Git case sensitive
Emmanuel Gautier / November 06, 2018
1 min read
Today, I was wondering to know why on the CI pipeline, tests were failing due to missing files but those files are on the file system locally and push on the GIT repository. This issue came from files renamed updating from lowercase to uppercase.
Windows & OSX file systems are not case sensitive. So if you are one user of one of these two operating systems, here the two solutions you can use.
One simple workaround is to use the git mv
command as follows:
git mv camelcase camelCase
git commit -m "fix camelCase name"
Another solution you can use is to configure GIT to be case sensitive with the current files system type.
From this documentation de git-config
Internal variable which enables various workarounds to enable Git to work better on filesystems that are not case sensitive, like APFS, HFS+, FAT, NTFS, etc. For example, if a directory listing finds "makefile" when Git expects "Makefile", Git will assume it is really the same file, and continue to remember it as "Makefile".
To enable it, assign the value false
to core.ignoreCase
config
git config core.ignorecase false
Subscribe to the newsletter
Get emails from me about web development and a lot of topics related to tech.
Related Posts
Succeeding understanding tech as a non-technical person
It exists a lot of technical terms. If you want to better understand the product team, you are at the right place.
MySQL Docker Image for Mac ARM M1
Apple ARM M1 issue is that number of software are not compatible with the microarchitecture ARMv8 like MySQL official Docker image for example. Here a solution.
Undo a git add
An unwanted " git add " can happen. That's why there is a command to redo this " git add ". Here the command line to perform this action.
Featured Posts
How to deal with Docker Hub rate limit on AWS
Since 2020, DockerHub has been limited to only 200 container image pull requests per six hours. This article will help you to deal with this limitation on AWS.
How to enable Python type checking in VSCode
Python now has support for type hints. In this article, we will see how to enable better IntelliSense and type checking analysis in VSCode.
How to manage Internationalization with NextJS SSG
Staticaly generating a website with the NextJS framework in different languages is not so obvious.