[orca] Updated run_pylint.sh to work with git.



commit 3abf4d6c1983abcde95b02330af4ed8ac288b33c
Author: Mesar Hameed <mesar hameed gmail com>
Date:   Wed Apr 22 15:30:52 2009 +0100

    Updated run_pylint.sh to work with git.
---
 run_pylint.sh.in |    7 ++++++-
 1 files changed, 6 insertions(+), 1 deletions(-)

diff --git a/run_pylint.sh.in b/run_pylint.sh.in
old mode 100644
new mode 100755
index ef7d7e0..88cd929
--- a/run_pylint.sh.in
+++ b/run_pylint.sh.in
@@ -7,7 +7,12 @@ exec_prefix= prefix@
 INSTALL_DIR= pyexecdir@
 if [ "x$*" == "x" ]
 then
-    FILES=`svn stat src/orca | egrep "^M|^A" | grep "[.]py$" | awk '{ print $2 }'`
+    if [ -d .git ]
+    then
+        FILES=`git status | egrep 'modified:|new file:' | grep '[.]py$' | awk '{ print $NF }'`
+    else
+        FILES=`svn stat src/orca | egrep '^M|^A' | grep '[.]py$' | awk '{ print $NF }'`
+    fi
 else
     FILES="$*"
 fi



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]