diff options
author | Stephen Boyd <bebarino@gmail.com> | 2010-03-17 22:10:45 -0700 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2010-03-20 07:25:02 -0700 |
commit | 0d12e59f636b68964c80a82a58020d34a6cd5032 (patch) | |
tree | 29b579238046f696f83496afb5e37a327d292941 | |
parent | 7d182f52f1a754bdccb2e7c7cea54f773f76bc5c (diff) | |
download | git-0d12e59f636b68964c80a82a58020d34a6cd5032.tar.gz |
pull: replace unnecessary sed invocation
Getting the shortened branch name is as easy as using the shell's
parameter expansion.
Signed-off-by: Stephen Boyd <bebarino@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
-rwxr-xr-x | git-pull.sh | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/git-pull.sh b/git-pull.sh index 38331a8611..246a3a4b37 100755 --- a/git-pull.sh +++ b/git-pull.sh @@ -41,7 +41,7 @@ strategy_args= diffstat= no_commit= squash= no_ff= ff_only= log_arg= verbosity= merge_args= curr_branch=$(git symbolic-ref -q HEAD) -curr_branch_short=$(echo "$curr_branch" | sed "s|refs/heads/||") +curr_branch_short="${curr_branch#refs/heads/}" rebase=$(git config --bool branch.$curr_branch_short.rebase) while : do |