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

Re: [ANNOUNCE] Git v2.50.1 and friends

From
Todd Zullinger <tmz@pobox.com>
Date
Jul 8, 2025, 20:28 UTC
Message-ID
<aG1_eqSpH46UddZJ@teonanacatl.net>
In-Reply-To
<xmqqzfdevcov.fsf@gitster.g>
Junio C Hamano wrote:
> A maintenance release Git v2.50.1 and others for older maintenance
> tracks down to maint-2.43 are now available at the usual places.

I was building v2.45.4 on an older system and two tests failed:

    t1300.237 writing value with trailing CR not stripped on read
    t7450.50  submodule must not checkout into different directory

These both look like they use new git config syntax (get, set, unset) which is not available in the older releases.

I haven't done enough digging to determine when the syntax changed to prepare a proper patch, but I thought I'd mention it, in case anyone else runs into a similar issue or is highly motivated to work up a patch against which ever older releases need it.

The fix looks something like this, I believe:
-- >8 --
diff --git i/t/t1300-config.sh w/t/t1300-config.sh
index 00f34c5a01..3ed4a0b1ce 100755
--- i/t/t1300-config.sh
+++ w/t/t1300-config.sh
@@ -2743,8 +2743,8 @@ test_expect_success 'writing value with trailing CR not stripped on read' '
 
 	printf "bar\r\n" >expect &&
 	git init cr-test &&
-	git -C cr-test config set core.foo $(printf "bar\r") &&
-	git -C cr-test config get core.foo >actual &&
+	git -C cr-test config core.foo $(printf "bar\r") &&
+	git -C cr-test config --get core.foo >actual &&
 
 	test_cmp expect actual
 '
diff --git i/t/t7450-bad-git-dotfiles.sh w/t/t7450-bad-git-dotfiles.sh
index ff63c05652..38b9db85cd 100755
--- i/t/t7450-bad-git-dotfiles.sh
+++ w/t/t7450-bad-git-dotfiles.sh
@@ -388,10 +388,10 @@ test_expect_success SYMLINKS,!WINDOWS,!MINGW 'submodule must not checkout into d
 	git -C repo mv sub $(printf "sub\r") &&
 
 	# Ensure config values containing CR are wrapped in quotes.
-	git config unset -f repo/.gitmodules submodule.sub.path &&
+	git config --unset -f repo/.gitmodules submodule.sub.path &&
 	printf "\tpath = \"sub\r\"\n" >>repo/.gitmodules &&
 
-	git config unset -f repo/.git/modules/sub/config core.worktree &&
+	git config --unset -f repo/.git/modules/sub/config core.worktree &&
 	{
 		printf "[core]\n" &&
 		printf "\tworktree = \"../../../sub\r\"\n"
-- 
Todd
Previous: Junio C HamanoNext: Todd Zullinger
Message 2 of 6 in “[ANNOUNCE] Git v2.50.1 and friends”
  1. Junio C HamanoJul 8, 2025
  2. Todd ZullingerJul 8, 2025
  3. t: avoid git config syntax from newer releasesTodd Zullinger, Jul 8, 2025
  4. Junio C HamanoJul 8, 2025
  5. Justin ToblerJul 9, 2025
  6. Todd ZullingerJul 9, 2025

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.