tools/cloney
changeset 116 ae6a90899b42
parent 61 7684fe2a9eb5
child 179 ca3935296621
--- a/tools/cloney	Tue Mar 01 14:19:15 2011 -0800
+++ b/tools/cloney	Wed Mar 02 02:39:37 2011 -0800
@@ -36,16 +36,18 @@
 echo symlink cloning $srcdir to $destdir
 
 cd ${srcdir}
-for i in `gfind . -type d | \
+gfind . -type d | \
     grep -v '^.$' | \
-    gsed -e 's,^./,,'`
+    gsed -e 's,^./,,' | \
+    while read i;
 do
-	mkdir -p ${destdir}/$i
+	mkdir -p "${destdir}/$i"
 done
 
-for i in `gfind . -type f | \
-    gsed -e 's,^./,,'`
+gfind . -type f | \
+    gsed -e 's,^./,,' | \
+    while read i;
 do
-	rm -f ${destdir}/$i
-	ln -s ${srcdir}/$i ${destdir}/$i
+	rm -f "${destdir}/$i"
+	ln -s "${srcdir}/$i" "${destdir}/$i"
 done