bug-bash
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: how to make an alphabetical counter


From: Paul Jarc
Subject: Re: how to make an alphabetical counter
Date: Tue, 25 Dec 2001 17:15:32 -0500
User-agent: Gnus/5.090004 (Oort Gnus v0.04) Emacs/20.7 (i386-redhat-linux-gnu)

"David D" <dd@asi.fr> wrote:
> eval "find -type f -name \"^\$'\\$(printf %o "$[$number]")'*\" -exec mv -f
> {} ./\$'\\$(printf %o "$[$number]")' \; "

$'' isn't expanded within double quotes.

find's -name argument should be a shell pattern, not a regexp, thus
there should be no leading "^".

eval "letter=\$'\\$(printf %o "$[$number]")'"
find -type f -name "$letter*" -exec mv -f '{}' "./$letter" \;


paul



reply via email to

[Prev in Thread] Current Thread [Next in Thread]