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

Re: Parameter Expansion




On 8/13/2017 7:07 PM, Bart Schaefer wrote:
FUNCS=( $SD/autoload/*(:t) )
Wow, it never dawned on me that I could just use it as a glob qualifier. I'd be trying to do it with ${~..} and ${~~..} with no luck.

Thank you!
Oh, and if you want something more complicated, the above is
equivalent to using the "e" glob qualifier like so:

   $SD/autoload/*(e?'reply=( "$REPLY:t" )'?)

So you can do any substitution tricks you want on $REPLY.  Just
remember that it will contain exactly one filename at a time.
I've read about but not yet played around with the e flag yet, but I've heard of it. :)

Thanks again Bart!

--
-Clint



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