Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: Global Alias to "read" previous parameter?



On Dec 26,  3:15pm, zzapper wrote:
}
} $_ The last argument of the previous command.
} 
} same as !$ but more useful as history is not available in an  alias (?)

History is expanded before aliases are, so that's correct.

} is this zsh only? are there any more eg first argument

I believe this was borrowed from ksh.  No, there are not any others,
but $_ is used for some other things in other contexts.



Messages sorted by: Reverse Date, Date, Thread, Author