summaryrefslogtreecommitdiff
path: root/git-rebase--interactive.sh
diff options
context:
space:
mode:
authorAlban Gruin <alban.gruin@gmail.com>2018-08-10 16:51:31 (GMT)
committerJunio C Hamano <gitster@pobox.com>2018-08-10 18:56:22 (GMT)
commit64a43cbd5da23718dee242d6ad4d5823128bf564 (patch)
tree7b5c399b5497773b519a7609f19c45321e8c1b7e /git-rebase--interactive.sh
parent2aed01811daee2f412b795ea539a4eb5abb69510 (diff)
downloadgit-64a43cbd5da23718dee242d6ad4d5823128bf564.zip
git-64a43cbd5da23718dee242d6ad4d5823128bf564.tar.gz
git-64a43cbd5da23718dee242d6ad4d5823128bf564.tar.bz2
rebase -i: rewrite the edit-todo functionality in C
This rewrites the edit-todo functionality from shell to C. To achieve that, a new command mode, `edit-todo`, is added, and the `write-edit-todo` flag is removed, as the shell script does not need to write the edit todo help message to the todo list anymore. The shell version is then stripped in favour of a call to the helper. Signed-off-by: Alban Gruin <alban.gruin@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'git-rebase--interactive.sh')
-rw-r--r--git-rebase--interactive.sh11
1 files changed, 1 insertions, 10 deletions
diff --git a/git-rebase--interactive.sh b/git-rebase--interactive.sh
index 94c23a7..2defe60 100644
--- a/git-rebase--interactive.sh
+++ b/git-rebase--interactive.sh
@@ -108,16 +108,7 @@ initiate_action () {
--continue
;;
edit-todo)
- git stripspace --strip-comments <"$todo" >"$todo".new
- mv -f "$todo".new "$todo"
- collapse_todo_ids
- git rebase--helper --append-todo-help --write-edit-todo
-
- git_sequence_editor "$todo" ||
- die "$(gettext "Could not execute editor")"
- expand_todo_ids
-
- exit
+ exec git rebase--helper --edit-todo
;;
show-current-patch)
exec git show REBASE_HEAD --