projects
/
freeside.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
rt 4.2.16
[freeside.git]
/
rt
/
devel
/
tools
/
rt-attributes-editor
diff --git
a/rt/devel/tools/rt-attributes-editor
b/rt/devel/tools/rt-attributes-editor
index
92caeaf
..
ac92434
100644
(file)
--- a/
rt/devel/tools/rt-attributes-editor
+++ b/
rt/devel/tools/rt-attributes-editor
@@
-3,7
+3,7
@@
#
# COPYRIGHT:
#
#
# COPYRIGHT:
#
-# This software is Copyright (c) 1996-201
2
Best Practical Solutions, LLC
+# This software is Copyright (c) 1996-201
9
Best Practical Solutions, LLC
# <sales@bestpractical.com>
#
# (Except where explicitly superseded by other copyright notices)
# <sales@bestpractical.com>
#
# (Except where explicitly superseded by other copyright notices)
@@
-49,19
+49,12
@@
use strict;
use warnings;
use Term::EditorEdit;
use strict;
use warnings;
use Term::EditorEdit;
-use Getopt::Long;
-my ($help, $key, $id);
-GetOptions('help|h' => \$help, 'key|k=s' => \$key, 'id=i' => \$id);
-if ( $help || !$id ) {
- require Pod::Usage;
- Pod::Usage::pod2usage({ verbose => 2 });
- exit;
-}
+use RT::Interface::CLI qw(Init);
+my ($key, $id);
+Init('key|k=s' => \$key, 'id=i' => \$id);
-require RT;
-RT::LoadConfig();
-RT::Init();
+Pod::Usage::pod2usage({ verbose => 2 }) unless $id;
require RT::Attribute;
my $attr = RT::Attribute->new( RT->SystemUser );
require RT::Attribute;
my $attr = RT::Attribute->new( RT->SystemUser );