Created
October 2, 2013 12:01
-
-
Save shadyvb/6792634 to your computer and use it in GitHub Desktop.
Default to pull-request to develop branch instead of master on github
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// ==UserScript== | |
// @name Compare pull-requests against develop branch instead of master branch | |
// @namespace http://sharaf.me/ | |
// @version 0.1 | |
// @match https://github.com/*/compare/issue* | |
// @copyright 2013+, Shady Sharaf | |
// @run-at document-start | |
// ==/UserScript== | |
window.location.href = window.location.href.replace('compare/issue', 'compare/develop...issue') |
Since is stone-age anyway.. but i think i'll do a small popup, on clicking a button, placed anywhere on the settings page for a repo, that will give you the choice of which branch should be set as the default base branch for pull-requests .. which stores in a cookie and be used later on redirection ..
Shouldn't be hard to do i think ..
That would be awesome! Better yet would be to use localStorage
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
What about:
And then what if the repo you're looking at doesn't have a
develop
branch, or if is nameddevelopment
? Would this cause you to always go to a 404?