Last active
March 3, 2021 01:04
-
-
Save hasantezcan/b643651871a5b9023ee715a09532ac96 to your computer and use it in GitHub Desktop.
git repo alias - access repo link directly from command prompt
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
alias git-repo="git config --get remote.origin.url | sed -e 's/:/\//g'| sed -e 's/ssh\/\/\///g'| sed -e 's/git@/https:\/\//g'" | |
alias git-pr="git config --get remote.origin.url | sed -e 's/:/\//g'| sed -e 's/ssh\/\/\///g'| sed -e 's/git@/https:\/\//g' | sed 's/....$//' | sed -ne 's/$/\/pulls &/p'" | |
# https://stackoverflow.com/a/63907839/10694425 | |
# https://stackoverflow.com/a/66395349/10694425 |
Author
hasantezcan
commented
Mar 3, 2021
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment