You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Add git-blame-ignore-revs to hide bot commits - ornl-next (#39153)
Add git-blame-ignore-revs to hide bot commits
This is a feature of git/github so git blame will ignore commits by bots
or changes in formatting tool configuration
# The refspecs listed in this file are ignored by `git blame` when git is configured correctly.
2
+
# The refspecs must be listed in commit order from oldest to newest.
3
+
#
4
+
# MOST OF THE COMMITS LISTED ARE BY BOTS
5
+
#
6
+
# github does this automatically https://docs.github.com/en/repositories/working-with-files/using-files/viewing-and-understanding-files#ignore-commits-in-the-blame-view
Copy file name to clipboardExpand all lines: dev-docs/source/GitWorkflow.rst
+22-2Lines changed: 22 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -68,6 +68,27 @@ pushed to GitHub, please follow the convention of
68
68
what the branch is for (issue number) and quickly know what is being
69
69
done there (short description).
70
70
71
+
Git Blame
72
+
---------
73
+
74
+
The refspecs listed in this file are ignored by ``git blame`` when git is configured correctly.
75
+
This is mostly used to hide commits that are created by bots (e.g. formatting)
76
+
The refspecs must be listed in commit order from oldest to newest.
77
+
Github does this automatically in the `blame view of a file <https://docs.github.com/en/repositories/working-with-files/using-files/viewing-and-understanding-files#ignore-commits-in-the-blame-view>`_
78
+
79
+
To configure it locally (examples assume you are in the root of your local clone), add it as an option to git blame
- Added file ``.git-blame-ignore-revs`` to ignore particular revisions (e.g. by bots) in ``git blame`` listings. See :ref:`GitWorkflow` page for more details.
0 commit comments