Read configuration also from ~/.gitconfig
authorJohannes Schindelin <Johannes.Schindelin@gmx.de>
Thu, 8 Jun 2006 11:31:12 +0000 (13:31 +0200)
committerJunio C Hamano <junkio@cox.net>
Sat, 10 Jun 2006 21:09:25 +0000 (14:09 -0700)
commitea71d197c3d265f32aae225a5fd17f4ef617c216
treec8ce872cbf4eb00b884e0c027d475d025a8f96c8
parent41292ddd37202ff6dce34986c87a6000c5d3fbfa
Read configuration also from ~/.gitconfig

This patch is based on Pasky's, with three notable differences:

- I did not yet update the documentation
- I named it .gitconfig, not .gitrc
- git-repo-config does not barf when a unique key is overridden locally

The last means that if you have something like

[alias]
l = log --stat -M

in ~/.gitconfig, and

[alias]
l = log --stat -M next..

in $GIT_DIR/config, then

git-repo-config alias.l

returns only one value, namely the value from $GIT_DIR/config.

Signed-off-by: Johannes Schindelin <Johannes.Schindelin@gmx.de>
Signed-off-by: Junio C Hamano <junkio@cox.net>
config.c
repo-config.c
t/t1300-repo-config.sh