[Bps-public-commit] rt-extension-nonwatcherrecipients branch, master, updated. 4a41aac3fb7ce4a2014ed3a5ac19d207bc22f6ee
Thomas Sibley
trs at bestpractical.com
Tue Jan 29 17:46:33 EST 2013
The branch, master has been updated
via 4a41aac3fb7ce4a2014ed3a5ac19d207bc22f6ee (commit)
via 0ebd5b95273993aec0b6bf7e7020bdcaeda2f6be (commit)
via 6feb3e3424e331ccd3d0b0159b2219d0f20bf3a5 (commit)
via ca0ff0cf276c9a34526952463fcf1731a19ceb9c (commit)
via 2f0a3adf12168d0bb677005fe2ab0b265092e96f (commit)
via 8306ac5a26bea6a9442072720cce80dde8f2c443 (commit)
via 879708bab9b887de7bfb0ce2344a8257d80cae7e (commit)
via 6a8fb942ddc48eda5262e88a350d906f8e75c15a (commit)
via 3415e78b806142688c55e43e3b7790b462e58e0e (commit)
from 1c26e6d5ffb7bb6e3be651f68b534fc20ed7b903 (commit)
Summary of changes:
MANIFEST | 25 +---------
MANIFEST.SKIP | 65 ++++++++++++++++++++++++++
README | 68 ++++++++++++++-------------
etc/initialdata | 6 +--
inc/Module/Install/RTx/Factory.pm | 2 +-
inc/Module/Install/ReadmeFromPod.pm | 2 +-
lib/RT/Extension/NonWatcherRecipients.pm | 79 ++++++++++++++++----------------
7 files changed, 144 insertions(+), 103 deletions(-)
create mode 100644 MANIFEST.SKIP
- Log -----------------------------------------------------------------
commit 3415e78b806142688c55e43e3b7790b462e58e0e
Author: Thomas Sibley <trs at bestpractical.com>
Date: Tue Jan 29 14:23:35 2013 -0800
The added X-RT-Queue header has nothing to do with this extension
It was mistakenly copied from an internal template.
diff --git a/etc/initialdata b/etc/initialdata
index de1887e..94f3c15 100644
--- a/etc/initialdata
+++ b/etc/initialdata
@@ -4,7 +4,6 @@
Description => 'Note non-ticket-watchers receiving email on correspondence',
Content => <<' TEMPLATE',
RT-Attach-Message: yes
-X-RT-Queue: {$Ticket->QueueObj->Name}
<URL: {RT->Config->Get('WebURL')}Ticket/Display.html?id={$Ticket->id} >
commit 6a8fb942ddc48eda5262e88a350d906f8e75c15a
Author: Thomas Sibley <trs at bestpractical.com>
Date: Tue Jan 29 14:24:44 2013 -0800
Remove an unnecessary variable for a simpler template
diff --git a/etc/initialdata b/etc/initialdata
index 94f3c15..6495cdf 100644
--- a/etc/initialdata
+++ b/etc/initialdata
@@ -7,9 +7,7 @@ RT-Attach-Message: yes
<URL: {RT->Config->Get('WebURL')}Ticket/Display.html?id={$Ticket->id} >
-{ my $message = RT::Extension::NonWatcherRecipients->FindRecipients(Transaction => $Transaction, Ticket => $Ticket);
- $message;
-}
+{ RT::Extension::NonWatcherRecipients->FindRecipients(Transaction => $Transaction, Ticket => $Ticket) }
{$Transaction->Content()}
TEMPLATE
commit 879708bab9b887de7bfb0ce2344a8257d80cae7e
Author: Thomas Sibley <trs at bestpractical.com>
Date: Tue Jan 29 14:33:18 2013 -0800
Touch up the documentation for clarity
diff --git a/README b/README
index 09a542d..b9ccc03 100644
--- a/README
+++ b/README
@@ -1,6 +1,6 @@
NAME
- RT-Extension-NonWatcherRecipients - Notify when non-watchers are CC'd on
- RT email
+ RT-Extension-NonWatcherRecipients - Note when non-watchers received an
+ email which RT redistributed to watchers
INSTALLATION
"perl Makefile.PL"
@@ -34,10 +34,10 @@ DESCRIPTION
Sometimes email addresses will be added to a thread attached to an RT
ticket because someone wants someone else to know what's going on.
However, if that person isn't added as a Watcher on the RT ticket,
- they'll likely miss correspondence on the thread as RT doesn't know
- about them.
+ they'll likely miss subsequent correspondence on the thread as RT
+ doesn't know about them.
- "RT::Extension::NonWatcherRecipients" looks for email addresses on
+ RT::Extension::NonWatcherRecipients looks for email addresses on
correspondence that RT doesn't know about and posts a message like this
so you know someone may need to be added:
@@ -62,15 +62,15 @@ USAGE
template because you'll need RT privileges to add the user to the
ticket.
- You can also add this to existing templates by adding the following
- call:
+ You can also add this to existing templates by adding the following to
+ any template:
- RT::Extension::NonWatcherRecipients->FindRecipients(
- Transaction => $Transaction, Ticket => $Ticket );
+ { RT::Extension::NonWatcherRecipients->FindRecipients(
+ Transaction => $Transaction, Ticket => $Ticket ) }
- As described below, this method returns the message which you can insert
- in your template wherever you like. You can also look at the installed
- template for an example.
+ As described below, this method returns a message which is then inserted
+ into your template. Look at the installed template for an example. You
+ may also call the method and use the returned string however you'd like.
METHODS
FindRecipients
diff --git a/lib/RT/Extension/NonWatcherRecipients.pm b/lib/RT/Extension/NonWatcherRecipients.pm
index b36e034..bff96bf 100644
--- a/lib/RT/Extension/NonWatcherRecipients.pm
+++ b/lib/RT/Extension/NonWatcherRecipients.pm
@@ -6,8 +6,7 @@ our $VERSION = '0.01';
=head1 NAME
-RT-Extension-NonWatcherRecipients - Notify when non-watchers are CC'd on
-RT email
+RT-Extension-NonWatcherRecipients - Note when non-watchers received an email which RT redistributed to watchers
=head1 INSTALLATION
@@ -49,12 +48,12 @@ or add C<RT::Extension::NonWatcherRecipients> to your existing C<@Plugins> line.
=head1 DESCRIPTION
-Sometimes email addresses will be added to a thread attached to an RT
-ticket because someone wants someone else to know what's going on. However,
-if that person isn't added as a Watcher on the RT ticket, they'll likely
-miss correspondence on the thread as RT doesn't know about them.
+Sometimes email addresses will be added to a thread attached to an RT ticket
+because someone wants someone else to know what's going on. However, if that
+person isn't added as a Watcher on the RT ticket, they'll likely miss
+subsequent correspondence on the thread as RT doesn't know about them.
-C<RT::Extension::NonWatcherRecipients> looks for email addresses on
+L<RT::Extension::NonWatcherRecipients> looks for email addresses on
correspondence that RT doesn't know about and posts a message like this
so you know someone may need to be added:
@@ -81,14 +80,14 @@ C<Admin Correspondence> template because you'll need RT privileges
to add the user to the ticket.
You can also add this to existing templates by adding the following
-call:
+to any template:
- RT::Extension::NonWatcherRecipients->FindRecipients(
- Transaction => $Transaction, Ticket => $Ticket );
+ { RT::Extension::NonWatcherRecipients->FindRecipients(
+ Transaction => $Transaction, Ticket => $Ticket ) }
-As described below, this method returns the message which you can insert
-in your template wherever you like. You can also look at the installed
-template for an example.
+As described below, this method returns a message which is then inserted into
+your template. Look at the installed template for an example. You may also
+call the method and use the returned string however you'd like.
=head1 METHODS
commit 8306ac5a26bea6a9442072720cce80dde8f2c443
Author: Thomas Sibley <trs at bestpractical.com>
Date: Tue Jan 29 14:34:11 2013 -0800
Add myself as the pre-extension author
diff --git a/README b/README
index b9ccc03..5f643b2 100644
--- a/README
+++ b/README
@@ -85,6 +85,8 @@ METHODS
AUTHOR
Jim Brandt <jbrandt at bestpractical.com>
+ Thomas Sibley <trs at bestpractical.com>
+
BUGS
All bugs should be reported via email to
bug-RT-Extension-NonWatcherRecipients at rt.cpan.org
diff --git a/lib/RT/Extension/NonWatcherRecipients.pm b/lib/RT/Extension/NonWatcherRecipients.pm
index bff96bf..a634a5d 100644
--- a/lib/RT/Extension/NonWatcherRecipients.pm
+++ b/lib/RT/Extension/NonWatcherRecipients.pm
@@ -177,6 +177,8 @@ sub Format {
Jim Brandt <jbrandt at bestpractical.com>
+Thomas Sibley <trs at bestpractical.com>
+
=head1 BUGS
All bugs should be reported via email to
commit 2f0a3adf12168d0bb677005fe2ab0b265092e96f
Author: Thomas Sibley <trs at bestpractical.com>
Date: Tue Jan 29 14:34:33 2013 -0800
Fix indentation
Looks like copying and pasting in vim without :set paste.
diff --git a/lib/RT/Extension/NonWatcherRecipients.pm b/lib/RT/Extension/NonWatcherRecipients.pm
index a634a5d..7c7b94e 100644
--- a/lib/RT/Extension/NonWatcherRecipients.pm
+++ b/lib/RT/Extension/NonWatcherRecipients.pm
@@ -127,20 +127,20 @@ sub FindRecipients {
for my $hdr (qw(From To Cc RT-Send-Cc RT-Send-Bcc)) {
my @new = grep { not $self->IsWatcher($_->address) } @{$addr{$hdr} || []};
$recipients .= " $hdr: " . $self->Format(\@new) . "\n"
- if @new;
+ if @new;
}
if ($recipients) {
$message = "The following people received a copy of this email "
- . "but are not on the ticket. You may want to add them "
- . "before replying: ${RT::WebURL}Ticket/ModifyPeople.html?id="
- . $Ticket->id . "\n\n$recipients";
+ . "but are not on the ticket. You may want to add them "
+ . "before replying: ${RT::WebURL}Ticket/ModifyPeople.html?id="
+ . $Ticket->id . "\n\n$recipients";
}
# Show From if there's a different phrase; this catches name changes and "via RT"
my @from = grep { $_->phrase ne $creator } @{$addr{From} || []};
$message = " From: " . $self->Format(\@from) . ($message ? "\n\n$message" : "\n")
- if @from;
+ if @from;
if ($message) {
$message = ("-" x 72) . "\n$message";
commit ca0ff0cf276c9a34526952463fcf1731a19ceb9c
Author: Thomas Sibley <trs at bestpractical.com>
Date: Tue Jan 29 14:36:40 2013 -0800
Move Installation after Description but before Usage
It's more useful to read what this extension is about before knowing how
to install it.
diff --git a/README b/README
index 5f643b2..9a8ac71 100644
--- a/README
+++ b/README
@@ -2,6 +2,30 @@ NAME
RT-Extension-NonWatcherRecipients - Note when non-watchers received an
email which RT redistributed to watchers
+DESCRIPTION
+ Sometimes email addresses will be added to a thread attached to an RT
+ ticket because someone wants someone else to know what's going on.
+ However, if that person isn't added as a Watcher on the RT ticket,
+ they'll likely miss subsequent correspondence on the thread as RT
+ doesn't know about them.
+
+ RT::Extension::NonWatcherRecipients looks for email addresses on
+ correspondence that RT doesn't know about and posts a message like this
+ so you know someone may need to be added:
+
+ ------------------------------------------------------------------------
+ From: "A User" <a-user at example.com>
+
+ The following people received a copy of this email but are not on the ticket.
+ You may want to add them before replying:
+ https://YourRT.com/Ticket/ModifyPeople.html?id=12345
+
+ Cc: "Non Watcher" <non-watcher at example.com>
+ ------------------------------------------------------------------------
+
+ If you want the person to see correspondence, you can click the link and
+ add them. If not, you can just ignore the message.
+
INSTALLATION
"perl Makefile.PL"
"make"
@@ -30,30 +54,6 @@ INSTALLATION
Restart your webserver
-DESCRIPTION
- Sometimes email addresses will be added to a thread attached to an RT
- ticket because someone wants someone else to know what's going on.
- However, if that person isn't added as a Watcher on the RT ticket,
- they'll likely miss subsequent correspondence on the thread as RT
- doesn't know about them.
-
- RT::Extension::NonWatcherRecipients looks for email addresses on
- correspondence that RT doesn't know about and posts a message like this
- so you know someone may need to be added:
-
- ------------------------------------------------------------------------
- From: "A User" <a-user at example.com>
-
- The following people received a copy of this email but are not on the ticket.
- You may want to add them before replying:
- https://YourRT.com/Ticket/ModifyPeople.html?id=12345
-
- Cc: "Non Watcher" <non-watcher at example.com>
- ------------------------------------------------------------------------
-
- If you want the person to see correspondence, you can click the link and
- add them. If not, you can just ignore the message.
-
USAGE
If you run the "make initdb" step, a new global template called
"NonWatcherRecipients Admin Correspondence" is installed on your system.
diff --git a/lib/RT/Extension/NonWatcherRecipients.pm b/lib/RT/Extension/NonWatcherRecipients.pm
index 7c7b94e..ca466cf 100644
--- a/lib/RT/Extension/NonWatcherRecipients.pm
+++ b/lib/RT/Extension/NonWatcherRecipients.pm
@@ -8,6 +8,30 @@ our $VERSION = '0.01';
RT-Extension-NonWatcherRecipients - Note when non-watchers received an email which RT redistributed to watchers
+=head1 DESCRIPTION
+
+Sometimes email addresses will be added to a thread attached to an RT ticket
+because someone wants someone else to know what's going on. However, if that
+person isn't added as a Watcher on the RT ticket, they'll likely miss
+subsequent correspondence on the thread as RT doesn't know about them.
+
+L<RT::Extension::NonWatcherRecipients> looks for email addresses on
+correspondence that RT doesn't know about and posts a message like this
+so you know someone may need to be added:
+
+ ------------------------------------------------------------------------
+ From: "A User" <a-user at example.com>
+
+ The following people received a copy of this email but are not on the ticket.
+ You may want to add them before replying:
+ https://YourRT.com/Ticket/ModifyPeople.html?id=12345
+
+ Cc: "Non Watcher" <non-watcher at example.com>
+ ------------------------------------------------------------------------
+
+If you want the person to see correspondence, you can click the link and add
+them. If not, you can just ignore the message.
+
=head1 INSTALLATION
=over
@@ -46,30 +70,6 @@ or add C<RT::Extension::NonWatcherRecipients> to your existing C<@Plugins> line.
=back
-=head1 DESCRIPTION
-
-Sometimes email addresses will be added to a thread attached to an RT ticket
-because someone wants someone else to know what's going on. However, if that
-person isn't added as a Watcher on the RT ticket, they'll likely miss
-subsequent correspondence on the thread as RT doesn't know about them.
-
-L<RT::Extension::NonWatcherRecipients> looks for email addresses on
-correspondence that RT doesn't know about and posts a message like this
-so you know someone may need to be added:
-
- ------------------------------------------------------------------------
- From: "A User" <a-user at example.com>
-
- The following people received a copy of this email but are not on the ticket.
- You may want to add them before replying:
- https://YourRT.com/Ticket/ModifyPeople.html?id=12345
-
- Cc: "Non Watcher" <non-watcher at example.com>
- ------------------------------------------------------------------------
-
-If you want the person to see correspondence, you can click the link and add
-them. If not, you can just ignore the message.
-
=head1 USAGE
If you run the C<make initdb> step, a new global template called
commit 6feb3e3424e331ccd3d0b0159b2219d0f20bf3a5
Author: Thomas Sibley <trs at bestpractical.com>
Date: Tue Jan 29 14:37:27 2013 -0800
Remove bogus files from the MANIFEST and add a MANIFEST.SKIP excluding them
diff --git a/MANIFEST b/MANIFEST
index 278a1cc..b04ea38 100644
--- a/MANIFEST
+++ b/MANIFEST
@@ -1,5 +1,4 @@
etc/initialdata
-gitignore
inc/Module/Install.pm
inc/Module/Install/Base.pm
inc/Module/Install/Can.pm
@@ -13,32 +12,10 @@ inc/Module/Install/Substitute.pm
inc/Module/Install/Win32.pm
inc/Module/Install/WriteAll.pm
lib/RT/Extension/NonWatcherRecipients.pm
-lib/RT/Extension/NonWatcherRecipients/Test.pm
lib/RT/Extension/NonWatcherRecipients/Test.pm.in
Makefile.PL
MANIFEST This list of files
+MANIFEST.SKIP
META.yml
README
xt/basic.t
-xt/tmp/basic.t-7GQX7KKv/mailbox.eml
-xt/tmp/basic.t-7GQX7KKv/rt.debug.log
-xt/tmp/basic.t-7GQX7KKv/RT_SiteConfig.pm
-xt/tmp/basic.t-9hyB6JyS/mailbox.eml
-xt/tmp/basic.t-9hyB6JyS/rt.debug.log
-xt/tmp/basic.t-9hyB6JyS/RT_SiteConfig.pm
-xt/tmp/basic.t-Au3O7mKv/mailbox.eml
-xt/tmp/basic.t-Au3O7mKv/rt.debug.log
-xt/tmp/basic.t-Au3O7mKv/RT_SiteConfig.pm
-xt/tmp/basic.t-gmgB4ilZ/mailbox.eml
-xt/tmp/basic.t-gmgB4ilZ/rt.debug.log
-xt/tmp/basic.t-gmgB4ilZ/RT_SiteConfig.pm
-xt/tmp/basic.t-IMBvlhAt/mailbox.eml
-xt/tmp/basic.t-IMBvlhAt/rt.debug.log
-xt/tmp/basic.t-IMBvlhAt/RT_SiteConfig.pm
-xt/tmp/basic.t-jb_Mz1Xv/mailbox.eml
-xt/tmp/basic.t-jb_Mz1Xv/rt.debug.log
-xt/tmp/basic.t-jb_Mz1Xv/RT_SiteConfig.pm
-xt/tmp/basic.t-KtBdjXbU/mailbox.eml
-xt/tmp/basic.t-KtBdjXbU/rt.debug.log
-xt/tmp/basic.t-KtBdjXbU/RT_SiteConfig.pm
-xt/tmp/ports
diff --git a/MANIFEST.SKIP b/MANIFEST.SKIP
new file mode 100644
index 0000000..89c7538
--- /dev/null
+++ b/MANIFEST.SKIP
@@ -0,0 +1,65 @@
+
+#!start included /opt/perlbrew/perls/perl-5.16.2/lib/5.16.2/ExtUtils/MANIFEST.SKIP
+# Avoid version control files.
+\bRCS\b
+\bCVS\b
+\bSCCS\b
+,v$
+\B\.svn\b
+\B\.git\b
+\B\.gitignore\b
+\b_darcs\b
+\B\.cvsignore$
+
+# Avoid VMS specific MakeMaker generated files
+\bDescrip.MMS$
+\bDESCRIP.MMS$
+\bdescrip.mms$
+
+# Avoid Makemaker generated and utility files.
+\bMANIFEST\.bak
+\bMakefile$
+\bblib/
+\bMakeMaker-\d
+\bpm_to_blib\.ts$
+\bpm_to_blib$
+\bblibdirs\.ts$ # 6.18 through 6.25 generated this
+
+# Avoid Module::Build generated and utility files.
+\bBuild$
+\b_build/
+\bBuild.bat$
+\bBuild.COM$
+\bBUILD.COM$
+\bbuild.com$
+
+# Avoid temp and backup files.
+~$
+\.old$
+\#$
+\b\.#
+\.bak$
+\.tmp$
+\.#
+\.rej$
+
+# Avoid OS-specific files/dirs
+# Mac OSX metadata
+\B\.DS_Store
+# Mac OSX SMB mount metadata files
+\B\._
+
+# Avoid Devel::Cover and Devel::CoverX::Covered files.
+\bcover_db\b
+\bcovered\b
+
+# Avoid MYMETA files
+^MYMETA\.
+#!end included /opt/perlbrew/perls/perl-5.16.2/lib/5.16.2/ExtUtils/MANIFEST.SKIP
+
+
+lib/RT/Extension/NonWatcherRecipients/Test\.pm$
+
+x?t/tmp/
+MYMETA\.(json|yml)
+\.tar\.gz$
commit 0ebd5b95273993aec0b6bf7e7020bdcaeda2f6be
Author: Thomas Sibley <trs at bestpractical.com>
Date: Tue Jan 29 14:38:28 2013 -0800
Update build toolchain to the latest
diff --git a/inc/Module/Install/RTx/Factory.pm b/inc/Module/Install/RTx/Factory.pm
index a8702e4..76ab761 100644
--- a/inc/Module/Install/RTx/Factory.pm
+++ b/inc/Module/Install/RTx/Factory.pm
@@ -34,7 +34,7 @@ sub RTxInitDB {
"--action" => $action,
"--datadir" => "etc",
(($action eq 'insert') ? ("--datafile" => "etc/initialdata") : ()),
- "--dba" => $RT::DatabaseUser,
+ "--dba" => $RT::DatabaseAdmin || $RT::DatabaseUser,
"--prompt-for-dba-password" => '',
(RT::System->can('AddUpgradeHistory') ? ("--package" => $name, "--ext-version" => $version) : ()),
);
diff --git a/inc/Module/Install/ReadmeFromPod.pm b/inc/Module/Install/ReadmeFromPod.pm
index fb7075f..6a80818 100644
--- a/inc/Module/Install/ReadmeFromPod.pm
+++ b/inc/Module/Install/ReadmeFromPod.pm
@@ -7,7 +7,7 @@ use warnings;
use base qw(Module::Install::Base);
use vars qw($VERSION);
-$VERSION = '0.18';
+$VERSION = '0.20';
sub readme_from {
my $self = shift;
commit 4a41aac3fb7ce4a2014ed3a5ac19d207bc22f6ee
Author: Thomas Sibley <trs at bestpractical.com>
Date: Tue Jan 29 14:41:37 2013 -0800
Avoid extra newlines in the template by padding the message appropriately
diff --git a/etc/initialdata b/etc/initialdata
index 6495cdf..8d83fe1 100644
--- a/etc/initialdata
+++ b/etc/initialdata
@@ -8,7 +8,6 @@ RT-Attach-Message: yes
<URL: {RT->Config->Get('WebURL')}Ticket/Display.html?id={$Ticket->id} >
{ RT::Extension::NonWatcherRecipients->FindRecipients(Transaction => $Transaction, Ticket => $Ticket) }
-
{$Transaction->Content()}
TEMPLATE
};
diff --git a/lib/RT/Extension/NonWatcherRecipients.pm b/lib/RT/Extension/NonWatcherRecipients.pm
index ca466cf..e98a409 100644
--- a/lib/RT/Extension/NonWatcherRecipients.pm
+++ b/lib/RT/Extension/NonWatcherRecipients.pm
@@ -143,8 +143,8 @@ sub FindRecipients {
if @from;
if ($message) {
- $message = ("-" x 72) . "\n$message";
- $message .= ("-" x 72);
+ my $sep = "-" x 72;
+ $message = "$sep\n$message$sep\n";
}
return $message;
-----------------------------------------------------------------------
More information about the Bps-public-commit
mailing list