[rt-users] Change RTname smoothly...

James Moseley jmoseley at corp.xanadoo.com
Wed Jun 6 11:44:32 EDT 2007

The code below will work, yes.  As for changing RT name, yes, you have to
change $rtname in RT_SiteConfig.pm.  You don't need to make any changes to
the database.

However, rather than changing the code in EmailParser.pm, you can
accomplish the same thing by adding the following into RT_SiteConfig.pm:

Set($EmailSubjectTagRegex, qr/(?:<old RT name>|<new RT name>)/i );

James Moseley

             "Carlos R. S."                                                
             <cbsilva at student.                                             
             dei.uc.pt>                                                 To 
             Sent by:                  <rt-users at lists.bestpractical.com>  
             rt-users-bounces@                                          cc 
             al.com                                                Subject 
                                       [rt-users] Change RTname            
             06/06/2007 05:53                                              


I need to change my rtname, but has the server is in production, I’ve got
to be pretty sure nothing is going to go wrong.
I found some info about some extra lines to add to the EmailParser.pm:

*** ./lib/RT/EmailParser.pm~ 2004-06-15 02:08:15.000000000 +0200
--- ./lib/RT/EmailParser.pm 2004-08-23 18:58:47.000000000 +0200
*** 332,337 ****
--- 332,342 ----
$RT::Logger->debug("Found a ticket ID. It's $id");
return ($id);
+ elsif ($Subject =~ s/\[OldName \#(\d+)\]//i) {
+ my $id = $1;
+ $RT::Logger->debug("Found an old (OldName) ticket ID. It's $id");
+ return ($id);
+ }
else {
return (undef);

But I have to be pretty sure this will work… and about changing Rtname
itself, should I alter it in RT_SiteConfig.pm, and make initialize-database
or doing this will initialize all the info instead of only the rtname?

How should I do it? Any advice from someone who has done it…?

 (See attached file: smime.p7s)

Community help: http://wiki.bestpractical.com
Commercial support: sales at bestpractical.com

Discover RT's hidden secrets with RT Essentials from O'Reilly Media.
Buy a copy at http://rtbook.bestpractical.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/octet-stream
Size: 3094 bytes
Desc: not available
URL: <http://lists.bestpractical.com/pipermail/rt-users/attachments/20070606/1c9f4169/attachment.obj>

More information about the rt-users mailing list