"Shawn O. Pearce" <spearce@xxxxxxxxxxx> wrote: > To avoid deleting refs used by another remote we only clear refs > that are unique to this remote. This prevents `git prune rm alt` > from removing the refs used by say origin if alt was just using a > different URL for the same repository. Hmm. You probably should squash this test case into that patch. --8<-- diff --git a/t/t5505-remote.sh b/t/t5505-remote.sh index 0d7ed1f..96e461b 100755 --- a/t/t5505-remote.sh +++ b/t/t5505-remote.sh @@ -182,6 +182,18 @@ test_expect_success 'add alt && prune' ' git rev-parse --verify refs/remotes/origin/side2) ' +test_expect_success 'rm alt' ' + (cd alttst && + git remote rm alt && + tokens_match z z$(git config remote.alt.url) && + tokens_match z z$(git config remote.alt.fetch) && + git rev-parse --verify refs/remotes/origin/side2 && + git remote rm origin && + tokens_match z z$(git config remote.alt.url) && + tokens_match z z$(git config remote.alt.fetch) && + ! git rev-parse --verify refs/remotes/origin/side2) +' + cat > one/expect << EOF apis/master apis/side -- Shawn. -- 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