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

Re: [PATCH] fast-export: quote paths in output

From
Johannes Sixt <j.sixt@viscovery.net>
Date
Aug 5, 2011, 11:12 UTC
Message-ID
<4E3BD006.6010005@viscovery.net>
In-Reply-To
<20110805105526.GA22480@sigill.intra.peff.net>
Am 8/5/2011 12:55, schrieb Jeff King:
Show 7 quoted lines
> +test_expect_success 'fast-export quotes pathnames' '
> +	git init crazy-paths &&
> +	(cd crazy-paths &&
> +	 >"$(printf "path with\\nnewline")" &&
> +	 >"path with \"quote\"" &&
> +	 >"path with \\backslash" &&
> +	 >"path with space" &&

Please construct the tree object using git-update-index's --cacheinfo or --index-info rather than using actual files and git add so that the test can pass on filesystems that do not allow newlines, quotes, or backslashes(!) in filenames.

-- Hannes
-- 
"Atomic objects are neither active nor radioactive." --
Programming Languages -- C++, Final Committee Draft (Doc.N3092)
Previous: Jeff KingNext: Jeff King
Message 2 of 5 in “fast-export: quote paths in output”
  1. fast-export: quote paths in outputJeff King, Aug 5, 2011
  2. Johannes SixtAug 5, 2011
  3. Jeff KingAug 5, 2011
  4. Junio C HamanoAug 5, 2011
  5. Jeff KingAug 6, 2011

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.