Filename brace expansion in scripts

Colin Law clanlaw at
Thu Nov 18 20:55:03 UTC 2010

On 18 November 2010 18:23, Mark <mhullrich at> wrote:
> On Thu, Nov 18, 2010 at 7:48 AM, Colin Law <clanlaw at> wrote:
>> I have a problem with filename expansion in a script and am having
>> difficulty understanding what is going on.
>> In a terminal, if I enter
>> ls {a*,b*}
>> I see all files beginning with a or b (I know this is not the best way
>> of doing that but it is a simple example of the problem I am seeing).
> Although this is not what you were asking about, have you considered
> using [ab]* instead?

Yes, I know that, thanks.  As I said this is the simplest example of
the problem I was seeing, my real requirement is more complex.


More information about the ubuntu-users mailing list