Fix patterns for url matching to handle IPv6 as host

This commit is contained in:
Stephen Boddy 2017-02-18 21:31:52 +01:00
parent 31c3b2e9f4
commit e88f3b2140
1 changed files with 1 additions and 1 deletions

View File

@ -259,7 +259,7 @@ class Terminal(Gtk.VBox):
"""Update the regexps used to match URLs""" """Update the regexps used to match URLs"""
userchars = "-A-Za-z0-9" userchars = "-A-Za-z0-9"
passchars = "-A-Za-z0-9,?;.:/!%$^*&~\"#'" passchars = "-A-Za-z0-9,?;.:/!%$^*&~\"#'"
hostchars = "-A-Za-z0-9" hostchars = "-A-Za-z0-9:\[\]"
pathchars = "-A-Za-z0-9_$.+!*(),;:@&=?/~#%'" pathchars = "-A-Za-z0-9_$.+!*(),;:@&=?/~#%'"
schemes = "(news:|telnet:|nntp:|file:/|https?:|ftps?:|webcal:)" schemes = "(news:|telnet:|nntp:|file:/|https?:|ftps?:|webcal:)"
user = "[" + userchars + "]+(:[" + passchars + "]+)?" user = "[" + userchars + "]+(:[" + passchars + "]+)?"