From: Dan Aloni Date: Sat, 6 Feb 2016 06:23:36 +0000 (+0200) Subject: ident: add user.useConfigOnly boolean for when ident shouldn't be guessed X-Git-Tag: v2.8.0-rc0~51^2 X-Git-Url: https://git.lorimer.id.au/gitweb.git/diff_plain/4d5c2956969a6690db2bbb2f3ff40459c09d7646?hp=4d5c2956969a6690db2bbb2f3ff40459c09d7646 ident: add user.useConfigOnly boolean for when ident shouldn't be guessed It used to be that: git config --global user.email "(none)" was a viable way for people to force themselves to set user.email in each repository. This was helpful for people with more than one email address, targeting different email addresses for different clones, as it barred git from creating a commit unless the user.email config was set in the per-repo config to the correct email address. A recent change, 19ce497c (ident: keep a flag for bogus default_email, 2015-12-10), however, declared that an explicitly configured user.email is not bogus, no matter what its value is, so this hack no longer works. Provide the same functionality by adding a new configuration variable user.useConfigOnly; when this variable is set, the user must explicitly set user.email configuration. Signed-off-by: Junio C Hamano Helped-by: Eric Sunshine Signed-off-by: Jeff King Signed-off-by: Dan Aloni Signed-off-by: Junio C Hamano ---