]> git.wh0rd.org - home.git/commitdiff
vcs-url: more updates
authorMike Frysinger <vapier@gentoo.org>
Tue, 19 Apr 2016 06:51:02 +0000 (02:51 -0400)
committerMike Frysinger <vapier@gentoo.org>
Tue, 19 Apr 2016 06:51:02 +0000 (02:51 -0400)
.bin/vcs-url

index a86f8b7330bc9cab0fac9398072312e49531ec9b..bab6e78c9ca5ce4b7e48c453806956f67abb70cb 100755 (executable)
@@ -83,9 +83,9 @@ git_url() {
                repo=$(echo "${remote}" | sed 's:.*git[.a-z]*.gentoo.org/::')
                url="https://gitweb.gentoo.org/${repo}/commit/?id="
                ;;
-       git@github.com/*|\
+       git@github.com[:/]*|\
        *://github.com/*)
-               repo=$(echo "${remote}" | sed -e 's,^git@github.com/,,' -e 's,^https://github.com/,,' -e 's,^git://github.com/,,' -e 's:[.]git$::')
+               repo=$(echo "${remote}" | sed -e 's,^git@github.com[:/],,' -e 's,^https://github.com/,,' -e 's,^git://github.com/,,' -e 's:[.]git$::')
                url="https://github.com/${repo}/commit/"
                ;;
        git://git.sv.gnu.org/*)
@@ -103,6 +103,10 @@ git_url() {
        *.googlesource.com/*)
                url="${remote%.git}/+/"
                ;;
+       *://git.enlightenment.org/*)
+               repo=$(echo "${remote}" | sed -e 's,^[^/]*//[^/]*/,,' -e 's,[.]git$,,')
+               url="https://git.enlightenment.org/${repo}.git/commit/?id="
+               ;;
        *)
                echo "Unknown remote: ${remote}"
                exit 1