Skip to content

Commit

Permalink
Merge pull request #3 from glensc/patch-1
Browse files Browse the repository at this point in the history
add ssh://git url support
  • Loading branch information
jeffreyiacono authored Oct 14, 2018
2 parents 211e3f1 + d79358a commit bc71564
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion git-open.sh
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ if [ -z "$git_repo" ]; then
baseurl=${GITHUB_URL:-"https://github.com"}
else
# baseurl="https://github.com";username="jeffreyiacono";repo="git-open"
eval "$(echo $(git config remote.origin.url) | perl -pe 's/^(?:https?:\/\/|git@)([^:\/]+)[:\/]([^\/]+)\/([^\/]+?)(?:\.git)?$/baseurl="https:\/\/$1";username="$2";repo="$3"/')"
eval "$(echo $(git config remote.origin.url) | perl -pe 's/^(?:https?:\/\/|ssh:\/\/git@|git@)([^:\/]+)[:\/]([^\/]+)\/([^\/]+?)(?:\.git)?$/baseurl="https:\/\/$1";username="$2";repo="$3"/')"
fi

if [ $# = 1 ]; then
Expand Down

0 comments on commit bc71564

Please sign in to comment.