Saturday, October 15, 2011

Git Moving/Renaming Files inside Repository

Tracking the Moved or Renamed Files is a Problem for all Version Control Systems and so for Git too. The Easiest way to Move or Rename a File in Git is:
git mv fileIntoAccount
But if your File has been Already Moved or Renamed you need the Double Step Process:
git rm fileIntoAccount
git add fileIntoAccountButRenamedOrMoved