Skip to content

Commit ecffa3e

Browse files
LemmingAvalanchegitster
authored andcommitted
config: rename global config function
Rename this function to a more descriptive name since we want to use the existing name for a new function. Signed-off-by: Kristoffer Haugsbakk <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent 4ef97dc commit ecffa3e

File tree

5 files changed

+7
-7
lines changed

5 files changed

+7
-7
lines changed

builtin/config.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -710,7 +710,7 @@ int cmd_config(int argc, const char **argv, const char *prefix)
710710
if (use_global_config) {
711711
char *user_config, *xdg_config;
712712

713-
git_global_config(&user_config, &xdg_config);
713+
git_global_config_paths(&user_config, &xdg_config);
714714
if (!user_config)
715715
/*
716716
* It is unknown if HOME/.gitconfig exists, so

builtin/gc.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1546,7 +1546,7 @@ static int maintenance_register(int argc, const char **argv, const char *prefix)
15461546
char *user_config = NULL, *xdg_config = NULL;
15471547

15481548
if (!config_file) {
1549-
git_global_config(&user_config, &xdg_config);
1549+
git_global_config_paths(&user_config, &xdg_config);
15501550
config_file = user_config;
15511551
if (!user_config)
15521552
die(_("$HOME not set"));
@@ -1614,7 +1614,7 @@ static int maintenance_unregister(int argc, const char **argv, const char *prefi
16141614
int rc;
16151615
char *user_config = NULL, *xdg_config = NULL;
16161616
if (!config_file) {
1617-
git_global_config(&user_config, &xdg_config);
1617+
git_global_config_paths(&user_config, &xdg_config);
16181618
config_file = user_config;
16191619
if (!user_config)
16201620
die(_("$HOME not set"));

builtin/var.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,7 @@ static char *git_config_val_global(int ident_flag UNUSED)
9090
char *user, *xdg;
9191
size_t unused;
9292

93-
git_global_config(&user, &xdg);
93+
git_global_config_paths(&user, &xdg);
9494
if (xdg && *xdg) {
9595
normalize_path_copy(xdg, xdg);
9696
strbuf_addf(&buf, "%s\n", xdg);

config.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1987,7 +1987,7 @@ char *git_system_config(void)
19871987
return system_config;
19881988
}
19891989

1990-
void git_global_config(char **user_out, char **xdg_out)
1990+
void git_global_config_paths(char **user_out, char **xdg_out)
19911991
{
19921992
char *user_config = xstrdup_or_null(getenv("GIT_CONFIG_GLOBAL"));
19931993
char *xdg_config = NULL;
@@ -2040,7 +2040,7 @@ static int do_git_config_sequence(const struct config_options *opts,
20402040
data, CONFIG_SCOPE_SYSTEM,
20412041
NULL);
20422042

2043-
git_global_config(&user_config, &xdg_config);
2043+
git_global_config_paths(&user_config, &xdg_config);
20442044

20452045
if (xdg_config && !access_or_die(xdg_config, R_OK, ACCESS_EACCES_OK))
20462046
ret += git_config_from_file_with_options(fn, xdg_config, data,

config.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -382,7 +382,7 @@ int config_error_nonbool(const char *);
382382
#endif
383383

384384
char *git_system_config(void);
385-
void git_global_config(char **user, char **xdg);
385+
void git_global_config_paths(char **user, char **xdg);
386386

387387
int git_config_parse_parameter(const char *, config_fn_t fn, void *data);
388388

0 commit comments

Comments
 (0)