From 1164db0ba8564d273a4d46e5d1af6baa6e2f54a0 Mon Sep 17 00:00:00 2001 From: Curtis McEnroe Date: Mon, 22 Oct 2018 16:32:02 -0400 Subject: [PATCH] Add more URL schemes --- url.c | 17 +++++++++++++---- 1 file changed, 13 insertions(+), 4 deletions(-) diff --git a/url.c b/url.c index a398778..b62baba 100644 --- a/url.c +++ b/url.c @@ -24,9 +24,19 @@ #include "chat.h" static const char *Schemes[] = { - "https:", - "http:", + "cvs:", "ftp:", + "git:", + "http:", + "https:", + "irc:", + "ircs:", + "magnet:", + "sftp:", + "ssh:", + "svn:", + "telnet:", + "vnc:", }; static const size_t SchemesLen = sizeof(Schemes) / sizeof(Schemes[0]); @@ -81,8 +91,7 @@ void urlOpenMatch(struct Tag tag, const char *substr) { struct Entry entry = ringEntry(i); if (!entry.url || entry.tag != tag.id) continue; if (!strstr(entry.url, substr)) continue; - char *argv[] = { "open", entry.url, NULL }; - eventPipe(argv); + eventPipe((char *[]) { "open", entry.url, NULL }); break; } }