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

[PATCH] t1305: fix include by absolute path test on Windows

From
Johannes Sixt <j.sixt@viscovery.net>
Date
Feb 17, 2012, 08:31 UTC
Message-ID
<4F3E1064.5080603@viscovery.net>
From: Johannes Sixt <j6t@kdbg.org>

Git on Windows does not understand bash's /c/dir/... POSIXy paths, so that the test fails. Ensure that the config file mentions the Windows style absolute path to the file to be included.

Signed-off-by: Johannes Sixt <j6t@kdbg.org>
---
 Feel free to squash this into the patch that adds the test.
 t/t1305-config-include.sh |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/t/t1305-config-include.sh b/t/t1305-config-include.sh
index f3e03a0..4b1cbaa 100755
--- a/t/t1305-config-include.sh
+++ b/t/t1305-config-include.sh
@@ -5,7 +5,7 @@ test_description='test config file include directives'
 
 test_expect_success 'include file by absolute path' '
 	echo "[test]one = 1" >one &&
-	echo "[include]path = \"$PWD/one\"" >.gitconfig &&
+	echo "[include]path = \"$(pwd)/one\"" >.gitconfig &&
 	echo 1 >expect &&
 	git config test.one >actual &&
 	test_cmp expect actual
-- 
1.7.9.1264.g9b7e2
Message 1 of 1 in “t1305: fix include by absolute path test on Windows”
  1. t1305: fix include by absolute path test on WindowsJohannes Sixt, Feb 17, 2012

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.