From: Junio C Hamano Date: Mon, 4 Aug 2025 15:10:32 +0000 (-0700) Subject: Merge branch 'ps/config-wo-the-repository' X-Git-Tag: v2.51.0-rc0~10 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=540aaa607c5efcd94bb852a76a8ec3e07ea9a7bc;p=thirdparty%2Fgit.git Merge branch 'ps/config-wo-the-repository' The config API had a set of convenience wrapper functions that implicitly use the_repository instance; they have been removed and inlined at the calling sites. * ps/config-wo-the-repository: (21 commits) config: fix sign comparison warnings config: move Git config parsing into "environment.c" config: remove unused `the_repository` wrappers config: drop `git_config_set_multivar()` wrapper config: drop `git_config_get_multivar_gently()` wrapper config: drop `git_config_set_multivar_in_file_gently()` wrapper config: drop `git_config_set_in_file_gently()` wrapper config: drop `git_config_set()` wrapper config: drop `git_config_set_gently()` wrapper config: drop `git_config_set_in_file()` wrapper config: drop `git_config_get_bool()` wrapper config: drop `git_config_get_ulong()` wrapper config: drop `git_config_get_int()` wrapper config: drop `git_config_get_string()` wrapper config: drop `git_config_get_string()` wrapper config: drop `git_config_get_string_multi()` wrapper config: drop `git_config_get_value()` wrapper config: drop `git_config_get_value()` wrapper config: drop `git_config_get()` wrapper config: drop `git_config_clear()` wrapper ... --- 540aaa607c5efcd94bb852a76a8ec3e07ea9a7bc diff --cc builtin/remote.c index 5dd6cbbaee,4c63a8bb57..43a122740a --- a/builtin/remote.c +++ b/builtin/remote.c @@@ -223,10 -208,8 +223,10 @@@ static int add(int argc, const char **a if (!valid_remote_name(name)) die(_("'%s' is not a valid remote name"), name); + for_each_remote(check_remote_collision, (void *)name); + strbuf_addf(&buf, "remote.%s.url", name); - git_config_set(buf.buf, url); + repo_config_set(the_repository, buf.buf, url); if (!mirror || mirror & MIRROR_FETCH) { strbuf_reset(&buf);