dusty-phillips / gitifyhg

Tools for using git as a client to mercurial repositories
GNU General Public License v3.0
62 stars 17 forks source link

repo clones incorrectly on case-insensitive fs when repo contains case-only rename #95

Open dlitz opened 11 years ago

dlitz commented 11 years ago

Let's say I'm cloning a repo on a case-insensitive filesystem (i.e. Mac OS X). If the repo contains a case-only rename, the file seems to disappear entirely.

Example repo: https://bitbucket.org/ronaldoussoren/altgraph Case-only rename (ReadMe.txt -> README.txt): https://bitbucket.org/ronaldoussoren/altgraph/commits/d5b57fd29a646d7f70384b067f0f218a7bdcaf83

My guess is that README.txt was added before ReadMe.txt was deleted, but the filesystem's case-folding broke it. It could probably be fixed by processing deleted files before added files.

felipec commented 10 years ago

Yeah. That's why git-remote-hg does.

I've ported the code https://github.com/felipec/gitifyhg/commit/0c0c0772fb4cffd104d7518fef857b5e9889f0dc.