X-Git-Url: https://git.verplant.org/?a=blobdiff_plain;f=git-status.sh;h=b90ffc198d97bccfc7f484e8555b01ba9bf5217b;hb=562051809589574576971c53c23aad93f8c395d9;hp=29c2b1169b5f8ee862cbc62d0a1eb5577587e1c1;hpb=4ae22d96fe9248dac4f26b1fc91154ba5e879799;p=git.git diff --git a/git-status.sh b/git-status.sh index 29c2b116..b90ffc19 100755 --- a/git-status.sh +++ b/git-status.sh @@ -2,7 +2,7 @@ # # Copyright (c) 2005 Linus Torvalds # -. git-sh-setup || die "Not a git archive" +GIT_DIR=$(git-rev-parse --git-dir) || exit report () { header="# @@ -41,7 +41,7 @@ git-update-index -q --unmerged --refresh || exit if GIT_DIR="$GIT_DIR" git-rev-parse --verify HEAD >/dev/null 2>&1 then - git-diff-index -M --cached --name-status HEAD | + git-diff-index -M --cached --name-status --diff-filter=MDTCRA HEAD | sed -e ' s/\\/\\\\/g s/ /\\ /g @@ -90,7 +90,7 @@ perl -e '$/ = "\0"; s|\n|\\n|g; s/^/# /; if (!$shown) { - print "#\n# Ignored files:\n"; + print "#\n# Untracked files:\n"; print "# (use \"git add\" to add to commit)\n#\n"; $shown = 1; }