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

Re: Tip of the day: previous command output



> I use this little function [*] for a similar purpose:
Great!  I was just about to post a followup asking how to do what Bart is
doing because I use find and locate a lot, too but then I usually do stuff
with the whole list of found files, not just one of them.

So I modified Barts "keep" to use
      kept=$($*)
instead of
      kept=($~*)

So that I can do
  keep locate -i pictures | grep -i thursday | grep -i png
  keep print $kept | grep too_dark
  qiv $kept

At least that's what I thought that would work.  But it doesn't.
The first keep prints out the found files but $kept doesn't contain the
list.

Help, where is my mistake?
 Andy.

-- 
                              o      _     _         _
  ------- __o       __o      /\_   _ \\o  (_)\__/o  (_)          -o)
  ----- _`\<,_    _`\<,_    _>(_) (_)/<_    \_| \   _|/' \/       /\\
  ---- (_)/ (_)  (_)/ (_)  (_)        (_)   (_)    (_)'  _\o_    _\_v
 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
 Our continuing mission: To seek out knowledge of C, to explore strange
 UNIX commands and to boldly code where no one has a manpage 4... 



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