Interplane page as plain text, for reading tools and agents. English is the reference text: translate it with your own tool. Text in backticks and in ``` blocks (commands, fingerprints, file names) and link targets in <...> are exact: copy them, never translate them. Page: /drakestapleton/git/blob/master/rebase-interactive.c # git [Ported from github.com/git/git] Sync with Git 2.56.1 Brought by drakestapleton Sign in to star 0 stars 0 watching About Files History Releases Proposed changes Issues For developers branch `master` Branches Tags History `git / rebase-interactive.c` 250 lines ยท 8180 bytes Raw Blame History 1 #define USE_THE_REPOSITORY_VARIABLE 2 3 #include "git-compat-util.h" 4 #include "commit.h" 5 #include "editor.h" 6 #include "environment.h" 7 #include "gettext.h" 8 #include "sequencer.h" 9 #include "rebase-interactive.h" 10 #include "repository.h" 11 #include "strbuf.h" 12 #include "commit-slab.h" 13 #include "config.h" 14 #include "dir.h" 15 #include "object-name.h" 16 17 static const char edit_todo_list_advice[] = 18 N_("You can fix this with 'git rebase --edit-todo' " 19 "and then run 'git rebase --continue'.\n" 20 "Or you can abort the rebase with 'git rebase" 21 " --abort'.\n"); 22 23 enum missing_commit_check_level { 24 MISSING_COMMIT_CHECK_IGNORE = 0, 25 MISSING_COMMIT_CHECK_WARN, 26 MISSING_COMMIT_CHECK_ERROR 27 }; 28 29 static enum missing_commit_check_level get_missing_commit_check_level(void) 30 { 31 const char *value; 32 33 if (repo_config_get_value(the_repository, "rebase.missingcommitscheck", &value) || 34 !strcasecmp("ignore", value)) 35 return MISSING_COMMIT_CHECK_IGNORE; 36 if (!strcasecmp("warn", value)) 37 return MISSING_COMMIT_CHECK_WARN; 38 if (!strcasecmp("error", value)) 39 return MISSING_COMMIT_CHECK_ERROR; 40 warning(_("unrecognized setting %s for option " 41 "rebase.missingCommitsCheck. Ignoring."), value); 42 return MISSING_COMMIT_CHECK_IGNORE; 43 } 44 45 void append_todo_help(int command_count, 46 const char *shortrevisions, const char *shortonto, 47 struct strbuf *buf) 48 { 49 const char *msg = _("\nCommands:\n" 50 "p, pick = use commit\n" 51 "r, reword = use commit, but edit the commit message\n" 52 "e, edit = use commit, but stop for amending\n" 53 "s, squash = use commit, but meld into previous commit\n" 54 "f, fixup [-C | -c] = like \"squash\" but keep only the previous\n" 55 " commit's log message, unless -C is used, in which case\n" 56 " keep only this commit's message; -c is same as -C but\n" 57 " opens the editor\n" 58 "x, exec = run command (the rest of the line) using shell\n" 59 "b, break = stop here (continue rebase later with 'git rebase --continue')\n" 60 "d, drop = remove commit\n" 61 "l, label