Show Full Git Log When Path/File Used git mv

#usage:

$ git log --follow path/to/file


#example:
event/old_path/index.php is already in git commit log
event/old_path/index.php move to event/new_path/index.php

#show old log

$ git log event/old_path/index.php
change wording
init


#move file

$ git mv event/old_path/index.php event/new_path/index.php


#add changes to staging area

$ git add event/new_path/index.php


#commit changes

$ git commit -m 'move file'


#display log ,just display new path log

$ git log event/new_path/index.php
move file


#display full log, both new path and old path log
$ git log --follow event/new_path/index.php
move file
change wording
init


留言