This is a synchronized article with authorization, original link: https://www.liuzhen932.top/posts/default/githistory
It's 4202 now, and there are countless tools available to view Git commit history, including CLI (just git history
) and GUI (Github Desktop).
This brings me to a ⭐ treasure project I discovered, pomber/git-history
is an online tool that can present the change history of repository files quickly and clearly in an animated way.
Want to give it a try? It's very simple:
- Go to a file in GitHub / GitLab / Bitbucket
- Replace
github.com
withgithub.githistory.xyz
- And that's it, use the left and right arrow keys to view the changes in animated form
Compared to the methods like Blame we usually use, this tool provides a faster and more intuitive way to check how past commits have affected files.
The author also provides bookmarks and browser extensions for quick use:
/* Bookmark Original: https://github.com/pomber/git-history?tab=readme-ov-file#browsers */
javascript: (function() {
var url = window.location.href;
var regEx = /^(https?\:\/\/)(www\.)?(github|gitlab|bitbucket)\.(com|org)\/(.*)$/i;
if (regEx.test(url)) {
url = url.replace(regEx, "$1$3.githistory.xyz/$5");
window.open(url, "_blank");
} else {
alert("Not a Git File URL");
}
})();
You can download the browser extension version here, and you can even download the CLI version for local use here.
Well, that's the treasure project I recently discovered, thank you for reading, see you next time!