summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFlorian Pritz <bluewind@xinu.at>2024-08-20 20:52:12 +0200
committerFlorian Pritz <bluewind@xinu.at>2024-08-20 20:53:21 +0200
commit77509c41292c1caef8899f75fe12a6910f17d1b8 (patch)
tree9e597857e32b8758243dbaa1eabc7c7b4b8b28d7
parente65064903d069256a7d80fed26c83435795cf6e0 (diff)
downloadbin-77509c41292c1caef8899f75fe12a6910f17d1b8.tar.gz
bin-77509c41292c1caef8899f75fe12a6910f17d1b8.tar.xz
browser_launcher.pl: Add ssh git URL support
Signed-off-by: Florian Pritz <bluewind@xinu.at>
-rwxr-xr-xbrowser_launcher.pl6
1 files changed, 6 insertions, 0 deletions
diff --git a/browser_launcher.pl b/browser_launcher.pl
index 3bc2dfe..a77dc2a 100755
--- a/browser_launcher.pl
+++ b/browser_launcher.pl
@@ -14,6 +14,12 @@ use autodie qw(:all);
use Text::Template 'fill_in_string';
my $sites = {
+ 'ssh-git' => {
+ 'patterns' => [
+ qr|^ssh://(?:(?<username>\w+)@)?(?<domain>[\w.]+)(?::(?<port>\d+))?/(?<path>.*)\.git|,
+ ],
+ 'command' => ['firefox', 'https://{$domain}/{$path}'],
+ },
'youtube' => {
'patterns' => [
qr|^https://www.youtube.com|,