[Pkg-urxvt-maintainers] Bug#683136: rxvt-unicode{, -256color}: tight regexp in matcher

gregor herrmann gregoa at debian.org
Sun Jul 29 01:12:32 UTC 2012


Package: rxvt-unicode-256color,rxvt-unicode
Version: 9.15-2
Severity: minor
Tags: patch

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

The matcher extension has a tight default regexp for matching URLs.
"a-zA-Z0-9" doesn't match non-ascii chars which might be a nuisance
but exist in URLs.

Using \w seems that work for me; quick patch (I haven't really
thought where \w makes more sense and where not ...):

#v+
- --- /usr/lib/urxvt/perl/matcher 2012-06-30 18:16:46.000000000 +0200
+++ /home/gregoa/.urxvt/matcher 2012-07-29 03:02:55.358499702 +0200
@@ -6,10 +6,10 @@
 my $url =
    qr{
       (?:https?://|ftp://|news://|mailto:|file://|\bwww\.)
- -      [a-zA-Z0-9\-\@;\/?:&=%\$_.+!*\x27,~#]*
+      [\w\-\@;\/?:&=%\$_.+!*\x27,~#]*
       (
- -         \([a-zA-Z0-9\-\@;\/?:&=%\$_.+!*\x27,~#]*\)| # Allow a pair of matched parentheses
- -         [a-zA-Z0-9\-\@;\/?:&=%\$_+*~]  # exclude some trailing characters (heuristic)
+         \([\w\-\@;\/?:&=%\$_.+!*\x27,~#]*\)| # Allow a pair of matched parentheses
+         [\w\-\@;\/?:&=%\$_+*~]  # exclude some trailing characters (heuristic)
       )+
    }x;
 
#v-


Cheers,
gregor


- -- System Information:
Debian Release: wheezy/sid
  APT prefers unstable
  APT policy: (990, 'unstable'), (500, 'experimental'), (500, 'testing'), (500, 'stable')
Architecture: amd64 (x86_64)

Kernel: Linux 3.4-trunk-amd64 (SMP w/4 CPU cores)
Locale: LANG=C, LC_CTYPE=de_AT.utf8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/bash

Versions of packages rxvt-unicode-256color depends on:
ii  base-passwd               3.5.26
ii  libc6                     2.13-35
ii  libfontconfig1            2.9.0-7
ii  libgcc1                   1:4.7.1-5
ii  libgdk-pixbuf2.0-0        2.26.1-1
ii  libglib2.0-0              2.32.3-1
ii  libperl5.14               5.14.2-12
ii  libstartup-notification0  0.12-1
ii  libx11-6                  2:1.5.0-1
ii  libxft2                   2.3.1-1
ii  libxrender1               1:0.9.7-1
ii  ncurses-term              5.9-10

Versions of packages rxvt-unicode-256color recommends:
pn  fonts-vlgothic | fonts-japanese-gothic  <none>
ii  ttf-dejavu                              2.33-2

rxvt-unicode-256color suggests no packages.

- -- no debconf information

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.12 (GNU/Linux)

iQIcBAEBCAAGBQJQFI39AAoJELs6aAGGSaoGRSAQAItwTUPHtrJrNNOKTKEMjWNT
tiBrtEYzBvju1GneqCWVZS8UhaDbCDQGuPGMtdkJnIFe5FjfE+XOI8PbfynPTX5S
ygZSYdeMaD+ZZhv6uNxDYdnXduE5nS2ajHpEEfHJT68uxnYlAAbn2Dy/UCZ3KK/4
4hD6KZm0GyH5xe6Z8vtIDq+xLkRcew1pXKKcaKR1vp3lRSVKi+6HXoloVUxnIrgJ
1jaRaYgIYPakdK7nbHYcOfZJOV1m8yPr5ZvGIVFXtOIRAreoWWqsruJet4JNZMuN
I6bzycOTck1+3Y48AjnUqf9Skdj41VMN1REgJoynQLD2cIxZRMzU5X354f5n2b4x
N0ab+NspbwQrFsn268Dj6ykQnQRcltrctGEQ5n47jTwbPUbvficn0f3U4sYtKZL7
7Nn3Qpi/moDgMF0LqJR12+Bd301Y8n8Gep8P9rXTwdW8fxwYeVmmxXwVNGcxIeXC
G2V7barwm+ZncadzNHvNXJ0BCvMghv1HXUbM2zQwVKmhVkP+OWOd1Vss7zKwdzYH
mpJBPH6WgPdonUHgkQEylO2F1Fj14SIRfEIx5MYEPxAfQMZon1xjfeaLWbS9M0l0
rPTDcHFYgGJ+iCQF6ZnZ/zjxrFicEtj47Tb8EGbN6l7tjL83AAx+pN0OGtUazjfr
lnODFvDUJKGV9GLzsX1K
=i09M
-----END PGP SIGNATURE-----




More information about the Pkg-urxvt-maintainers mailing list