历史:在 commit 信息中查找并展示 commit

git log --grep="待过滤信息"

历史: 在文件中查找内容并展示 commit

git log -S"待搜索内容" -p

参考资料