Userscript that adds tweaks to GitHub.
GitHub Tweaks can be installed on a PC, or a Mac. Simply choose the plugin that corresponds to your web browser below and download the script, as easy as that!
- Which browser?
- Firefox: Install the GreaseMonkey plugin.
- Chrome: Install the Tampermonkey plugin.
- Opera: Install the ViolentMonkey extension.
- Safari & Internet Explorer: NOT SUPPORTED!
- GitHub Tweaks script can be found here (just choose any one)
Here's what this script does for you / adds to the GitHub website.
When viewing the changed files of a PR, branch comparison or a single commit, you can now collapse and expand the files by clicking the individual file headers. Alternatively, you can collapse and expand all at the same time by clicking one of the new buttons at the top.
When viewing a conversation of an issue or PR, you can now collapse and expand the comments by clicking the individual comment headers. Alternatively, you can collapse and expand all at the same time by clicking one of the new buttons in the topmost comment header. For hidden comments, the first part of the content gets added to the comment header as a tooltip.
A link with the permalink to the current page gets added to the top right into the user links.
When viewing a PR, there is a short summary text similar to this at the top:
- user2 wants to merge 8 commits into
user1:master
fromuser2:branch
The user1:master
and user2:branch
placeholders are now links to the respective branches.
(this applies to all user:branch
placeholders wherever they appear)
Here are features that don't apply anymore, due to GitHub changes.
On the dashboard, the pull info fields are now linked to the PR's "Files changed" tab for quick access.
- Remove Commit Ref Links which have been implemented by GitHub directly.
- Remove Pull Info Links which are obsolete since GitHub's new dashboard.
- Fix permalink link next to the user links at the top right.
- Improve userscript initialisation.
- Fix tooltip for folded comments. Error was due to clearfix added by GitHub.
- Add fold/unfold buttons when viewing a single commit.
- Add permalink of the current page to user links.
- Remove built-in GitHub file collapse toggle, due to a very different approach of showing/hiding content.
- Fix fold/unfold buttons to work correctly even after changing tabs in PR view.
- Make fold/unfold buttons react to specific selectors instead of elements. This means that newly added comments also get toggled correctly.
- Fix for class rename on GitHub.
- Add Pull Info Links on dashboard.
- Refresh tweaks on page content change, so that new inline comments instantly become toggleable.
- Add content tooltip to comment header when content is collapsed.
- Add missing tooltips to comment action buttons.
- Fix Commit Ref Links for unknown repositories.
- Add Toggleable File Diff buttons when viewing a single commit.
- Add Toggleable Comments.
- Code rewrite / restructure.
- Change position of Toggleable File Diff buttons.
- Add Toggleable File Diff buttons to branch compare.
- First version, adding Commit Ref Links and Toggleable File Diffs.