Reply to message «Re: Why does this extended glob pattern fail?», sent 14:20:58 01 August 2011, Monday by Ronald Fischer: > Actually, this does not work either. Instead, I have to write > > cp $from/^*.(log|png) $dest > > The reason is that ^ doesn't apply to the *whole* word, but only up to > the first '/'. There is also a ~ that applies to the whole pattern, but in this case you will have to write `$from/*~$from/*.(log|png)'. Original message: > On Wed, 27 Jul 2011 15:32 +0100, "Stephane Chazelas" > > <stephane.chazelas@xxxxxxxxx> wrote: > > or better, use globbing alternate operator rather than brace > > expansion: > > > > cp ^$from/*.(log|png) $dest > > Actually, this does not work either. Instead, I have to write > > cp $from/^*.(log|png) $dest > > The reason is that ^ doesn't apply to the *whole* word, but only up to > the first '/'. > > Thanks for helping! > > Ronald
Attachment:
signature.asc
Description: This is a digitally signed message part.