maintenance: stop writing log.excludeDecoration
This reverts commit 96eaffebbf
(maintenance: set
log.excludeDecoration durin prefetch, 2021-01-19).
The previous change created a default decoration filter that does not
include refs/prefetch/, so this modification of the config is no longer
needed.
One issue that can happen from this point on is that users who ran the
prefetch task on previous versions of Git will still have a
log.excludeDecoration value and that will prevent the new default
decoration filter from being active. Thus, when we add the refs/bundle/
namespace as part of the bundle URI feature, those users will see
refs/bundle/ decorations.
Signed-off-by: Derrick Stolee <derrickstolee@github.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
maint
parent
3e103ed23f
commit
863a8ae97b
|
@ -904,12 +904,6 @@ static int fetch_remote(struct remote *remote, void *cbdata)
|
|||
|
||||
static int maintenance_task_prefetch(struct maintenance_run_opts *opts)
|
||||
{
|
||||
git_config_set_multivar_gently("log.excludedecoration",
|
||||
"refs/prefetch/",
|
||||
"refs/prefetch/",
|
||||
CONFIG_FLAGS_FIXED_VALUE |
|
||||
CONFIG_FLAGS_MULTI_REPLACE);
|
||||
|
||||
if (for_each_remote(fetch_remote, opts)) {
|
||||
error(_("failed to prefetch remotes"));
|
||||
return 1;
|
||||
|
|
|
@ -162,7 +162,6 @@ test_expect_success 'prefetch multiple remotes' '
|
|||
test_cmp_rev refs/remotes/remote1/one refs/prefetch/remotes/remote1/one &&
|
||||
test_cmp_rev refs/remotes/remote2/two refs/prefetch/remotes/remote2/two &&
|
||||
|
||||
test_cmp_config refs/prefetch/ log.excludedecoration &&
|
||||
git log --oneline --decorate --all >log &&
|
||||
! grep "prefetch" log &&
|
||||
|
||||
|
@ -173,26 +172,6 @@ test_expect_success 'prefetch multiple remotes' '
|
|||
test_subcommand git fetch remote2 $fetchargs <skip-remote1.txt
|
||||
'
|
||||
|
||||
test_expect_success 'prefetch and existing log.excludeDecoration values' '
|
||||
git config --unset-all log.excludeDecoration &&
|
||||
git config log.excludeDecoration refs/remotes/remote1/ &&
|
||||
git maintenance run --task=prefetch &&
|
||||
|
||||
git config --get-all log.excludeDecoration >out &&
|
||||
grep refs/remotes/remote1/ out &&
|
||||
grep refs/prefetch/ out &&
|
||||
|
||||
git log --oneline --decorate --all >log &&
|
||||
! grep "prefetch" log &&
|
||||
! grep "remote1" log &&
|
||||
grep "remote2" log &&
|
||||
|
||||
# a second run does not change the config
|
||||
git maintenance run --task=prefetch &&
|
||||
git log --oneline --decorate --all >log2 &&
|
||||
test_cmp log log2
|
||||
'
|
||||
|
||||
test_expect_success 'loose-objects task' '
|
||||
# Repack everything so we know the state of the object dir
|
||||
git repack -adk &&
|
||||
|
|
Loading…
Reference in New Issue