On Tue, Jul 28, 2015 at 3:59 PM, Jeff King <peff@xxxxxxxx> wrote: > If you hide a hierarchy of refs using the transfer.hideRefs > config, there is no way to later override that config to > "unhide" it. This patch implements a "negative" hide which > causes matches to immediately be marked as unhidden, even if > another match would hide it. We take care to apply the > matches in reverse-order from how they are fed to us by the > config machinery, as that lets our usual "last one wins" > config precedence work (and entries in .git/config, for > example, will override /etc/gitconfig). > > Signed-off-by: Jeff King <peff@xxxxxxxx> > --- > +test_expect_success 'set up some extra tags for ref hiding' ' > + git tag magic/one && > + git tag magic/two > +' > + > for configsection in transfer uploadpack > do > test_expect_success "Hide some refs with $configsection.hiderefs" ' > @@ -138,6 +143,16 @@ do > sed -e "/ refs\/tags\//d" >expect && > test_cmp expect actual > ' > + > + test_expect_success "Override hiding of $configsection.hiderefs" ' > + test_when_finished "test_unconfig $configsection.hiderefs" && > + git config --add $configsection.hiderefs refs/tags && > + git config --add $configsection.hiderefs "!refs/tags/magic" && > + git config --add $configsection.hiderefs refs/tags/magic/one && > + git ls-remote . >actual && > + verbose grep refs/tags/magic/two actual For completeness, do you also want to add !grep refs/tags/magic/one actual to confirm that the third hideRefs did indeed override the second one? > + ' > + > done > > test_done > -- > 2.5.0.rc3.557.g17a1555 -- To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html