git/list[1] front-page[2] threads[3] people[4] search[5] about
 

[PATCH] t9104: kosherly remove remote refs

From
Christian Couder <christian.couder@gmail.com>
Date
Jun 1, 2018, 05:08 UTC
Message-ID
<20180601050833.27676-1-chriscool@tuxfamily.org>

As there are plans to implement other ref storage systems, let's use a way to remove remote refs that does not depend on refs being files.

This makes it clear to readers that this test does not depend on which ref backend is used.

Suggested-by: Michael Haggerty <mhagger@alum.mit.edu>
Helped-by: Jeff King <peff@peff.net>
Signed-off-by: Christian Couder <chriscool@tuxfamily.org>
---
This was suggested and discussed in:
https://public-inbox.org/git/20180525085906.GA2948@sigill.intra.peff.net/
 t/t9104-git-svn-follow-parent.sh | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/t/t9104-git-svn-follow-parent.sh b/t/t9104-git-svn-follow-parent.sh
index 9c49b6c1fe..5e0ad19177 100755
--- a/t/t9104-git-svn-follow-parent.sh
+++ b/t/t9104-git-svn-follow-parent.sh
@@ -215,7 +215,9 @@ test_expect_success "multi-fetch continues to work" "
 	"
 
 test_expect_success "multi-fetch works off a 'clean' repository" '
-	rm -rf "$GIT_DIR/svn" "$GIT_DIR/refs/remotes" &&
+	rm -rf "$GIT_DIR/svn" &&
+	git for-each-ref --format="option no-deref%0adelete %(refname)" refs/remotes |
+	git update-ref --stdin &&
 	git reflog expire --all --expire=all &&
 	mkdir "$GIT_DIR/svn" &&
 	git svn multi-fetch
-- 
2.17.0.1035.g12039e008f
Next: Johannes Schindelin
Message 1 of 4 in “t9104: kosherly remove remote refs”
  1. t9104: kosherly remove remote refsChristian Couder, Jun 1, 2018
  2. Johannes SchindelinJun 1, 2018
  3. Michael HaggertyJun 2, 2018
  4. SZEDER GáborJun 2, 2018

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.