Hi list, This was posted on #rxvt-unicode today but I thought a formal email would be better for discussion.
I'm trying to auto-match the text in IRC chatting, so if someone mentioned "we should focus on bug 134553", I can click and open "bugs.example.com/134553". This is doable with matcher: urxvt.matcher.pattern.1: bug[ ](\\d+) urxvt.matcher.launcher.1: /usr/bin/google-chrome bugs.example.com/$1 But this is tedious: I also want to recognize "bug id \d+" and "issue \d+", and I want to recognize "commit \d+" to "svn.example.com/$1", "release \w+" to "svn.example.com/branch/$1" etc. So I'm proposing a new plugin (or maybe improvement to matcher plugin?) which accept a single substitution expression and convert some text into a valid URL. The configuration might look like this: urxvt.new-plugin.transform-into-url.1 = s/(?:bug|issue)[ ](\\d+)/bugs.example.com\/$1/ urxvt.new-plugin.transform-into-url.2 = s/commit[ ](\\d+)/svn.example.com\/$1/ urxvt.new-plugin.transform-into-url.3 = s/release[ ](\\w+)/svn.example.com\/branch\/$1/ What do you think? Bad idea? Good-but-we-don't-want-to-include? -- yegle http://about.me/yegle _______________________________________________ rxvt-unicode mailing list [email protected] http://lists.schmorp.de/cgi-bin/mailman/listinfo/rxvt-unicode
