Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: Passing sentences to an array
- X-seq: zsh-users 9102
- From: Bart Schaefer <schaefer@xxxxxxxxxxxxxxxx>
- To: zsh-users@xxxxxxxxxx
- Subject: Re: Passing sentences to an array
- Date: Mon, 18 Jul 2005 15:11:20 +0000
- In-reply-to: <6lcnd1t0qclmgdtjj9v3mlfn9c5fgnsram@xxxxxxx>
- Mailing-list: contact zsh-users-help@xxxxxxxxxx; run by ezmlm
- References: <6lcnd1t0qclmgdtjj9v3mlfn9c5fgnsram@xxxxxxx>
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