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

Re: Trouble with case-insensitive filesystems

From
Jeff King <peff@peff.net>
Date
Oct 26, 2007, 16:34 UTC
Message-ID
<20071026163450.GA19673@coredump.intra.peff.net>
In-Reply-To
<4722064C.1000201@op5.se>
On Fri, Oct 26, 2007 at 05:22:52PM +0200, Andreas Ericsson wrote:
> There are no areas in git to patch. There's no sane way to handle your
> case, so the best you could opt for is to import it to a system with
> sane case-handling, alter the repo so no two filenames clash, and then
> check it out on your case-insensitive filesystem. Note that you'll
You don't need a sane system, since git's index provides one:
  # make our new repo without checking anything out
  git-clone -n /path/to/other/repo repo
  cd repo
  # grab a text representation of what would be checked out
  git-ls-tree -r HEAD >files
  # fix up any broken filenames
  $EDITOR files
  # and shove it into the index
  git-update-index --index-info <files
  # update your working tree
  git-checkout-index -a
  # and optionally save the commit
  git-commit -m 'broken filenames hack'

Of course, all of the prior commits won't be usable. You would have to repeat this hack on every commit using git-filter-branch for that.

-Peff
Previous: Rocco RutteNext: Jean-François Veillette
Message 4 of 5 in “Trouble with case-insensitive filesystems”
  1. Rocco RutteOct 26, 2007
  2. Andreas EricssonOct 26, 2007
  3. Rocco RutteOct 26, 2007
  4. Jeff KingOct 26, 2007
  5. Jean-François VeilletteOct 26, 2007

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.