Ticket #363 (new FeatureRequest)

Opened 1 year ago

Last modified 7 months ago

regex plugin

Reported by: yars12 Assigned to:
Milestone: PluginPack2.1.0 Component: PluginPack
Version: Current Release Severity:
Keywords: Cc:
Pending: 0

Description

It would be super sweet if there were a plugin that allowed me to define regex replacements on both incoming and outgoing text (text replacement does some of this now).

In particular, it would be awesome to have something like colloquy's traclinks (http://colloquy.info/project/wiki/TracLinks), where when I get a message with [32104] in it, it gets linkified to the trac db changeset, and "#345" or "bug 345" gets linkified to the trac ticket.

Of course, a regex engine for this would allow someone to make such a set of rules for trac, or for bugzilla, or for just about anything.

Change History

06/20/07 16:14:48 changed by grim

I LIKE this idea, a lot, I don't see myself using it that much (right now anyways), but the idea still rocks :)

06/20/07 22:21:27 changed by sadrul

If you have perl-support in your pidgin, can you please try out http://pidgin.im/~sadrul/pp/replaceX.pl and see if it does what you want?

06/22/07 12:07:27 changed by yars12

I've just tried scouring google for info on perl-support with pidgin/gaim, as well as the pidgin wiki, and have come up empty-handed (aside from a few people reporting getting gaim to compile with perl-support).

So, this is a total noob question, but how would I go about determining if I have perl-support, and once I do that, how do I install/use replaceX.pl?

07/03/07 10:31:34 changed by rageboy04

Check your help->about at the bottom under debugging information. I don't quite know how perl plugins work, but I think you can just put the .pl file in the ~/.purple/plugins directory where ~ is C:\Documents and Settings\<username>\ on Windows XP.

07/15/07 09:50:39 changed by jbailey

  • milestone set to PluginPack2.1.0.

(follow-up: ↓ 7 ) 12/06/07 15:51:55 changed by yars12

looks like this didn't make it in for 2.1.0?

also, a couple issues to report back with replaceX.pl: - the default rule example doesn't show up properly with -l -- the $1 and $0 get stripped out - a simpler example would be nice, e.g., how to replace all incoming occurrences of "blah" with "bleh" (the "gf#" thing -- what is that?)

I'm still monkeying with replaceX.pl to see if I can figure out how to get it to replace text, and I'll report more ASAP.

(in reply to: ↑ 6 ) 02/06/08 11:53:27 changed by ioeth

This plugin seems to be working great for me. I wanted to set up a regex replacement rule for linkifying Wikilinks, and the replacement is very smooth and easy. The only problem that I'm having is that the plugin doesn't seem to be paying attention to my IRC chats, which is where I need it most. It will work in IRC 1-on-1 conversations, but not in rooms. Any idea what's going on with this?