Merge branch 'jc/add-i-retire-usebuiltin-config'

For over a year, setting add.interactive.useBuiltin configuration
variable did nothing but giving a "this does not do anything"
warning.  Finally remove it.

* jc/add-i-retire-usebuiltin-config:
  add-i: finally retire add.interactive.useBuiltin
This commit is contained in:
Junio C Hamano 2024-06-24 16:39:14 -07:00
commit 2c4aa7ad74
3 changed files with 1 additions and 26 deletions

View file

@ -5,9 +5,3 @@ add.ignore-errors (deprecated)::
option of linkgit:git-add[1]. `add.ignore-errors` is deprecated,
as it does not follow the usual naming convention for configuration
variables.
add.interactive.useBuiltin::
Unused configuration variable. Used in Git versions v2.25.0 to
v2.36.0 to enable the built-in version of linkgit:git-add[1]'s
interactive mode, which then became the default in Git
versions v2.37.0 to v2.39.0.

View file

@ -150,11 +150,7 @@ static int refresh(int verbose, const struct pathspec *pathspec)
int interactive_add(const char **argv, const char *prefix, int patch)
{
struct pathspec pathspec;
int unused, ret;
if (!git_config_get_bool("add.interactive.usebuiltin", &unused))
warning(_("the add.interactive.useBuiltin setting has been removed!\n"
"See its entry in 'git help config' for details."));
int ret;
parse_pathspec(&pathspec, 0,
PATHSPEC_PREFER_FULL |

View file

@ -43,21 +43,6 @@ force_color () {
)
}
test_expect_success 'warn about add.interactive.useBuiltin' '
cat >expect <<-\EOF &&
warning: the add.interactive.useBuiltin setting has been removed!
See its entry in '\''git help config'\'' for details.
EOF
echo "No changes." >expect.out &&
for v in = =true =false
do
git -c "add.interactive.useBuiltin$v" add -p >out 2>actual &&
test_cmp expect.out out &&
test_cmp expect actual || return 1
done
'
test_expect_success 'unknown command' '
test_when_finished "git reset --hard; rm -f command" &&
echo W >command &&