'git log' doesn't keep log of un-removed and then renamed directory
- From
- Yuri <yuri@freebsd.org>
- Date
- Aug 14, 2021, 09:09 UTC
- Message-ID
- <75911f47-1433-f0a4-7d46-f1fb2fd44cf4@rawbw.com>
In the FreeBSD ports tree I restored the previously removed directory math/dynare:
1. git checkout 3fb72e318f7be~1 -- math/dynare
2. git mv math/dynare science/dynare
3. rm -rf science/dynare && cp -r science/dynare.new science/dynare
4. git add science/dynare
5. git commit science/dynare
After this 'git log science/dynare' only shows my last commit, and not the previous history of 'math/dynare' that existed before its removal.
The above sequence of commands should have kept and migrated the history of math/dynare to science/dynare, but it didn't.
The corresponding subversion command sequence keeps history.
Yuri