$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. Signed-off-by: Pierre Habouzit <madcoder@debian.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Pierre Habouzit committed
Jun 5, 2007 at 18:40 UTC
ec563e8153cba89728a271a26c8a94e7a42d8152
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;