[Rt-commit] [rtir] 03/22: Make new 'add_constituency tool work with the --quiet option'
Jesse Vincent
jesse at bestpractical.com
Sun Mar 29 02:50:57 EDT 2015
This is an automated email from the git hooks/post-receive script.
jesse pushed a commit to branch 3.4/remove_old_constituencies
in repository rtir.
commit 55068799028672b7063da296a5790b5d374b8e3e
Author: Jesse Vincent <jesse at bestpractical.com>
Date: Sat Mar 28 16:31:20 2015 -0700
Make new 'add_constituency tool work with the --quiet option'
---
bin/add_constituency.in | 18 +++++++++---------
1 file changed, 9 insertions(+), 9 deletions(-)
diff --git a/bin/add_constituency.in b/bin/add_constituency.in
index 9302066..422ec72 100755
--- a/bin/add_constituency.in
+++ b/bin/add_constituency.in
@@ -169,18 +169,18 @@ die "Couldn't find 'RTIR default WHOIS server' custom field"
my $exist = cf_value_exists( $constituency );
-print "\nIf you continue then we'll...\n";
+debug "\nIf you continue then we'll...\n";
if ( $exist ) {
- print "* WARNING: skip adding constituency value, already exists.\n";
+ debug "* WARNING: skip adding constituency value, already exists.\n";
} else {
- print "* add new constituency value: '$constituency'.\n";
+ debug "* add new constituency value: '$constituency'.\n";
}
foreach my $lifecycle (@lifecycles) {
my $prefix = RT::IR::FriendlyLifecycle($lifecycle);
- print "* create queue '$prefix - $constituency' if it doesn't exist\n";
+ debug "* create queue '$prefix - $constituency' if it doesn't exist\n";
}
-print <<END;
+debug <<END;
* create group 'DutyTeam $constituency' if it don't exist
* create group 'ReadOnly $constituency' if it don't exist
* grant basic set of rights to the groups on the queues
@@ -498,8 +498,8 @@ sub rename_value {
$RT::Handle->BeginTransaction;
- print "\nIf you continue then we'll...\n";
- print "* rename constituency value '$old' into '$new'.\n";
+ debug "\nIf you continue then we'll...\n";
+ debug "* rename constituency value '$old' into '$new'.\n";
my $queues = RT::Queues->new(RT->SystemUser);
$queues->UnLimit;
while (my $queue = $queues->Next) {
@@ -508,13 +508,13 @@ sub rename_value {
my $newname = $oldname;
$newname =~ s/$old/$new/;
- print "* rename queue '$oldname' to '$newname'.\n";
+ debug "* rename queue '$oldname' to '$newname'.\n";
}
foreach my $basename (@queue_prefixes) {
}
- print <<END;
+ debug <<END;
* rename group 'DutyTeam $old' if it exists into 'DutyTeam $new'
* rename group 'ReadOnly $old' if it exists into 'ReadOnly $new'
--
To stop receiving notification emails like this one, please contact
the administrator of this repository.
More information about the rt-commit
mailing list