summaryrefslogtreecommitdiff
path: root/sequencer.c
diff options
context:
space:
mode:
authorJohannes Schindelin <johannes.schindelin@gmx.de>2017-01-02 15:35:42 (GMT)
committerJunio C Hamano <gitster@pobox.com>2017-01-17 22:06:01 (GMT)
commit27fdbb96aae789105dadbddbfa9bccce8f88d3c8 (patch)
tree86f9b44c7810bbf1733c7920ba4b158f85d733dc /sequencer.c
parent62fdb6529a5b744e544ec3d776ba1adf48dab751 (diff)
downloadgit-27fdbb96aae789105dadbddbfa9bccce8f88d3c8.zip
git-27fdbb96aae789105dadbddbfa9bccce8f88d3c8.tar.gz
git-27fdbb96aae789105dadbddbfa9bccce8f88d3c8.tar.bz2
sequencer (rebase -i): suggest --edit-todo upon unknown command
This is the same behavior as known from `git rebase -i`. Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'sequencer.c')
-rw-r--r--sequencer.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/sequencer.c b/sequencer.c
index 27dc91c..5784fb4 100644
--- a/sequencer.c
+++ b/sequencer.c
@@ -1314,8 +1314,12 @@ static int read_populate_todo(struct todo_list *todo_list,
close(fd);
res = parse_insn_buffer(todo_list->buf.buf, todo_list);
- if (res)
+ if (res) {
+ if (is_rebase_i(opts))
+ return error(_("please fix this using "
+ "'git rebase --edit-todo'."));
return error(_("unusable instruction sheet: '%s'"), todo_file);
+ }
if (!todo_list->nr &&
(!is_rebase_i(opts) || !file_exists(rebase_path_done())))