Re: [rt-users] Commands by Email

2009-08-07 Thread Rich West
Argh.. I have the code in place (actually, improved upon the code by
replicating some of the detection code from the original plugin), and I
can see it is working via some test code, but the commands still show up
in the content of the ticket.

So.. that leads to the question: where did you put your code in to the
Transaction_Overlay.pm file in order to get it to work? :)

I had appended it to the end of the Content subroutine, and I can see
from the output I have going to /tmp/content.txt that the content is
getting modified appropriately:
 # more /tmp/content.txt
 omitting Owner: rwest
 omitting Status: open
 omitting CF.{CVendors}: IBM
 omitting
 This is a test

But when I look at the web GUI, I still see the commands:
 Subject:   Test
 To: support-...@ourdomain.net
 Date: Fri, 7 Aug 2009 11:44:15 -0400
 From: r...@helpdesk-dev.ourdomain.net
 Download (untitled) / with headers
 text/plain 71b
 Owner: rwest
 Status: open
 CF.{CVendors}: IBM

 This is a test

 --
 Rich

I just have this feeling like I have placed it in the wrong location in
the code.. :(

Thanks!
-Rich



$content = $self-loc(On [_1], [_2] wrote:,
$self-CreatedAsString, $self-CreatorObj-Name)
  . \n$content\n\n;
}

open (TEST,  /tmp/content.txt);

   # Remove quoted signature.
   $content =~ s/\n--\n(.*?)$//s;

   # Remove CommandByMail commands
   my @content = split (\n,$content);
   my @new_content = ();
   my $no_pseudoheaders = 0;
   my $line = ;
   foreach $line ( @content )
   {
if ($line =~ /^(?:(\S+)\s*?:\s*?(.*)\s*?|)$/)
{
   print TEST omitting $line\n;
}
  next if ($line =~ /^(?:(\S+)\s*?:\s*?(.*)\s*?|)$/);
print TEST $line\n;
  push ( @new_content, $line);
   }
   $content = join(\n,@new_content);
print $content;
close (TEST);

return ($content);
}

# }}}


=head2 Addresses

On 08/03/2009 10:20 AM, Andreas Ittgenshorst wrote:
 To remove the commands I added a few lines
 to /opt/rt3/local/lib/RT/Transaction_Overlay.pm

  # Remove quoted signature.
  $content =~ s/\n-- \n(.*?)$//s;

 +# Remove CommandByMail commands
 +my @content = split (\n,$content);
 +my @new_content = ();
 +foreach ( @content ) {
 +if ( ( $_ =~ /^Requestor:/ ) or
 +( $_ =~ /^CF.{Foo}:/ ) or
 +( $_ =~ /^CF.{WhatElse}:/ ) ) {
 +next;
 +}
 +push ( @new_content, $_);
 +}
 +$content = join(\n,@new_content);
 +
  # What's the longest line like?
  my $max = 0;



 - Andreas


   
 Another question, though.. is there a way to strip out the email
 commands from the content of the ticket as it shows up in Request
 Tracker?
 

___
http://lists.bestpractical.com/cgi-bin/mailman/listinfo/rt-users

Community help: http://wiki.bestpractical.com
Commercial support: sa...@bestpractical.com


Discover RT's hidden secrets with RT Essentials from O'Reilly Media. 
Buy a copy at http://rtbook.bestpractical.com


Re: [rt-users] Commands by Email

2009-08-06 Thread Rich West
Being unfamiliar with how to drop things in the local/lib tree, is the
process to simply create a file of the same name and the contents are
added?  or does the file entirely replace the original?

-Rich



On 08/03/2009 10:20 AM, Andreas Ittgenshorst wrote:
 To remove the commands I added a few lines
 to /opt/rt3/local/lib/RT/Transaction_Overlay.pm

  # Remove quoted signature.
  $content =~ s/\n-- \n(.*?)$//s;

 +# Remove CommandByMail commands
 +my @content = split (\n,$content);
 +my @new_content = ();
 +foreach ( @content ) {
 +if ( ( $_ =~ /^Requestor:/ ) or
 +( $_ =~ /^CF.{Foo}:/ ) or
 +( $_ =~ /^CF.{WhatElse}:/ ) ) {
 +next;
 +}
 +push ( @new_content, $_);
 +}
 +$content = join(\n,@new_content);
 +
  # What's the longest line like?
  my $max = 0;



 - Andreas


   
 Another question, though.. is there a way to strip out the email
 commands from the content of the ticket as it shows up in Request
 Tracker?
 

___
http://lists.bestpractical.com/cgi-bin/mailman/listinfo/rt-users

Community help: http://wiki.bestpractical.com
Commercial support: sa...@bestpractical.com


Discover RT's hidden secrets with RT Essentials from O'Reilly Media. 
Buy a copy at http://rtbook.bestpractical.com


Re: [rt-users] Commands by Email

2009-08-06 Thread Jerrad Pierce
On Thu, Aug 6, 2009 at 16:38, Rich Westrich.w...@wesmo.com wrote:
 Being unfamiliar with how to drop things in the local/lib tree, is the
 process to simply create a file of the same name and the contents are
 added?  or does the file entirely replace the original?
Local overrides original. Appending would raise all sorts of problems
(redefining subroutines, etc.)

-- 
Cambridge Energy Alliance: Save money. Save the planet.
___
http://lists.bestpractical.com/cgi-bin/mailman/listinfo/rt-users

Community help: http://wiki.bestpractical.com
Commercial support: sa...@bestpractical.com


Discover RT's hidden secrets with RT Essentials from O'Reilly Media. 
Buy a copy at http://rtbook.bestpractical.com


Re: [rt-users] Commands by Email

2009-08-03 Thread Andreas Ittgenshorst
To remove the commands I added a few lines
to /opt/rt3/local/lib/RT/Transaction_Overlay.pm

 # Remove quoted signature.
 $content =~ s/\n-- \n(.*?)$//s;

+# Remove CommandByMail commands
+my @content = split (\n,$content);
+my @new_content = ();
+foreach ( @content ) {
+if ( ( $_ =~ /^Requestor:/ ) or
+( $_ =~ /^CF.{Foo}:/ ) or
+( $_ =~ /^CF.{WhatElse}:/ ) ) {
+next;
+}
+push ( @new_content, $_);
+}
+$content = join(\n,@new_content);
+
 # What's the longest line like?
 my $max = 0;



- Andreas


 Another question, though.. is there a way to strip out the email
 commands from the content of the ticket as it shows up in Request
 Tracker?
 
 -Rich


___
http://lists.bestpractical.com/cgi-bin/mailman/listinfo/rt-users

Community help: http://wiki.bestpractical.com
Commercial support: sa...@bestpractical.com


Discover RT's hidden secrets with RT Essentials from O'Reilly Media. 
Buy a copy at http://rtbook.bestpractical.com


Re: [rt-users] Commands by Email

2009-07-23 Thread Rich West
The extension works rather well once you get past the caveats of the 
formatting.  With regard to the slimness of the documentation, it 
doesn't mention those 'simple rules', which forced me to comb through 
the code (which is rather clean) to determine the proper formatting 
which led to the discovery that outlook has a tendency to insert blank 
lines when the MIME conversion happens.


Also, the section describing how it applies to custom fields is fairly 
vague.  Are the curly braces required (is that what is meant by The 
curly braces are literal) for custom field declaration?  Would a 
correct example be CustomField.{Severity}: Severity 2 - Multiple Users 
Down?  Does AddCustomField set the custom field, or would that be 
CustomField?  What, if any, is the difference between AddCustomField 
and CustomField?


Specifically, I have been unable to get custom fields to be applied when 
testing this extension.  Everything else worked once I realized that my 
mail program was getting blank lines inserted. :(


-Rich


On 07/22/2009 04:53 PM, Ruslan Zakirov wrote:

What's so slim in the doc?

http://search.cpan.org/~falcone/RT-Extension-CommandByMail-0.07/lib/RT/Extension/CommandByMail.pm
http://search.cpan.org/~falcone/RT-Extension-CommandByMail-0.07/lib/RT/Interface/Email/Filter/TakeAction.pm#COMMANDS_commands_below

Simple rules: no html, no empty lines, commands like headers, but in body.

On Wed, Jul 22, 2009 at 11:14 PM, Rich Westrich.w...@wesmo.com  wrote:
   

Way back in the day, when I was heavily involved in the development of
RT, there was a way to send commands in to RT to set some of the
metadata (queue, owner, status, etc).

Now that the place I am at is heavily entrenched in to RT 3.8.4 and our
separate front-end form submission system is nearing completion (it's on
an ASP server.. not by my choice, but it is what it is..), I'm looking
in to how to get the latest RT to do the same.  I installed the
CommandsByMail extension, and it is parsing the email, but it isn't
parsing everything.  In fact, it is only processing the Owner setting.

I get the feeling like I am missing syntax, ordering, or something, but
I am not getting a lot (any) of debugging out of it.  Additionally, the
documentation is relatively slim.

Any pointers in the right direction are more than welcome. :)

Thanks!
-Rich
___
http://lists.bestpractical.com/cgi-bin/mailman/listinfo/rt-users

Community help: http://wiki.bestpractical.com
Commercial support: sa...@bestpractical.com


Discover RT's hidden secrets with RT Essentials from O'Reilly Media.
Buy a copy at http://rtbook.bestpractical.com

 




   


___
http://lists.bestpractical.com/cgi-bin/mailman/listinfo/rt-users

Community help: http://wiki.bestpractical.com
Commercial support: sa...@bestpractical.com


Discover RT's hidden secrets with RT Essentials from O'Reilly Media. 
Buy a copy at http://rtbook.bestpractical.com

Re: [rt-users] Commands by Email

2009-07-23 Thread Rich West
Another question, though.. is there a way to strip out the email 
commands from the content of the ticket as it shows up in Request Tracker?


-Rich

On 07/23/2009 10:56 AM, Rich West wrote:
The extension works rather well once you get past the caveats of the 
formatting.  With regard to the slimness of the documentation, it 
doesn't mention those 'simple rules', which forced me to comb through 
the code (which is rather clean) to determine the proper formatting 
which led to the discovery that outlook has a tendency to insert blank 
lines when the MIME conversion happens.


Also, the section describing how it applies to custom fields is fairly 
vague.  Are the curly braces required (is that what is meant by The 
curly braces are literal) for custom field declaration?  Would a 
correct example be CustomField.{Severity}: Severity 2 - Multiple 
Users Down?  Does AddCustomField set the custom field, or would 
that be CustomField?  What, if any, is the difference between 
AddCustomField and CustomField?


Specifically, I have been unable to get custom fields to be applied 
when testing this extension.  Everything else worked once I realized 
that my mail program was getting blank lines inserted. :(


-Rich


On 07/22/2009 04:53 PM, Ruslan Zakirov wrote:

What's so slim in the doc?

http://search.cpan.org/~falcone/RT-Extension-CommandByMail-0.07/lib/RT/Extension/CommandByMail.pm
http://search.cpan.org/~falcone/RT-Extension-CommandByMail-0.07/lib/RT/Interface/Email/Filter/TakeAction.pm#COMMANDS_commands_below

Simple rules: no html, no empty lines, commands like headers, but in body.

On Wed, Jul 22, 2009 at 11:14 PM, Rich Westrich.w...@wesmo.com  wrote:
   

Way back in the day, when I was heavily involved in the development of
RT, there was a way to send commands in to RT to set some of the
metadata (queue, owner, status, etc).

Now that the place I am at is heavily entrenched in to RT 3.8.4 and our
separate front-end form submission system is nearing completion (it's on
an ASP server.. not by my choice, but it is what it is..), I'm looking
in to how to get the latest RT to do the same.  I installed the
CommandsByMail extension, and it is parsing the email, but it isn't
parsing everything.  In fact, it is only processing the Owner setting.

I get the feeling like I am missing syntax, ordering, or something, but
I am not getting a lot (any) of debugging out of it.  Additionally, the
documentation is relatively slim.

Any pointers in the right direction are more than welcome. :)

Thanks!
-Rich
   


___
http://lists.bestpractical.com/cgi-bin/mailman/listinfo/rt-users

Community help: http://wiki.bestpractical.com
Commercial support: sa...@bestpractical.com


Discover RT's hidden secrets with RT Essentials from O'Reilly Media. 
Buy a copy at http://rtbook.bestpractical.com

Re: [rt-users] Commands by Email

2009-07-23 Thread Rich West
One item that should be documented is that this extension cannot handle 
spaces in the custom field names.  Spaces causes it to break. :(


-Rich


On 07/23/2009 10:56 AM, Rich West wrote:
The extension works rather well once you get past the caveats of the 
formatting.  With regard to the slimness of the documentation, it 
doesn't mention those 'simple rules', which forced me to comb through 
the code (which is rather clean) to determine the proper formatting 
which led to the discovery that outlook has a tendency to insert blank 
lines when the MIME conversion happens.


Also, the section describing how it applies to custom fields is fairly 
vague.  Are the curly braces required (is that what is meant by The 
curly braces are literal) for custom field declaration?  Would a 
correct example be CustomField.{Severity}: Severity 2 - Multiple 
Users Down?  Does AddCustomField set the custom field, or would 
that be CustomField?  What, if any, is the difference between 
AddCustomField and CustomField?


Specifically, I have been unable to get custom fields to be applied 
when testing this extension.  Everything else worked once I realized 
that my mail program was getting blank lines inserted. :(


-Rich


On 07/22/2009 04:53 PM, Ruslan Zakirov wrote:

What's so slim in the doc?

http://search.cpan.org/~falcone/RT-Extension-CommandByMail-0.07/lib/RT/Extension/CommandByMail.pm
http://search.cpan.org/~falcone/RT-Extension-CommandByMail-0.07/lib/RT/Interface/Email/Filter/TakeAction.pm#COMMANDS_commands_below

Simple rules: no html, no empty lines, commands like headers, but in body.

On Wed, Jul 22, 2009 at 11:14 PM, Rich Westrich.w...@wesmo.com  wrote:
   

Way back in the day, when I was heavily involved in the development of
RT, there was a way to send commands in to RT to set some of the
metadata (queue, owner, status, etc).

Now that the place I am at is heavily entrenched in to RT 3.8.4 and our
separate front-end form submission system is nearing completion (it's on
an ASP server.. not by my choice, but it is what it is..), I'm looking
in to how to get the latest RT to do the same.  I installed the
CommandsByMail extension, and it is parsing the email, but it isn't
parsing everything.  In fact, it is only processing the Owner setting.

I get the feeling like I am missing syntax, ordering, or something, but
I am not getting a lot (any) of debugging out of it.  Additionally, the
documentation is relatively slim.

Any pointers in the right direction are more than welcome. :)

Thanks!
-Rich
   


___
http://lists.bestpractical.com/cgi-bin/mailman/listinfo/rt-users

Community help: http://wiki.bestpractical.com
Commercial support: sa...@bestpractical.com


Discover RT's hidden secrets with RT Essentials from O'Reilly Media. 
Buy a copy at http://rtbook.bestpractical.com

Re: [rt-users] Commands by Email

2009-07-22 Thread Ruslan Zakirov
What's so slim in the doc?

http://search.cpan.org/~falcone/RT-Extension-CommandByMail-0.07/lib/RT/Extension/CommandByMail.pm
http://search.cpan.org/~falcone/RT-Extension-CommandByMail-0.07/lib/RT/Interface/Email/Filter/TakeAction.pm#COMMANDS_commands_below

Simple rules: no html, no empty lines, commands like headers, but in body.

On Wed, Jul 22, 2009 at 11:14 PM, Rich Westrich.w...@wesmo.com wrote:
 Way back in the day, when I was heavily involved in the development of
 RT, there was a way to send commands in to RT to set some of the
 metadata (queue, owner, status, etc).

 Now that the place I am at is heavily entrenched in to RT 3.8.4 and our
 separate front-end form submission system is nearing completion (it's on
 an ASP server.. not by my choice, but it is what it is..), I'm looking
 in to how to get the latest RT to do the same.  I installed the
 CommandsByMail extension, and it is parsing the email, but it isn't
 parsing everything.  In fact, it is only processing the Owner setting.

 I get the feeling like I am missing syntax, ordering, or something, but
 I am not getting a lot (any) of debugging out of it.  Additionally, the
 documentation is relatively slim.

 Any pointers in the right direction are more than welcome. :)

 Thanks!
 -Rich
 ___
 http://lists.bestpractical.com/cgi-bin/mailman/listinfo/rt-users

 Community help: http://wiki.bestpractical.com
 Commercial support: sa...@bestpractical.com


 Discover RT's hidden secrets with RT Essentials from O'Reilly Media.
 Buy a copy at http://rtbook.bestpractical.com




-- 
Best regards, Ruslan.
___
http://lists.bestpractical.com/cgi-bin/mailman/listinfo/rt-users

Community help: http://wiki.bestpractical.com
Commercial support: sa...@bestpractical.com


Discover RT's hidden secrets with RT Essentials from O'Reilly Media. 
Buy a copy at http://rtbook.bestpractical.com

Re: [rt-users] Commands by Email

2009-07-22 Thread bouncy...@gmail.com
I also would be interested in knowing what the current state of this is as I 
want to use th systrm in an entire email read remote fashion

--
Sent via Cricket Mobile Email

--Original Message--
From: Rich West rich.w...@wesmo.com
To: rt-users@lists.bestpractical.com rt-users@lists.bestpractical.com
Date: Wed, 22 Jul 2009 03:14:49 PM -0400
Subject: [rt-users] Commands by Email

Way back in the day, when I was heavily involved in the development of 
RT, there was a way to send commands in to RT to set some of the 
metadata (queue, owner, status, etc).

Now that the place I am at is heavily entrenched in to RT 3.8.4 and our 
separate front-end form submission system is nearing completion (it's on 
an ASP server.. not by my choice, but it is what it is..), I'm looking 
in to how to get the latest RT to do the same.  I installed the 
CommandsByMail extension, and it is parsing the email, but it isn't 
parsing everything.  In fact, it is only processing the Owner setting.

I get the feeling like I am missing syntax, ordering, or something, but 
I am not getting a lot (any) of debugging out of it.  Additionally, the 
documentation is relatively slim.

Any pointers in the right direction are more than welcome. :)

Thanks!
-Rich
___
http://lists.bestpractical.com/cgi-bin/mailman/listinfo/rt-users

Community help: http://wiki.bestpractical.com
Commercial support: sa...@bestpractical.com


Discover RT's hidden secrets with RT Essentials from O'Reilly Media. 
Buy a copy at http://rtbook.bestpractical.com

___
http://lists.bestpractical.com/cgi-bin/mailman/listinfo/rt-users

Community help: http://wiki.bestpractical.com
Commercial support: sa...@bestpractical.com


Discover RT's hidden secrets with RT Essentials from O'Reilly Media. 
Buy a copy at http://rtbook.bestpractical.com


Re: [rt-users] Commands by email

2008-10-14 Thread Jesse Vincent



On Tue 14.Oct'08 at 13:00:10 +0200, Richard Hartmann wrote:
 Hi all,
 
 I thought RT 3.8.x had email commands incorporated and does not need
 CommandByMail, any more. Yet, I can't see anything in the docs/wiki
 about it. I don't want to enable the plugin without checking if that is
 the right way to go.
 
 So, does RT 3.8.x come with CommandByMail or not?

No, it's not built in to 3.8
 
 
 Thanks,
 Richard
 ___
 http://lists.bestpractical.com/cgi-bin/mailman/listinfo/rt-users
 
 Community help: http://wiki.bestpractical.com
 Commercial support: [EMAIL PROTECTED]
 
 
 Discover RT's hidden secrets with RT Essentials from O'Reilly Media. 
 Buy a copy at http://rtbook.bestpractical.com
 

-- 


pgpVjilpWxD3n.pgp
Description: PGP signature
___
http://lists.bestpractical.com/cgi-bin/mailman/listinfo/rt-users

Community help: http://wiki.bestpractical.com
Commercial support: [EMAIL PROTECTED]


Discover RT's hidden secrets with RT Essentials from O'Reilly Media. 
Buy a copy at http://rtbook.bestpractical.com