Merge remote-tracking branch 'l10n/vi/vnwildman/master'
[gitweb.git] / git-rebase--interactive.sh
index 6ec9d3cb40b1e96f75132a11eb625fd42e64885d..b64dd28acf86e0b3075a638ae3419fb3a79a1815 100644 (file)
@@ -963,7 +963,7 @@ else
 fi
 git rev-list $merges_option --pretty=oneline --abbrev-commit \
        --abbrev=7 --reverse --left-right --topo-order \
-       $revisions | \
+       $revisions ${restrict_revision+^$restrict_revision} | \
        sed -n "s/^>//p" |
 while read -r shortsha1 rest
 do
@@ -1013,7 +1013,7 @@ then
        git rev-list $revisions |
        while read rev
        do
-               if test -f "$rewritten"/$rev -a "$(sane_grep "$rev" "$state_dir"/not-cherry-picks)" = ""
+               if test -f "$rewritten"/$rev && test "$(sane_grep "$rev" "$state_dir"/not-cherry-picks)" = ""
                then
                        # Use -f2 because if rev-list is telling us this commit is
                        # not worthwhile, we don't want to track its multiple heads,
@@ -1049,14 +1049,14 @@ fi
 
 
 has_action "$todo" ||
-       die_abort "Nothing to do"
+       return 2
 
 cp "$todo" "$todo".backup
 git_sequence_editor "$todo" ||
        die_abort "Could not execute editor"
 
 has_action "$todo" ||
-       die_abort "Nothing to do"
+       return 2
 
 expand_todo_ids