From: Junio C Hamano Date: Mon, 3 Sep 2012 22:53:06 +0000 (-0700) Subject: Merge branch 'jc/maint-config-exit-status' X-Git-Tag: v1.8.0-rc0~115 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=3e06f5ff3870279f3bf2f97d4a4256032575055e;p=git.git Merge branch 'jc/maint-config-exit-status' The exit status code from "git config" was way overspecified while being incorrect. Update the implementation to give the documented status for a case that was documented, and introduce a new code for "all other errors". * jc/maint-config-exit-status: config: "git config baa" should exit with status 1 --- 3e06f5ff3870279f3bf2f97d4a4256032575055e diff --cc builtin/config.c index 8cd08da99,b44277c23..ada6e1211 --- a/builtin/config.c +++ b/builtin/config.c @@@ -160,8 -160,8 +160,8 @@@ static int show_config(const char *key_ static int get_value(const char *key_, const char *regex_) { - int ret = -1; + int ret = CONFIG_GENERIC_ERROR; - char *global = NULL, *repo_config = NULL; + char *global = NULL, *xdg = NULL, *repo_config = NULL; const char *system_wide = NULL, *local; struct config_include_data inc = CONFIG_INCLUDE_INIT; config_fn_t fn;