diff options
author | Jeff King <peff@peff.net> | 2020-10-23 07:09:39 (GMT) |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2020-10-23 15:25:19 (GMT) |
commit | 16b0bb99eac5ebd02a5dcabdff2cfc390e9d92ef (patch) | |
tree | d0e42501b1cf65395e91e22e74f75fc5caa0286e /t/t3436-rebase-more-options.sh | |
parent | 56706dba33f5d4457395c651cf1cd033c6c03c7a (diff) | |
download | git-16b0bb99eac5ebd02a5dcabdff2cfc390e9d92ef.zip git-16b0bb99eac5ebd02a5dcabdff2cfc390e9d92ef.tar.gz git-16b0bb99eac5ebd02a5dcabdff2cfc390e9d92ef.tar.bz2 |
am: fix broken email with --committer-date-is-author-date
Commit e8cbe2118a (am: stop exporting GIT_COMMITTER_DATE, 2020-08-17)
rewrote the code for setting the committer date to use fmt_ident(),
rather than setting an environment variable and letting commit_tree()
handle it. But it introduced two bugs:
- we use the author email string instead of the committer email
- when parsing the committer ident, we used the wrong variable to
compute the length of the email, resulting in it always being a
zero-length string
This commit fixes both, which causes our test of this option via the
rebase "apply" backend to now succeed.
Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't/t3436-rebase-more-options.sh')
-rwxr-xr-x | t/t3436-rebase-more-options.sh | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/t/t3436-rebase-more-options.sh b/t/t3436-rebase-more-options.sh index 6f2f497..3fda223 100755 --- a/t/t3436-rebase-more-options.sh +++ b/t/t3436-rebase-more-options.sh @@ -70,7 +70,7 @@ test_ctime_is_atime () { test_cmp authortime committertime } -test_expect_failure '--committer-date-is-author-date works with apply backend' ' +test_expect_success '--committer-date-is-author-date works with apply backend' ' GIT_AUTHOR_DATE="@1234 +0300" git commit --amend --reset-author && git rebase --apply --committer-date-is-author-date HEAD^ && test_ctime_is_atime -1 |