]> source.dussan.org Git - jgit.git/commit
Read user.name and email from environment first 13/42413/3
authorMatthias Sohn <matthias.sohn@sap.com>
Mon, 23 Feb 2015 12:49:24 +0000 (13:49 +0100)
committerMatthias Sohn <matthias.sohn@sap.com>
Tue, 24 Feb 2015 15:39:19 +0000 (16:39 +0100)
commita8fd029a931f35db9f98e4f75530f299a70892eb
tree6b322847a5159e3a6b3f9a366322ab4b446ea49f
parenta8743df19c2574bc3481fa5f811499b5960951a8
Read user.name and email from environment first

According to [1] user name and email are taken first from the
environment variables:
GIT_AUTHOR_NAME, GIT_AUTHOR_EMAIL
GIT_COMMITTER_NAME, GIT_COMMITTER_EMAIL

In case (some of) these environment variables are not set, the
information is taken from the git configuration.

JGit doesn not yet support the environment variables GIT_AUTHOR_DATE and
GIT_COMMITTER_DATE.

[1] https://www.kernel.org/pub/software/scm/git/docs/git-commit-tree.html#_commit_information

Bug: 460586
Change-Id: I3ba582b4ae13674cf319652b5b13ebcbb96dd8ec
Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
org.eclipse.jgit.test/tst/org/eclipse/jgit/lib/ConfigTest.java
org.eclipse.jgit/src/org/eclipse/jgit/lib/UserConfig.java