From 7e5b6973525f6c78f533d25a5efe75e5c946b910 Mon Sep 17 00:00:00 2001 From: Pierguido Lambri Date: Fri, 7 Aug 2020 09:44:29 +0100 Subject: [PATCH] Fixed a small issue with the urlhandler. Urls lile: https://whatever.domain/~myprecious/usefull-blog.html https://brb.imback.maybe/isit/blah#sure Were not propery handled (everything after either '#' or '~' were ignored). Escaped '#' and added '~' in the regex. Signed-off-by: Pierguido Lambri --- st-urlhandler | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/st-urlhandler b/st-urlhandler index d44bb99..0d39dd5 100755 --- a/st-urlhandler +++ b/st-urlhandler @@ -1,6 +1,6 @@ #!/bin/sh -urlregex="(((http|https)://|www\\.)[a-zA-Z0-9.]*[:]?[a-zA-Z0-9./@$&%?$#=_-]*)|((magnet:\\?xt=urn:btih:)[a-zA-Z0-9]*)" +urlregex="(((http|https)://|www\\.)[a-zA-Z0-9.]*[:]?[a-zA-Z0-9./@$&%?$\#=_~-]*)|((magnet:\\?xt=urn:btih:)[a-zA-Z0-9]*)" # First remove linebreaks and mutt sidebars: urls="$(sed 's/.*│//g' | tr -d '\n' |