aboutsummaryrefslogtreecommitdiff
path: root/repo-config.c
Commit message (Collapse)AuthorAge
* repo-config: deconvolute logicsJohannes Schindelin2006-05-03
| | | | | | | It was rightly noticed that the logic is quite convoluted. Fix that. Signed-off-by: Johannes Schindelin <Johannes.Schindelin@gmx.de> Signed-off-by: Junio C Hamano <junkio@cox.net>
* repo-config: readability fixups.Junio C Hamano2006-05-02
| | | | Signed-off-by: Junio C Hamano <junkio@cox.net>
* repo-config: support --get-regexpJohannes Schindelin2006-05-02
| | | | | | | | | | | | | | | With --get-regexp, output all key/value pairs where the key matches a regexp. Example: git-repo-config --get-regexp remote.*.url will output something like remote.junio.url git://git.kernel.org/pub/scm/git/git.git remote.gitk.url git://git.kernel.org/pub/scm/gitk/gitk.git Signed-off-by: Johannes Schindelin <Johannes.Schindelin@gmx.de> Signed-off-by: Junio C Hamano <junkio@cox.net>
* repo-config: fix segfault with no argument.Johannes Schindelin2006-05-02
| | | | | | | | An earlier addition of --list feature was carelessly done and caused an invalid access to argv[1] when it was not given. Signed-off-by: Johannes Schindelin <Johannes.Schindelin@gmx.de> Signed-off-by: Junio C Hamano <junkio@cox.net>
* git-repo-config --list supportPetr Baudis2006-04-24
| | | | | | | | | This adds git-repo-config --list (or git-repo-config -l) support, similar to what git-var -l does now (to be phased out so that we have a single sane interface to the config file instead of fragmented and confused API). Signed-off-by: Petr Baudis <pasky@suse.cz>
* repo-config: give value_ a sane default so regexec won't segfaultJonas Fonseca2006-03-07
| | | | | Signed-off-by: Jonas Fonseca <fonseca@diku.dk> Signed-off-by: Junio C Hamano <junkio@cox.net>
* Add support for explicit type specifiers when calling git-repo-configPetr Baudis2006-02-12
| | | | | | | | | | | | | | | | | | | | | Currently, git-repo-config will just return the raw value of option as specified in the config file; this makes things difficult for scripts calling it, especially if the value is supposed to be boolean. This patch makes it possible to ask git-repo-config to check if the option is of the given type (int or bool) and write out the value in its canonical form. If you do not pass --int or --bool, the behaviour stays unchanged and the raw value is emitted. This also incidentally fixes the segfault when option with no value is encountered. [jc: tweaked the option parsing a bit to make it easier to see that the patch does not change anything but the type stuff in the diff output. Also changed to avoid "foo ? : bar" construct. ] Signed-off-by: Petr Baudis <pasky@suse.cz> Signed-off-by: Junio C Hamano <junkio@cox.net>
* AIX compile fix for repo-config.cAmos Waterland2006-01-05
| | | | | | | | | | | | | | | | | | AIX 5 has a /usr/include/regex.h containing this code: #ifdef _NO_PROTO extern char *regex(); extern char *regcmp(); #else /* _NO_PROTO */ extern char *regex(const char *, const char *, ...); extern char *regcmp(const char *, ...); #endif /* _NO_PROTO */ This means that repo-config.c is trying to redefine the `regex' symbol. Here is a simple patch that just uses `regexp' as the symbol name instead. Signed-off-by: Amos Waterland <apw@us.ibm.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
* Rename git-config-set to git-repo-configJohannes Schindelin2005-11-24
... and adjust all references. Signed-off-by: Johannes Schindelin <Johannes.Schindelin@gmx.de> Signed-off-by: Junio C Hamano <junkio@cox.net>