From 50ad3abcf8fc488fa4ab7948fb7b7957d2b33be7 Mon Sep 17 00:00:00 2001 From: Mike Frysinger Date: Wed, 9 Mar 2016 12:39:55 -0500 Subject: [PATCH] vcs-url: more updates --- .bin/vcs-url | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/.bin/vcs-url b/.bin/vcs-url index 0d83a33..a86f8b7 100755 --- a/.bin/vcs-url +++ b/.bin/vcs-url @@ -85,7 +85,7 @@ git_url() { ;; git@github.com/*|\ *://github.com/*) - repo=$(echo "${remote}" | sed -e 's,^git@github.com/,,' -e 's,^https://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/*) @@ -96,6 +96,13 @@ git_url() { repo=$(echo "${remote}" | sed -r -e 's,git://git.code.sf.net/p/([^/]*)/.*,\1,') url="http://sourceforge.net/p/${repo}/code/ci/" ;; + *://sourceware.org/*) + repo=$(echo "${remote}" | sed -e 's,.*/,,' -e 's,[.]git$,,') + url="https://sourceware.org/git/?p=${repo}.git;a=commit;h=" + ;; + *.googlesource.com/*) + url="${remote%.git}/+/" + ;; *) echo "Unknown remote: ${remote}" exit 1 -- 2.39.2