summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 45a0ee1)
raw | patch | inline | side by side (parent: 45a0ee1)
author | Andrew Sayers <andrew-git@pileofstuff.org> | |
Thu, 17 Jun 2010 21:32:16 +0000 (22:32 +0100) | ||
committer | Junio C Hamano <gitster@pobox.com> | |
Fri, 18 Jun 2010 16:15:52 +0000 (09:15 -0700) |
Define several variables in __git_ps1 to avoid errors under "set -u" semantics.
__git_ps1 seems to have been missed when the rest of the file was fixed in
25a31f8.
Signed-off-by: Andrew Sayers <andrew-git@pileofstuff.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
__git_ps1 seems to have been missed when the rest of the file was fixed in
25a31f8.
Signed-off-by: Andrew Sayers <andrew-git@pileofstuff.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
contrib/completion/git-completion.bash | patch | blob | history |
index 57245a8c01fa3aba4f9e3f2bc258b40f38f446c0..256b1a8f9299d238af9f1633c778db705c9e1258 100755 (executable)
{
local g="$(__gitdir)"
if [ -n "$g" ]; then
- local r
- local b
+ local r=""
+ local b=""
if [ -f "$g/rebase-merge/interactive" ]; then
r="|REBASE-i"
b="$(cat "$g/rebase-merge/head-name")"
}
fi
- local w
- local i
- local s
- local u
- local c
+ local w=""
+ local i=""
+ local s=""
+ local u=""
+ local c=""
if [ "true" = "$(git rev-parse --is-inside-git-dir 2>/dev/null)" ]; then
if [ "true" = "$(git rev-parse --is-bare-repository 2>/dev/null)" ]; then