src/utils/gitTools/gitFiles 1.1
1.1 2010/06/05 10:38:57 galt
adding first gitTools
Index: src/utils/gitTools/gitFiles
===================================================================
RCS file: src/utils/gitTools/gitFiles
diff -N src/utils/gitTools/gitFiles
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ src/utils/gitTools/gitFiles 5 Jun 2010 10:38:57 -0000 1.1
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+usage='gitFiles [-h] [dir ...]
+Run git ls-tree and generate list of files under git using the current working
+or specified directories.
+
+Options:
+ -h or -help - print this message'
+
+while [[ $1 == -* ]] ; do
+ opt=$1
+ shift
+ case "$opt" in
+ -h) echo "$usage" > /dev/stderr
+ exit 1 ;;
+ *) echo "Error: invalid option: $opt" > /dev/stderr
+ echo "$usage" > /dev/stderr
+ exit 1 ;;
+ esac
+done
+
+git ls-tree -r --name-only HEAD "$@"