This post will show you how to fix this git renaming failed: Permission denied error when you are trying to run the
git mv command.
Basically, you may hit this error when trying to rename a folder on case sensitive. For example, rename folder “example” to “EXAMPLE”.
git mv example EXAMPLE fatal: renaming 'example' failed: Permission denied
This error is still not disappeared although you have closed programs that may be working on this folder.
To solve the issue in a simple way, you can do the following two steps:
- Rename “example” to “tmp”
- Rename “tmp” to “EXAMPLE”
Here is the command how to do this:
git mv example tmp git mv tmp EXAMPLE