Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.kernel.org/pub/scm/git/git.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2021-04-08 23:23:25 +0300
committerJunio C Hamano <gitster@pobox.com>2021-04-08 23:23:26 +0300
commit82fd285e4606b941bd2bf79be700fb0371599c18 (patch)
treea2cd3d05f5bff362fee7cb380065e801ddfb02bf /builtin
parent22eee7f4554e777de93134c0ae06ee611bd570a4 (diff)
parent39edfd5cbc4d168db19ec1bc867d78ec7211ec39 (diff)
Merge branch 'en/sequencer-edit-upon-conflict-fix'
"git cherry-pick/revert" with or without "--[no-]edit" did not spawn the editor as expected (e.g. "revert --no-edit" after a conflict still asked to edit the message), which has been corrected. * en/sequencer-edit-upon-conflict-fix: sequencer: fix edit handling for cherry-pick and revert messages
Diffstat (limited to 'builtin')
-rw-r--r--builtin/revert.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/builtin/revert.c b/builtin/revert.c
index 314a86c562..237f2f18d4 100644
--- a/builtin/revert.c
+++ b/builtin/revert.c
@@ -182,7 +182,7 @@ static int run_sequencer(int argc, const char **argv, struct replay_opts *opts)
"--signoff", opts->signoff,
"--no-commit", opts->no_commit,
"-x", opts->record_origin,
- "--edit", opts->edit,
+ "--edit", opts->edit > 0,
NULL);
if (cmd) {
@@ -230,8 +230,6 @@ int cmd_revert(int argc, const char **argv, const char *prefix)
struct replay_opts opts = REPLAY_OPTS_INIT;
int res;
- if (isatty(0))
- opts.edit = 1;
opts.action = REPLAY_REVERT;
sequencer_init_config(&opts);
res = run_sequencer(argc, argv, &opts);