Re: For Loops and Space in Names, take 2

2008-12-10 Thread Robert Wuest
On Thu, 2008-12-11 at 10:02 +1100, Cameron Simpson wrote: Because the $1 is unquoted here you probably don't need the + in the regexps. But you probably should quote $1 because of this: [/Users/cameron]fleet* x='t*' [/Users/cameron]fleet* echo $x t* [/Users/cameron]fleet* echo $x

Re: For Loops and Space in Names, take 2

2008-12-10 Thread Robert Wuest
the $1 is still unsafe, and cannot easily be made safe. (Actually, bash's printf %q formatter may do the trick for you, and since you're already in nonportable GNU sed land, you may as well step right in with nonportable bash too:-) I'm not sure what %q does. It's not in the info or

Re: For Loops and Space in Names, take 2

2008-12-10 Thread Cameron Simpson
On 10Dec2008 20:52, Robert Wuest [EMAIL PROTECTED] wrote: | On Thu, 2008-12-11 at 10:02 +1100, Cameron Simpson wrote: | Because the $1 is unquoted here you probably don't need the + in the | regexps. But you probably should quote $1 because of this: | |[/Users/cameron]fleet* x='t*' |