[PATCH Cogito] cg-init breaks if . contains sub-dir

From: Brandon Philips <brandon@ifup.org>
Date: 2005-05-10 09:39:05
Hi Petr,

cg-init has the ability to cg-add all files in the current directory.

But if the current directory has a sub directory cg-init breaks because
the `find *` command on line 34 returns directories which cg-add doesn't
accept.

Regards

Brandon Philips

Shameless plug: cogito-0.10 available in Gentoo

--
http://ifup.org

---

cg-init: needs update
Index: cg-init
===================================================================
--- 972d8624458936868e6f392b40858b7c362af8cd/cg-init  (mode:100755)
+++ uncommitted/cg-init  (mode:100755)
@@ -31,7 +31,7 @@
 	echo "Cloned (origin $uri available as branch \"origin\")"
 else
 	git-read-tree # Seed the dircache
-	find * | xargs cg-add
+	find * ! -type d | xargs cg-add 
 	cg-commit -C -m"Initial commit" -e
 fi
 exit 0

-
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Received on Tue May 10 09:39:51 2005

This archive was generated by hypermail 2.1.8 : 2005-05-10 09:39:51 EST