summaryrefslogtreecommitdiff
path: root/builtin/commit.c
diff options
context:
space:
mode:
authorJorge Juan Garcia Garcia <Jorge-Juan.Garcia-Garcia@ensimag.imag.fr>2013-06-11 13:34:05 (GMT)
committerJunio C Hamano <gitster@pobox.com>2013-06-24 17:25:49 (GMT)
commitec85d0700faac679ec27eeacad2bcaa6d9bc8322 (patch)
tree4651cec77b35fb8276c0b882df653807a3b8003a /builtin/commit.c
parent4fb5166ab5e1b83ee6211ac77d76173f881ebfdb (diff)
downloadgit-ec85d0700faac679ec27eeacad2bcaa6d9bc8322.zip
git-ec85d0700faac679ec27eeacad2bcaa6d9bc8322.tar.gz
git-ec85d0700faac679ec27eeacad2bcaa6d9bc8322.tar.bz2
status: introduce status.branch to enable --branch by default
Some people often run 'git status -b'. The config variable status.branch allows to set it by default. Signed-off-by: Jorge Juan Garcia Garcia <Jorge-Juan.Garcia-Garcia@ensimag.imag.fr> Signed-off-by: Mathieu Lienard--Mayor <Mathieu.Lienard--Mayor@ensimag.imag.fr> Reviewed-by: Matthieu Moy <Matthieu.Moy@grenoble-inp.fr> Signed-off-by: Matthieu Moy <Matthieu.Moy@grenoble-inp.fr> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'builtin/commit.c')
-rw-r--r--builtin/commit.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/builtin/commit.c b/builtin/commit.c
index b2f41de..d6c8e20 100644
--- a/builtin/commit.c
+++ b/builtin/commit.c
@@ -1117,6 +1117,10 @@ static int git_status_config(const char *k, const char *v, void *cb)
status_format = STATUS_FORMAT_NONE;
return 0;
}
+ if (!strcmp(k, "status.branch")) {
+ s->show_branch = git_config_bool(k, v);
+ return 0;
+ }
if (!strcmp(k, "status.color") || !strcmp(k, "color.status")) {
s->use_color = git_config_colorbool(k, v);
return 0;