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

Re: Cygwin error?

From
Andreas Ericsson <ae@op5.se>
Date
Nov 20, 2008, 08:57 UTC
Message-ID
<49252669.7060304@op5.se>
In-Reply-To
<200811191857.30793.nadim@khemir.net>
nadim khemir wrote:
Show 18 quoted lines
> Hi, Given:
> 
> $ git pull
> remote: Counting objects: 46, done.
> ...
> Updating b80286d..a543dae
> error: Untracked working tree file 'xxx.txt' would be overwritten by merge.
> 
> 
> This is due to a rename of xxx.txt to Xxx.txt. I  understand that this is due 
> to files being just case preserving on Cycwin/Win32.
> 
> The only I found was to remove the xxx.txt localy and do a pull. The 
> interresting thing is that Xxx.txt is no present in my file system. I can 
> check it out from HEAD though.
> 
> What did I missunderstood and do wrong?
> 

You ran into a corner-case. Git expects the "Xxx.txt" and "xxx.txt" to be different. Cross-OS projects should never, ever rename files so that they end up with case ambiguity. Since they did, the only thing you can really do is this:

git fetch rm xxx.txt git reset --hard origin/master; # or whatever branch you're interested in

I'm afraid you'll have problems with this until all the branches you're interested in have this change.

-- 
Andreas Ericsson                   andreas.ericsson@op5.se
OP5 AB                             www.op5.se
Tel: +46 8-230225                  Fax: +46 8-230231
Previous: nadim khemir
Message 2 of 2 in “Cygwin error?”
  1. nadim khemirNov 19, 2008
  2. Andreas EricssonNov 20, 2008

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.