]> git.phdru.name Git - git-scripts.git/blobdiff - ls-not-pushed-carefully
Exclude empty "others" directories
[git-scripts.git] / ls-not-pushed-carefully
index 2bd0159f00db52d4701ffe67dc2d8f1c288f3d5f..0ae1935e3bccacec74c64a85c16afa17c8d0c3c5 100755 (executable)
@@ -1,13 +1,13 @@
 #! /bin/sh
 
-cd "`dirname \"$0\"`" && PROG_DIR="`pwd`" &&
+cd "`dirname \"$0\"`" && prog_dir="`pwd`" &&
 cd "$HOME"/tmp && rm -rf ls-not-pushed-carefully.tmp &&
 
 LSTMP="$HOME"/tmp/ls-not-pushed-carefully.tmp \
-"$PROG_DIR"/do-all \
+"$prog_dir"/do-all \
    'test "$g" = "$d/.git" || continue;' \
    'rsync -aW --del --protocol=28 "$d" "$LSTMP" && cd "$LSTMP/$b" &&' \
-   'test -n "`git status --branch --untracked-files=no |
-      grep "ahead\|behind"`" && echo "$d"' &&
+   'test -n "`git status --branch --short | grep "ahead\|behind"`" &&
+   echo "$d"' &&
 
 cd "$HOME"/tmp && exec rm -rf ls-not-pushed-carefully.tmp