diff options
author | Matěj Cepl <mcepl@cepl.eu> | 2024-03-27 16:27:37 +0100 |
---|---|---|
committer | Matěj Cepl <mcepl@cepl.eu> | 2024-03-28 17:12:18 +0100 |
commit | b065fb7b1b7035b4693d21d413feabf411269c6f (patch) | |
tree | 57206a992b785bde4f6fd959fe35c49b0c811873 /abbrevURL | |
parent | db45774fe880cb1617bd13f818a0d104104b932c (diff) | |
download | vim-suse-changes-b065fb7b1b7035b4693d21d413feabf411269c6f.tar.gz |
fix(abbrevURL): correctly abbreviate commit URL to gh#foo/bar@IDno.
Diffstat (limited to 'abbrevURL')
-rwxr-xr-x | abbrevURL | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -28,7 +28,7 @@ STR="$(echo "$STR" | sed -E -e 's@https?://github.com/(.*)/discussions/([0-9]+)@ # TODO STR=STR:gsub("https?://github.com/(.*)/commit/(%w+)", function (r, i) # return "gh#" .. r .. "@" .. i:sub(1, 12) # end) -STR="$(echo "$STR" | sed -E -e 's!https?://github.com/(.*)/commit/([a-zA-Z0-9]+)!gh#\1#\2!')" +STR="$(echo "$STR" | sed -E -e 's!https?://github.com/(.*)/commit/([a-zA-Z0-9]+)!gh#\1@\2!')" STR="$(echo "$STR" | sed -E -e 's@https?://gitlab.com/(.*)/issues/([0-9]+)@gl#\1#\2@')" STR="$(echo "$STR" | sed -E -e 's@https?://gitlab.com/(.*)/pull/([0-9]+)@gl#\1!\2@')" STR="$(echo "$STR" | sed -E -e 's@https?://gitlab.com/(.*)/-/issues/([0-9]+)@gl#\1#\2@')" |