Skip to content

Commit

Permalink
Add .git-blame-ignore-revs [ci skip]
Browse files Browse the repository at this point in the history
for [Misc #18891]

It is a file that could be used with `git config blame.ignoreRevsFile`.
The file name `.git-blame-ignore-revs` is natively supported by GitHub,
so you don't need anything else to make it work on GitHub.
https://docs.github.com/en/repositories/working-with-files/using-files/viewing-a-file#ignore-commits-in-the-blame-view

However, for your local git repository use, if you configure `blame.ignoreRevsFile`
globally, git expects you to have the file in every git repository you
use, which is nearly impossible.

So, for your local development, you're supposed to use this file with:

```
git config --local blame.ignoreRevsFile .git-blame-ignore-revs
```
  • Loading branch information
k0kubun authored and nobu committed May 6, 2024
1 parent 9ae2106 commit 48e427b
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions .git-blame-ignore-revs
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# This is a file used by GitHub to ignore the following commits on `git blame`.
#
# You can also do the same thing in your local repository with:
# $ git config --local blame.ignoreRevsFile .git-blame-ignore-revs

# Expand tabs
9ae210665a8524554e7c868d3ec67af54b0958bb

0 comments on commit 48e427b

Please sign in to comment.