Skip to content

Commit 2709401

Browse files
committed
Additional debug statements
1 parent 852ee02 commit 2709401

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

mgitstatus

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
# MIT license
44

55
VERSION="2.2"
6-
DEBUG=0
6+
DEBUG=${MG_DEBUG:-0}
77

88
usage () {
99
cat << EOF >&2
@@ -276,6 +276,11 @@ for DIR in "${@:-"."}"; do
276276
STASHES=$(git stash list | wc -l)
277277
cd "$OLDPWD" || exit
278278

279+
[ $DEBUG -eq 1 ] && echo "UNSTAGED: $UNSTAGED"
280+
[ $DEBUG -eq 1 ] && echo "UNCOMMITTED: $UNCOMMITTED"
281+
[ $DEBUG -eq 1 ] && echo "UNTRACKED: $UNTRACKED"
282+
[ $DEBUG -eq 1 ] && echo "STASHES: $STASHES"
283+
279284
# Build up the status string if not flattening. Otherwise, print
280285
# results immediately.
281286
IS_OK=0 # 0 = Repo needs something, 1 = Repo needs nothing ('ok')

0 commit comments

Comments
 (0)