diff --git a/pre-push b/pre-push index e22a6d3..b0d477f 100755 --- a/pre-push +++ b/pre-push @@ -5,9 +5,10 @@ # url is $2 url="${2#*@}" url="${url%.git}" +url="${url#*://}" shopt -s extglob -url="${url/:*([0-9])//}" -url="https://${url//\/\///}" +url="${url/:([0-9]+)//}" +url="https://${url}" branch="$(git branch | grep "\* ")" branch="${branch:2}" commit="$(git log -1 --pretty=%B)"