Q:

Move file in git without move

A script I need to execute moves a few hundred files in my repository from one location to another (but they stay in the repo). I know where the files came from, and where they are after the ove.
But git mv wants to move the files on its own. Is there any way to use git mv telling it that the move operation was already done?

A:

Git will automatically identify moves on its own even if you don't use git mv, as long as you stage both the deleted and the new file.
In fact, Git uses only the contents of files to sort out what is a move. Therefore, git mv is just a shorthand for the above.

