Created
January 27, 2018 09:14
-
-
Save MaximeD/e3f6d2d3c111579afa54adba9dcf6805 to your computer and use it in GitHub Desktop.
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
#!/bin/sh | |
# Full repository name (group and project) | |
repo=$(echo $(git ls-remote --get-url) | sed 's/git@github.com:\(.\+\)\.git/\1/') | |
# Branch name | |
branch=$(git rev-parse --abbrev-ref HEAD) | |
# Display link to pull request | |
echo "Create pull request for pre-push_hook:" | |
echo -e "\thttps://github.com/$repo/compare/$branch?expand=1" | |
exit 0 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment