aboutsummaryrefslogtreecommitdiff
path: root/contrib/subtree
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2015-08-03 11:01:31 -0700
committerJunio C Hamano <gitster@pobox.com>2015-08-03 11:01:31 -0700
commit7a06e63f821069fe959cdfe16592d9678eee06e4 (patch)
tree62f92b6c50fe542a977e3eff142c7595bae040a2 /contrib/subtree
parent0baebca51eba05dd3c3e9edf18fc49c67b55503f (diff)
parente7aac44ed276bc0de0253baa8e3f5ac247044a31 (diff)
downloadgit-7a06e63f821069fe959cdfe16592d9678eee06e4.tar.gz
git-7a06e63f821069fe959cdfe16592d9678eee06e4.tar.xz
Merge branch 'da/subtree-date-confusion'
"git subtree" (in contrib/) depended on "git log" output to be stable, which was a no-no. Apply a workaround to force a particular date format. * da/subtree-date-confusion: contrib/subtree: ignore log.date configuration
Diffstat (limited to 'contrib/subtree')
-rwxr-xr-xcontrib/subtree/git-subtree.sh2
-rwxr-xr-xcontrib/subtree/t/t7900-subtree.sh4
2 files changed, 5 insertions, 1 deletions
diff --git a/contrib/subtree/git-subtree.sh b/contrib/subtree/git-subtree.sh
index 07bd77c4c..9f0657185 100755
--- a/contrib/subtree/git-subtree.sh
+++ b/contrib/subtree/git-subtree.sh
@@ -305,7 +305,7 @@ copy_commit()
# We're going to set some environment vars here, so
# do it in a subshell to get rid of them safely later
debug copy_commit "{$1}" "{$2}" "{$3}"
- git log -1 --pretty=format:'%an%n%ae%n%ad%n%cn%n%ce%n%cd%n%B' "$1" |
+ git log -1 --pretty=format:'%an%n%ae%n%aD%n%cn%n%ce%n%cD%n%B' "$1" |
(
read GIT_AUTHOR_NAME
read GIT_AUTHOR_EMAIL
diff --git a/contrib/subtree/t/t7900-subtree.sh b/contrib/subtree/t/t7900-subtree.sh
index bd3df9793..90519823b 100755
--- a/contrib/subtree/t/t7900-subtree.sh
+++ b/contrib/subtree/t/t7900-subtree.sh
@@ -94,6 +94,10 @@ test_expect_success 'add sub3' '
# Back to mainline
cd ..
+test_expect_success 'enable log.date=relative to catch errors' '
+ git config log.date relative
+'
+
test_expect_success 'add main4' '
create main4 &&
git commit -m "main4" &&