Re: Branch Name Case Sensitivity

2014-03-05 Thread Lee Hopkins
Lee, could you improve your change in refs.c into a real patch, with a commit message? (And please have a look at the indentation with TABs) A test case could be good, if time allows I can make a suggestion. I will remove the refs.ignorecase flag and work on a test care or two, it will have

Re: Branch Name Case Sensitivity

2014-03-03 Thread Lee Hopkins
I don't think this distinction is necessary, either you have a case-insensitive file system or you don't. The case that the .git directory is case-sensitive and the worktree directory isn't (or the other way around) is probably so exotic that we can ignore it. I think Torsten's use case

Re: Branch Name Case Sensitivity

2014-03-01 Thread Lee Hopkins
Incorporating Torsten suggestions and some documentation: --- Documentation/config.txt | 12 builtin/init-db.c|4 +++- config.c |5 + environment.c|1 + refs.c | 26 +++--- 5 files changed,

Re: Branch Name Case Sensitivity

2014-02-28 Thread Lee Hopkins
If you are on a case-insensitive filesystem, or work on a cross-platform project, ensure that you avoid ambiguous refs. Problem solved. I agree this is the best solution, and I personally avoid the use of ambiguous refs. However, since there is nothing in git stopping the use of ambiguous refs,

Re: Branch Name Case Sensitivity

2014-02-28 Thread Lee Hopkins
I went ahead and took a stab at a solution. My solution is more aggressive than a warning, I actually prevent the creation of ambiguous refs. My changes are also in refs.c, which may not be appropriate, but it seemed like the natural place. I have never contributed to Git (in fact this is my

Re: Branch Name Case Sensitivity

2014-02-27 Thread Lee Hopkins
: Lee Hopkins leer...@gmail.com writes: Last week I ran across a potential bug with branch names on case insensitive file systems, the complete scenario can be found here: https://groups.google.com/forum/#!topic/msysgit/ugKL-sVMiqI The tldr is because refs are stored as plain text files

Re: Branch Name Case Sensitivity

2014-02-27 Thread Lee Hopkins
If I understand the issue correctly, the problem is that packed-refs are always case-sensitive, even if core.ignorecase=true. OTOH, checking / updating _unpacked_ refs on a case-insensitive file system is naturally case-insensitive. So wouldn't it be a better workaround to disallow packed

Branch Name Case Sensitivity

2014-02-26 Thread Lee Hopkins
Hello, Last week I ran across a potential bug with branch names on case insensitive file systems, the complete scenario can be found here: https://groups.google.com/forum/#!topic/msysgit/ugKL-sVMiqI The tldr is because refs are stored as plain text files except when packed into packed-refs, Git