зеркало из https://github.com/microsoft/git.git
stash: stop warning about the obsolete `stash.useBuiltin` config setting
In 8a2cd3f512
(stash: remove the stash.useBuiltin setting, 2020-03-03),
we removed support for `stash.useBuiltin`, but left a warning in its
place.
After almost two years, and several major versions, it is time to remove
even that warning.
Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
Родитель
deeaf5ee07
Коммит
e9b272e4c1
|
@ -788,7 +788,6 @@ static int list_stash(int argc, const char **argv, const char *prefix)
|
|||
static int show_stat = 1;
|
||||
static int show_patch;
|
||||
static int show_include_untracked;
|
||||
static int use_legacy_stash;
|
||||
|
||||
static int git_stash_config(const char *var, const char *value, void *cb)
|
||||
{
|
||||
|
@ -804,10 +803,6 @@ static int git_stash_config(const char *var, const char *value, void *cb)
|
|||
show_include_untracked = git_config_bool(var, value);
|
||||
return 0;
|
||||
}
|
||||
if (!strcmp(var, "stash.usebuiltin")) {
|
||||
use_legacy_stash = !git_config_bool(var, value);
|
||||
return 0;
|
||||
}
|
||||
return git_diff_basic_config(var, value, cb);
|
||||
}
|
||||
|
||||
|
@ -1778,11 +1773,6 @@ int cmd_stash(int argc, const char **argv, const char *prefix)
|
|||
|
||||
git_config(git_stash_config, NULL);
|
||||
|
||||
if (use_legacy_stash ||
|
||||
!git_env_bool("GIT_TEST_STASH_USE_BUILTIN", -1))
|
||||
warning(_("the stash.useBuiltin support has been removed!\n"
|
||||
"See its entry in 'git help config' for details."));
|
||||
|
||||
argc = parse_options(argc, argv, prefix, options, git_stash_usage,
|
||||
PARSE_OPT_KEEP_UNKNOWN | PARSE_OPT_KEEP_DASHDASH);
|
||||
|
||||
|
|
|
@ -1272,7 +1272,6 @@ test_expect_success 'stash works when user.name and user.email are not set' '
|
|||
>2 &&
|
||||
git add 2 &&
|
||||
test_config user.useconfigonly true &&
|
||||
test_config stash.usebuiltin true &&
|
||||
(
|
||||
sane_unset GIT_AUTHOR_NAME &&
|
||||
sane_unset GIT_AUTHOR_EMAIL &&
|
||||
|
@ -1323,20 +1322,6 @@ test_expect_success 'stash handles skip-worktree entries nicely' '
|
|||
git rev-parse --verify refs/stash:A.t
|
||||
'
|
||||
|
||||
test_expect_success 'stash -c stash.useBuiltin=false warning ' '
|
||||
expected="stash.useBuiltin support has been removed" &&
|
||||
|
||||
git -c stash.useBuiltin=false stash 2>err &&
|
||||
test_i18ngrep "$expected" err &&
|
||||
env GIT_TEST_STASH_USE_BUILTIN=false git stash 2>err &&
|
||||
test_i18ngrep "$expected" err &&
|
||||
|
||||
git -c stash.useBuiltin=true stash 2>err &&
|
||||
test_must_be_empty err &&
|
||||
env GIT_TEST_STASH_USE_BUILTIN=true git stash 2>err &&
|
||||
test_must_be_empty err
|
||||
'
|
||||
|
||||
test_expect_success 'git stash succeeds despite directory/file change' '
|
||||
test_create_repo directory_file_switch_v1 &&
|
||||
(
|
||||
|
|
Загрузка…
Ссылка в новой задаче