我正在尝试恢复修改了已重命名的文件的提交。
修改过的文件曾经被调用bin/internal/call_parser.rb
,当前被调用lib/call_parser.rb
,我在尝试还原后进入了我的状态
$ git status
# On branch master
# Your branch is ahead of 'origin/master' by 16 commits.
#
# Changes to be committed:
# (use "git reset HEAD <file>..." to unstage)
#
# modified: other/unrelated/file
#
# Unmerged paths:
# (use "git reset HEAD <file>..." to unstage)
# (use "git add/rm <file>..." as appropriate to mark resolution)
#
# deleted by us: bin/internal/call_parser.rb
#
据我所知,lib/call_parser.rb 的当前版本和 bin/internal/call_parser.br 文件的当时版本应该足够相似,以至于 git 可以检测到共享内容(我听说 git 可以工作文件内容,而不是文件名)。我如何告诉 git 更加努力地工作以检测重命名并因此恢复为 lib/call_parser.rb 中的内容?