Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我正在将 eslint/prettier 添加到我的代码格式、样式等存储库中。问题是,当人们运行时,git blame我现在将被称为我们项目中大量代码行的作者。
git blame
我发现这篇博客文章表明我可以git blame --ignore-rev用来忽略某个提交,git blame但这需要人们知道我已经做出了这个提交,然后它还要求他们每次都查找或使用该哈希。
git blame --ignore-rev
有没有办法,无论是在我提交时还是在提交之后,让这些代码行的作者在 linting 之前保持原样?我不想没有作者,我只想让他们保持不变。