Use portable sh syntax rather than bash syntax. Thanks to drizzt.
authorZac Medico <zmedico@gentoo.org>
Sat, 21 Apr 2007 10:49:56 +0000 (10:49 -0000)
committerZac Medico <zmedico@gentoo.org>
Sat, 21 Apr 2007 10:49:56 +0000 (10:49 -0000)
svn path=/main/trunk/; revision=6429

bin/ecompressdir

index 590fae75b7c7a02f7b94c047c02e85063826bb2e..4db01697ab306ec3f421097e64504023eecf3491 100755 (executable)
@@ -121,7 +121,7 @@ for dir in "$@" ; do
 
        # forcibly break all hard links as some compressors whine about it
        find "${dir}" -type f -links +1 -exec env file="{}" sh -c \
-               'cp -p "${file}"{,.ecompress.break} ; mv -f "${file}"{.ecompress.break,}' \;
+               'cp -p "${file}" "${file}.ecompress.break" ; mv -f "${file}.ecompress.break" "${file}"' \;
 
        # now lets do our work
        [[ -z ${suffix} ]] && continue