aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorsudoforge <no-reply@sudoforge.com>2024-07-18 21:05:51 -0700
committersudoforge <9c001b67637a@sudoforge.com>2024-07-20 16:45:55 -0700
commit4089b1693983782fffaf373a1e70a8cbbefc5a96 (patch)
tree3db8960a45c95d0d813529989d79ad8b0f2fd688
parent825eecefa1650737e661ad8eae4f07bb19b45ae0 (diff)
downloadgit-bug-4089b1693983782fffaf373a1e70a8cbbefc5a96.tar.gz
feat: add a common file for git-blame ignored revisions
Change-Id: Ia28c12c211c67fccbfc2f6a6dc2be390d13a29c0
-rw-r--r--.git-blame-ignore-revs19
-rw-r--r--flake.nix4
2 files changed, 23 insertions, 0 deletions
diff --git a/.git-blame-ignore-revs b/.git-blame-ignore-revs
new file mode 100644
index 00000000..d70324d7
--- /dev/null
+++ b/.git-blame-ignore-revs
@@ -0,0 +1,19 @@
+# git blame ignore list
+#
+# This file contains a list of git hashes of revisions to be ignored by
+# git-blame. These revisions are considered "unimportant" in that they are
+# unlikely to be what you are interested in when blaming.
+#
+# Instructions:
+# - Only large (generally automated) reformatting or renaming commits should be
+# added to this list. Do not put things here just because you feel they are
+# trivial or unimportant. If in doubt, do not put it on this list.
+# - Precede each revision with a comment containing the first line of its log.
+# For bulk work over many commits, place all commits in a block with a single
+# comment at the top describing the work done in those commits.
+# - Only put full 40-character hashes on this list (not short hashes or any
+# other revision reference).
+# - Append to the bottom of the file (revisions should be in chronological order
+# from oldest to newest).
+# - Because you must use a hash, you need to append to this list in a follow-up
+# commit to the actual reformatting commit that you are trying to ignore.
diff --git a/flake.nix b/flake.nix
index 9afc2cbc..75bfce54 100644
--- a/flake.nix
+++ b/flake.nix
@@ -32,6 +32,10 @@
shellHook = ''
# Use //:.gitmessage as the commit message template
${pkgs.git}/bin/git config --local commit.template ".gitmessage"
+
+ # Use a common, shared file as the default for running
+ # git-blame with the `--ignore-revs` flag
+ ${pkgs.git}/bin/git config --local blame.ignoreRevsFile ".git-blame-ignore-revs"
'';
};
}