diff options
Diffstat (limited to 'git-rebase--interactive.sh')
-rw-r--r-- | git-rebase--interactive.sh | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/git-rebase--interactive.sh b/git-rebase--interactive.sh index ca994c5c54..41fd374c72 100644 --- a/git-rebase--interactive.sh +++ b/git-rebase--interactive.sh @@ -93,8 +93,17 @@ eval ' GIT_CHERRY_PICK_HELP="$resolvemsg" export GIT_CHERRY_PICK_HELP -comment_char=$(git config --get core.commentchar 2>/dev/null | cut -c1) -: ${comment_char:=#} +comment_char=$(git config --get core.commentchar 2>/dev/null) +case "$comment_char" in +'' | auto) + comment_char="#" + ;; +?) + ;; +*) + comment_char=$(echo "$comment_char" | cut -c1) + ;; +esac warn () { printf '%s\n' "$*" >&2 |