Renaming a file isn't properly handled in git Follow
I recently used the "Rename" function on a file's context menu in the Refactor submenu. It worked great to update references in my code, but I noticed an issue when I was organizing a commit in git.
The original file was removed and the new one was added thereby destroying version history. This was equivalent to the following comands in Bash:
The original file was removed and the new one was added thereby destroying version history. This was equivalent to the following comands in Bash:
cat original_file.py > new_file.py rm original_file.pyprettyPrint(); Instead, this should have been done through git to retain the version history:
git mv original_file.py new_file.pyprettyPrint();
Please sign in to leave a comment.
http://stackoverflow.com/questions/7938582/how-does-git-detect-similar-files-for-its-rename-detection