--- /dev/null
+#! /bin/sh
+
+STMP="$HOME"/tmp/git-status.tmp
+export STMP
+trap 'exec rm -rf "$STMP"' 0 HUP INT QUIT TERM
+rm -rf "$STMP" && mkdir "$STMP" &&
+
+GIT_INDEX_FILE="$STMP"/index &&
+export GIT_INDEX_FILE &&
+
+if [ -d .git -a -f .git/index ]; then
+ cp -p .git/index $GIT_INDEX_FILE
+else
+ echo "$0: `pwd` is not a git directory" >&2
+ exit 1
+fi &&
+
+git status "$@" &&
+exec rm -rf "$STMP"