diff --git a/Documentation/config/add.txt b/Documentation/config/add.txt index c9f748f81c..3e859f3419 100644 --- a/Documentation/config/add.txt +++ b/Documentation/config/add.txt @@ -7,6 +7,6 @@ add.ignore-errors (deprecated):: variables. add.interactive.useBuiltin:: - [EXPERIMENTAL] Set to `true` to use the experimental built-in - implementation of the interactive version of linkgit:git-add[1] - instead of the Perl script version. Is `false` by default. + Set to `false` to fall back to the original Perl implementation of + the interactive version of linkgit:git-add[1] instead of the built-in + version. Is `true` by default. diff --git a/builtin/add.c b/builtin/add.c index ef6b619c45..8ef230a345 100644 --- a/builtin/add.c +++ b/builtin/add.c @@ -237,17 +237,12 @@ int run_add_interactive(const char *revision, const char *patch_mode, int use_builtin_add_i = git_env_bool("GIT_TEST_ADD_I_USE_BUILTIN", -1); - if (use_builtin_add_i < 0) { - int experimental; - if (!git_config_get_bool("add.interactive.usebuiltin", - &use_builtin_add_i)) - ; /* ok */ - else if (!git_config_get_bool("feature.experimental", &experimental) && - experimental) - use_builtin_add_i = 1; - } + if (use_builtin_add_i < 0 && + git_config_get_bool("add.interactive.usebuiltin", + &use_builtin_add_i)) + use_builtin_add_i = 1; - if (use_builtin_add_i == 1) { + if (use_builtin_add_i != 0) { enum add_p_mode mode; if (!patch_mode) diff --git a/ci/run-build-and-tests.sh b/ci/run-build-and-tests.sh index cc62616d80..660ebe8d10 100755 --- a/ci/run-build-and-tests.sh +++ b/ci/run-build-and-tests.sh @@ -29,7 +29,7 @@ linux-gcc) export GIT_TEST_COMMIT_GRAPH_CHANGED_PATHS=1 export GIT_TEST_MULTI_PACK_INDEX=1 export GIT_TEST_MULTI_PACK_INDEX_WRITE_BITMAP=1 - export GIT_TEST_ADD_I_USE_BUILTIN=1 + export GIT_TEST_ADD_I_USE_BUILTIN=0 export GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME=master export GIT_TEST_WRITE_REV_INDEX=1 export GIT_TEST_CHECKOUT_WORKERS=2 diff --git a/t/README b/t/README index 29f72354bf..2c22337d6e 100644 --- a/t/README +++ b/t/README @@ -419,7 +419,7 @@ the --sparse command-line argument. GIT_TEST_PRELOAD_INDEX= exercises the preload-index code path by overriding the minimum number of cache entries required per thread. -GIT_TEST_ADD_I_USE_BUILTIN=, when true, enables the +GIT_TEST_ADD_I_USE_BUILTIN=, when false, disables the built-in version of git add -i. See 'add.interactive.useBuiltin' in git-config(1). diff --git a/t/t2016-checkout-patch.sh b/t/t2016-checkout-patch.sh index 71c5a15be0..bc3f69b4b1 100755 --- a/t/t2016-checkout-patch.sh +++ b/t/t2016-checkout-patch.sh @@ -4,7 +4,7 @@ test_description='git checkout --patch' . ./lib-patch-mode.sh -if ! test_bool_env GIT_TEST_ADD_I_USE_BUILTIN false && ! test_have_prereq PERL +if ! test_bool_env GIT_TEST_ADD_I_USE_BUILTIN true && ! test_have_prereq PERL then skip_all='skipping interactive add tests, PERL not set' test_done