Browse Source

rebase -i: don't error out if $state_dir already exists

In preparation for a later patch that will create $state_dir/autostash
in git-rebase.sh before anything else can happen, change a `mkdir
$state_dir` call to `mkdir -p $state_dir`.  The change is safe,
because this is not a test to detect an in-progress rebase (that is
already done much earlier in git-rebase.sh).

Signed-off-by: Ramkumar Ramachandra <artagnon@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
maint
Ramkumar Ramachandra 12 years ago committed by Junio C Hamano
parent
commit
1224f3d0f1
  1. 2
      git-rebase--interactive.sh

2
git-rebase--interactive.sh

@ -842,7 +842,7 @@ then @@ -842,7 +842,7 @@ then
fi

orig_head=$(git rev-parse --verify HEAD) || die "No HEAD?"
mkdir "$state_dir" || die "Could not create temporary $state_dir"
mkdir -p "$state_dir" || die "Could not create temporary $state_dir"

: > "$state_dir"/interactive || die "Could not mark as interactive"
write_basic_state

Loading…
Cancel
Save