@matheusbsbs / matheus-bagliano / commits / 1367214417
Fork 0

$EMAIL is a last resort fallback, as it's system-wide.

$EMAIL is a system-wide setup that is used for many many many applications. If the git user chose a specific user.email setup, then _this_ should be honoured rather than $EMAIL. [jc: cherry-picked ec563e8 from 'master'] Signed-off-by: Pierre Habouzit <madcoder@debian.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>

Junio C Hamano committed Jun 15, 2007 at 23:33 UTC 1367214417ee55266ab951cf198bf1aa7e051965
1 file changed +2 -2
ident.c
+2 -2
@@ -195,10 +195,10 @@ const char *fmt_ident(const char *name, const char *email,
195 setup_ident();
196 if (!name)
197 name = git_default_name;
198 - if (!email)
199 - email = getenv("EMAIL");
198 if (!email)
199 email = git_default_email;
200 + if (!email)
201 + email = getenv("EMAIL");
202
203 if (!*name) {
204 struct passwd *pw;