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

Re: Passing sentences to an array



On Jul 18,  2:49pm, zzapper wrote:
}
} The above instead of a creating an array where each grepped line is an
} array element (desired behaviour" , creates an array of each word in
} each of the lines.

This one ought to be in the FAQ.

filessubject=( ${(f)"$(egrep -i 'note [0-9]{3}.*$1' note???.txt)"} )

} I haven't got word split set as an option

Doesn't matter, word splitting is the defined behavior for $(...) and
`...` substitutions.  If it were not, you'd get a one-element array,
which isn't any closer to what you wanted.



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