threads / discuss / 45405

File names are considered case insensitive in a folder. (aBcd.py ==AbcD.py) Inbox x

Subject: File names are considered case insensitive in a folder. (aBcd.py ==AbcD.py) Inbox x

## tl;dr

2 messages between Mar 17, 2017 and Mar 17, 2017.

replies: 1people: 2as markdown or json

Vish Gite· Mar 17, 2017, 09:28 UTC · lore
Hello,

Git 2.10.1 on Apple mac is treating different(uppercase/lowercase) files as same name(e.g ABCD.py and abcd.py)

In a project where file name is same but case is different, either ABCD.py or abcd.py. There is always one of these files is modified.

Below is the git version on my mac. snappy:myproject$ git version git version 2.10.1 (Apple Git-78)

Where as git 2.7.4 on Linux Ubuntu xenial is treating ABCD.py and abcd.py as different files.

To reproduce the issue on mac. Clone a project that has two files in same directory with same name but different case. ClassTest.py and classtest.py

Thanks, Vishnu

Torsten Bögershausen· Mar 17, 2017, 11:19 UTC · re: Vish Gite · lore

Re: File names are considered case insensitive in a folder. (aBcd.py ==AbcD.py) Inbox x

On 17/03/17 10:28, Vish Gite wrote:
Show 22 quoted lines
> Hello,
>
> Git 2.10.1 on Apple mac is treating different(uppercase/lowercase)
> files as same name(e.g ABCD.py and abcd.py)
>
> In a project where file name is same but case is different, either
> ABCD.py or abcd.py. There is always one of these files is modified.
>
> Below is the git version on my mac.
> snappy:myproject$ git version
> git version 2.10.1 (Apple Git-78)
>
> Where as git 2.7.4 on Linux Ubuntu xenial is treating ABCD.py and
> abcd.py as different files.
>
> To reproduce the issue on mac. Clone a project that has two files in
> same directory with same name but different case. ClassTest.py and
> classtest.py
>
>
> Thanks,
> Vishnu

This is a know problem, which is not caused by Git, but caused by the underlying file system,

which treats ABCD.py and abcd.py the same.
Git can not do anything about it.

If you want to do cross platform, the only chance to do this is to avoid this kind of name collision.

← back to recent threads