mirror of
https://github.com/pomber/git-history.git
synced 2024-11-22 05:33:57 +03:00
Quickly browse the history of a file from any git repository
.storybook | ||
cli | ||
public | ||
src | ||
vscode-ext | ||
.gitignore | ||
.travis.yml | ||
craco.config.js | ||
license | ||
netlify.toml | ||
package.json | ||
readme.md | ||
yarn.lock |
Git History
Quickly browse the history of any GitHub (GitLab and Bitbucket coming soon) file:
- Replace
github.com
withgithub.githistory.xyz
in any file url - There's no step two
If you like this project consider backing my open source work on Patreon!
And follow @pomber on twitter for updates.
Browser Extensions
You can also add an Open in Git History
button to GitHub, GitLab and Bitbucket with the Chrome and Firefox extensions.
Or you can use a bookmarklet.
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");
}
})();
CLI
There's also a command line version of Git History that works with any local git repo:
You need node to run this
$ npx git-file-history path/to/file.ext
or
$ npm install -g git-file-history
$ git-file-history path/to/file.ext
Sponsors
Support this project by becoming a sponsor. Your logo will show up here with a link to your website. [Become a sponsor]
Backers
Thank you to all our backers! 🙏 [Become a backer]
Contributors
This project exists thanks to all the people who contribute.
Credits
Based on these amazing projects:
- Prism by Lea Verou
- jsdiff by Kevin Decker
- Night Owl by Sarah Drasner
License
MIT