David C. Rankin wrote:
Listmates,
I am trying to use a bash list to move a group of files and directories under a single directory. It works, but I get a bash error I want to eliminate. How do I do it right so I can eliminate the error? Here is the situation. I want to move the following files and directories except "server" under the "desktop" directory with a single command:
drwxr-xr-x 2 david skyline 4096 2007-12-16 10:43 calc/ drwxr-xr-x 2 david skyline 4096 2007-07-24 21:34 crypto/ drwxr-xr-x 2 david skyline 4096 2008-05-14 11:37 desktop/ -rwxrwx--- 1 david skyline 4619908 2007-12-08 05:37 jpgraph-2.3.tar.gz* -rw-r--r-- 1 david skyline 608608 2008-02-21 22:43 kdesudo-2.4.tar.gz -rw-r--r-- 1 david skyline 503468 2008-03-03 20:38 KeePassX-0.3.0.tar.gz -rw-r--r-- 1 david skyline 27754 2008-03-03 02:42 pblogan-0.0.6-1.tar.gz drwxr-xr-x 2 david skyline 4096 2008-05-14 11:37 server/ -rw-r--r-- 1 david skyline 3251965 2008-02-22 21:17 sim-0.9.4.3.tar.bz2 -rwxr--r-- 1 david skyline 1050048 2008-02-22 22:04 trix-0.93.tar.bz2* -rw-r--r-- 1 david skyline 266574 2008-04-01 21:45 xca-0.6.4.tar.gz
I used this command line:
[11:38 nirvana/home/samba/computer/linux/apps] # mv { c* k* K* p* sim-0.9.4.3.tar.bz2 trix-0.93.tar.bz2 xca-0.6.4.tar.gz } desktop/
list in this case means list of commands.
It all worked, but I got this error:
mv: cannot stat `{': No such file or directory mv: cannot stat `}': No such file or directory
try this command line instead: # mv c* k* K* p* sim-0.9.4.3.tar.bz2 trix-0.93.tar.bz2 xca-0.6.4.tar.gz desktop/
Which makes sense because I didn't want the braces as directories only as list enclosures. How do I do it so I can eliminate the brace error?
Don't use them, that's not what they're for.
-- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org