Merge branch 'rr/rebase-autostash'
authorJunio C Hamano <gitster@pobox.com>
Wed, 31 Jul 2013 19:38:29 +0000 (12:38 -0700)
committerJunio C Hamano <gitster@pobox.com>
Wed, 31 Jul 2013 19:38:29 +0000 (12:38 -0700)
* rr/rebase-autostash:
git-rebase: fix typo

1  2 
git-rebase.sh
diff --combined git-rebase.sh
index 0039ecfb407960444c31d48767b65cf773a3243a,a28209daba69d085070535393ae9b29dc74b909d..8d7659a22c253b9f9535aee38e3bf0ce380cef75
@@@ -155,11 -155,14 +155,11 @@@ finish_rebase () 
                then
                        echo "$(gettext 'Applied autostash.')"
                else
 -                      ref_stash=refs/stash &&
 -                      >>"$GIT_DIR/logs/$ref_stash" &&
 -                      git update-ref -m "autostash" $ref_stash $stash_sha1 ||
 -                      die "$(eval_gettext 'Cannot store $stash_sha1')"
 -
 +                      git stash store -m "autostash" -q $stash_sha1 ||
 +                      die "$(eval_gettext "Cannot store \$stash_sha1")"
                        gettext 'Applying autostash resulted in conflicts.
  Your changes are safe in the stash.
- You can run "git stash pop" or "git stash drop" it at any time.
+ You can run "git stash pop" or "git stash drop" at any time.
  '
                fi
        fi
@@@ -433,7 -436,7 +433,7 @@@ the
                shift
                ;;
        esac
 -      upstream=`git rev-parse --verify "${upstream_name}^0"` ||
 +      upstream=$(peel_committish "${upstream_name}") ||
        die "$(eval_gettext "invalid upstream \$upstream_name")"
        upstream_arg="$upstream_name"
  else
@@@ -469,7 -472,7 +469,7 @@@ case "$onto_name" i
        fi
        ;;
  *)
 -      onto=$(git rev-parse --verify "${onto_name}^0") ||
 +      onto=$(peel_committish "$onto_name") ||
        die "$(eval_gettext "Does not point to a valid commit: \$onto_name")"
        ;;
  esac
@@@ -542,9 -545,7 +542,9 @@@ the
        if test -z "$force_rebase"
        then
                # Lazily switch to the target branch if needed...
 -              test -z "$switch_to" || git checkout "$switch_to" --
 +              test -z "$switch_to" ||
 +              GIT_REFLOG_ACTION="$GIT_REFLOG_ACTION: checkout $switch_to" \
 +                      git checkout "$switch_to" --
                say "$(eval_gettext "Current branch \$branch_name is up to date.")"
                finish_rebase
                exit 0
@@@ -570,9 -571,7 +570,9 @@@ test "$type" = interactive && run_speci
  
  # Detach HEAD and reset the tree
  say "$(gettext "First, rewinding head to replay your work on top of it...")"
 -git checkout -q "$onto^0" || die "could not detach HEAD"
 +
 +GIT_REFLOG_ACTION="$GIT_REFLOG_ACTION: checkout $onto_name" \
 +      git checkout -q "$onto^0" || die "could not detach HEAD"
  git update-ref ORIG_HEAD $orig_head
  
  # If the $onto is a proper descendant of the tip of the branch, then