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:
authorPhillip Wood <phillip.wood@dunelm.org.uk>2020-08-17 20:40:01 +0300
committerJunio C Hamano <gitster@pobox.com>2020-08-17 21:58:37 +0300
commite8cbe2118a8e3c1aa71ed8d93f96001decebde1d (patch)
tree2a431c9955a73175b6edc8ee95cc1dfa311946d5 /sequencer.c
parentef484add9f6ba846c62e4f13ebe0ba99b9cc4aa5 (diff)
am: stop exporting GIT_COMMITTER_DATE
The implementation of --committer-date-is-author-date exports GIT_COMMITTER_DATE to override the default committer date but does not reset GIT_COMMITTER_DATE in the environment after creating the commit so it is set in the environment of any hooks that get run. We're about to add the same functionality to the sequencer and do not want to have GIT_COMMITTER_DATE set when running hooks or exec commands so lets update commit_tree_extended() to take an explicit committer so we override the default date without setting GIT_COMMITTER_DATE in the environment. Signed-off-by: Phillip Wood <phillip.wood@dunelm.org.uk> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'sequencer.c')
-rw-r--r--sequencer.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sequencer.c b/sequencer.c
index 6fd2674632..968a2d4ef3 100644
--- a/sequencer.c
+++ b/sequencer.c
@@ -1408,8 +1408,8 @@ static int try_to_commit(struct repository *r,
reset_ident_date();
- if (commit_tree_extended(msg->buf, msg->len, &tree, parents,
- oid, author, opts->gpg_sign, extra)) {
+ if (commit_tree_extended(msg->buf, msg->len, &tree, parents, oid,
+ author, NULL, opts->gpg_sign, extra)) {
res = error(_("failed to write commit object"));
goto out;
}