On Sun, 9 Jul 2006 11:17:21 +0200
Frank Barknecht <fbar@email-addr-hidden> wrote:
> Hallo,
> Hans hat gesagt: // Hans wrote:
>
> > in the subdir, or
> >
> > for i in ./dir1/*.mp3; do ln -s $i $i;done
>
> Almost, but you're trying to link a file on itself here ("$i->$i").
> Use this instead:
>
> $ for i in ./dir1/*.mp3; do ln -s $i . ;done
>
> or even more general:
>
> $ for i in */* ; do ln -s $i . ; done
Watch out for whitespaces though. If your filenames can contain spaces,
it might be wise to do
export IFS=$'\n'$'\t'
and then do your for-loop. Don't forget to change it back afterwards
though.
Flo
-- Palimm Palimm! http://tapas.affenbande.orgReceived on Sun Jul 9 20:15:04 2006
This archive was generated by hypermail 2.1.8 : Sun Jul 09 2006 - 20:15:04 EEST