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

[PATCH v2 2/4] t3432: use git-reflog to inspect the reflog for HEAD

From
Han-Wen Nienhuys via GitGitGadget <gitgitgadget@gmail.com>
Date
Jul 10, 2020, 17:19 UTC
Message-ID
<123d246edf9e3e40c321cfaff81fe96ae3a0c015.1594401593.git.gitgitgadget@gmail.com>
In-Reply-To
<pull.669.v2.git.1594401593.gitgitgadget@gmail.com>
From: Han-Wen Nienhuys <hanwen@google.com>
Signed-off-by: Han-Wen Nienhuys <hanwen@google.com>
---
 t/t3432-rebase-fast-forward.sh | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)
diff --git a/t/t3432-rebase-fast-forward.sh b/t/t3432-rebase-fast-forward.sh
index 6f0452c0ea..a29eda87e9 100755
--- a/t/t3432-rebase-fast-forward.sh
+++ b/t/t3432-rebase-fast-forward.sh
@@ -60,15 +60,16 @@ test_rebase_same_head_ () {
 		fi &&
 		oldhead=\$(git rev-parse HEAD) &&
 		test_when_finished 'git reset --hard \$oldhead' &&
-		cp .git/logs/HEAD expect &&
+		git reflog HEAD >expect &&
 		git rebase$flag $* >stdout &&
+		git reflog HEAD >actual &&
 		if test $what = work
 		then
 			old=\$(wc -l <expect) &&
-			test_line_count '-gt' \$old .git/logs/HEAD
+			test_line_count '-gt' \$old actual
 		elif test $what = noop
 		then
-			test_cmp expect .git/logs/HEAD
+			test_cmp expect actual
 		fi &&
 		newhead=\$(git rev-parse HEAD) &&
 		if test $cmp = same
-- 
gitgitgadget
Previous: Han-Wen Nienhuys via GitGitGadgetNext: Junio C Hamano via GitGitGadget
Message 10 of 13 in “Preliminary fixes for reftable support”
  1. 0/4 Preliminary fixes for reftable supportHan-Wen Nienhuys via GitGitGadget, Jun 30, 2020
  2. 1/4 lib-t6000.sh: write tag using git-update-refHan-Wen Nienhuys via GitGitGadget, Jun 30, 2020
  3. 2/4 t3432: use git-reflog to inspect the reflog for HEADHan-Wen Nienhuys via GitGitGadget, Jun 30, 2020
  4. 3/4 checkout: add '\n' to reflog messageHan-Wen Nienhuys via GitGitGadget, Jun 30, 2020
  5. 4/4 Treat BISECT_HEAD as a pseudo refHan-Wen Nienhuys via GitGitGadget, Jun 30, 2020
  6. Junio C HamanoJul 7, 2020
  7. 0/4 Preliminary fixes for reftable supportHan-Wen Nienhuys via GitGitGadget, Jul 10, 2020
  8. 1/4 lib-t6000.sh: write tag using git-update-refHan-Wen Nienhuys via GitGitGadget, Jul 10, 2020
  9. 3/4 Treat BISECT_HEAD as a pseudo refHan-Wen Nienhuys via GitGitGadget, Jul 10, 2020
  10. 2/4 t3432: use git-reflog to inspect the reflog for HEADHan-Wen Nienhuys via GitGitGadget, Jul 10, 2020
  11. 4/4 Cleanse reflog messages in the refs.c layerJunio C Hamano via GitGitGadget, Jul 10, 2020
  12. Junio C HamanoJul 10, 2020
  13. Junio C HamanoJul 10, 2020

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.