Created
January 23, 2019 11:33
-
-
Save Teemu/aedb934fdea506afdfaed99313b05fef to your computer and use it in GitHub Desktop.
Open a pull request in 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
from sh import git, open | |
branch = git('rev-parse', '--abbrev-ref', 'HEAD').strip() | |
location = git('remote', 'get-url', 'origin').split('[email protected]:')[1].split('.git')[0] | |
url = 'https://github.com/%s/compare/%s?expand=1' % ( | |
location, | |
branch | |
) | |
open(url) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment