A line of code in a file was modified to an incorrect code. How can I use the git command to find out who modified the code? git blame filepath
Since there are too many file modification records and all are displayed, how can we find the culprit more accurately and quickly
世界只因有你2017-05-02 09:51:04
You can use the sourcetree tool. In this tool, the operations are all interface-based, and it is more convenient to search for records.
ringa_lee2017-05-02 09:51:04
The fastest one is probably blame. Just find that line and see who wrote the commit
You can also git log -p -M --follow --stat -- 文件名
and search
阿神2017-05-02 09:51:04
vim file.name Enter the file, move the cursor to this line, and then ":Gblame", the record of who modified this line will be displayed on the left.