[monitoring-plugin-perl] keep the old name in copyright for more ...

Git Repository git at nagios-plugins.org
Wed Jan 22 09:10:03 CET 2014


 Module: monitoring-plugin-perl
 Branch: master
 Commit: dfae38b656242898ce962c9ad93ed66be45fc3d4
 Author: Sven Nierlein <sven at nierlein.de>
   Date: Mon Jan 20 14:49:14 2014 +0100
    URL: https://www.nagios-plugins.org/repositories/monitoring-plugin-perl/commit/?id=dfae38b

keep the old name in copyright for more transparency

Signed-off-by: Sven Nierlein <sven at nierlein.de>

---

 MANIFEST                             |  3 --
 META.yml                             | 53 ++++++++++++++++++++++++------------
 Makefile.PL                          | 14 ++++------
 README                               |  5 ++--
 lib/Monitoring/Plugin.pm             |  5 ++--
 lib/Monitoring/Plugin/Config.pm      | 10 +++++--
 lib/Monitoring/Plugin/ExitResult.pm  |  9 ++++--
 lib/Monitoring/Plugin/Functions.pm   |  9 +++---
 lib/Monitoring/Plugin/Getopt.pm      | 12 +++++---
 lib/Monitoring/Plugin/Performance.pm |  4 +--
 lib/Monitoring/Plugin/Range.pm       |  4 +--
 lib/Monitoring/Plugin/Threshold.pm   |  4 +--
 notes                                |  9 +++---
 t/check_stuff.pl                     | 26 +++++++++---------
 14 files changed, 98 insertions(+), 69 deletions(-)

diff --git a/MANIFEST b/MANIFEST
index 8ccb51c..3a48778 100644
--- a/MANIFEST
+++ b/MANIFEST
@@ -1,11 +1,8 @@
 Changes
-inc/Module/AutoInstall.pm
 inc/Module/Install.pm
-inc/Module/Install/AutoInstall.pm
 inc/Module/Install/Base.pm
 inc/Module/Install/Can.pm
 inc/Module/Install/Fetch.pm
-inc/Module/Install/Include.pm
 inc/Module/Install/Makefile.pm
 inc/Module/Install/Metadata.pm
 inc/Module/Install/Win32.pm
diff --git a/META.yml b/META.yml
index 0a71585..ebeebb1 100644
--- a/META.yml
+++ b/META.yml
@@ -1,19 +1,36 @@
-# http://module-build.sourceforge.net/META-spec.html
-#XXXXXXX This is a prototype!!!  It will change in the future!!! XXXXX#
-name:         Nagios-Plugin
-version:      0.21
-version_from: lib/Nagios/Plugin/Functions.pm
-installdirs:  site
-requires:
-    Carp:                          0
-    Class::Accessor:               0
-    Config::Tiny:                  0
-    File::Basename:                0
-    File::Spec:                    0
-    IO::File:                      0
-    Math::Calc::Units:             0
-    Params::Validate:              0
-    Test::More:                    0.62
-
+---
+abstract: ~
+author:
+  - 'This code is maintained by the Monitoring Plugin Development Team: see'
+  - 'Monitoring Plugin Team <devel at monitoring-plugins.org>'
+build_requires:
+  ExtUtils::MakeMaker: 6.59
+  Test::More: 0.62
+configure_requires:
+  ExtUtils::MakeMaker: 6.59
 distribution_type: module
-generated_by: ExtUtils::MakeMaker version 6.17
+dynamic_config: 1
+generated_by: 'Module::Install version 1.06'
+license: perl
+meta-spec:
+  url: http://module-build.sourceforge.net/META-spec-v1.4.html
+  version: 1.4
+name: Monitoring-Plugin
+no_index:
+  directory:
+    - inc
+    - t
+requires:
+  Carp: 0
+  Class::Accessor: 0
+  Config::Tiny: 0
+  File::Basename: 0
+  File::Spec: 0
+  IO::File: 0
+  Math::Calc::Units: 0
+  Params::Validate: 0
+  perl: 5.6.0
+resources:
+  license: http://dev.perl.org/licenses/
+  repository: https://github.com/monitoring-plugins/monitoring-plugin-perl
+version: 0.37
diff --git a/Makefile.PL b/Makefile.PL
index d1f0c2a..2fa285d 100644
--- a/Makefile.PL
+++ b/Makefile.PL
@@ -1,10 +1,10 @@
 use inc::Module::Install;
 
-name     'Monitoring-Plugin';
-all_from 'lib/Monitoring/Plugin/Functions.pm';
-author   q{Monitoring Plugin Team <devel at monitoring-plugins.org>};
-license  'perl';
-repository 'https://github.com/monitoring-plugins/monitoring-plugin-perl';
+name        'Monitoring-Plugin';
+all_from    'lib/Monitoring/Plugin/Functions.pm';
+author      'Monitoring Plugin Team <devel at monitoring-plugins.org>';
+license     'perl';
+repository  'https://github.com/monitoring-plugins/monitoring-plugin-perl';
 
 requires 'Params::Validate'   => 0;
 requires 'Class::Accessor'    => 0;
@@ -13,11 +13,9 @@ requires 'Config::Tiny'       => 0;
 requires 'File::Spec'         => 0;
 requires 'File::Basename'     => 0;
 requires 'IO::File'           => 0;
-requires 'Math::Calc::Units'  => 0;           # used in M::P::Performance
+requires 'Math::Calc::Units'  => 0;     # used in M::P::Performance
 
 
 build_requires 'Test::More'   => 0.62;
 
-auto_install;
-
 WriteAll;
diff --git a/README b/README
index b0550d6..476d39f 100644
--- a/README
+++ b/README
@@ -6,7 +6,7 @@ Icinga, Shinken and other compatible products. It is meant to
 simplify a lot of the common functions required to do checking of a
 particular service.
 This module is maintained by the Monitoring-Plugins team
-(https:://monitoring-plugins.org)
+(https://monitoring-plugins.org)
 
 INSTALLATION
 
@@ -28,7 +28,8 @@ working example of a plugin script.
 
 COPYRIGHT AND LICENCE
 
-Copyright (C) 2006-2014 by Monitoring Plugin Team
+Copyright (C) 2014      by Monitoring Plugin Team
+Copyright (C) 2006-2014 by Nagios Plugin Development Team
 
 This library is free software; you can redistribute it and/or modify
 it under the same terms as Perl itself, either Perl version 5.8.4 or,
diff --git a/lib/Monitoring/Plugin.pm b/lib/Monitoring/Plugin.pm
index f9eb49e..a5b51b1 100644
--- a/lib/Monitoring/Plugin.pm
+++ b/lib/Monitoring/Plugin.pm
@@ -1,9 +1,9 @@
-
 package Monitoring::Plugin;
 
 use Monitoring::Plugin::Functions qw(:codes %ERRORS %STATUS_TEXT @STATUS_CODES);
 use Params::Validate qw(:all);
 
+use 5.006;
 use strict;
 use warnings;
 
@@ -703,7 +703,8 @@ Originally by Ton Voon, E<lt>ton.voon at altinity.comE<gt>.
 
 =head1 COPYRIGHT AND LICENSE
 
-Copyright (C) 2006-2014 by Monitoring Plugin Team
+Copyright (C) 2014      by Monitoring Plugin Team
+Copyright (C) 2006-2014 by Nagios Plugin Development Team
 
 This library is free software; you can redistribute it and/or modify it
 under the same terms as Perl itself, either Perl version 5.8.4 or, at your
diff --git a/lib/Monitoring/Plugin/Config.pm b/lib/Monitoring/Plugin/Config.pm
index 5e941d4..fe2b654 100644
--- a/lib/Monitoring/Plugin/Config.pm
+++ b/lib/Monitoring/Plugin/Config.pm
@@ -1,6 +1,9 @@
 package Monitoring::Plugin::Config;
 
+use 5.006;
 use strict;
+use warnings;
+
 use Carp;
 use File::Spec;
 use base qw(Config::Tiny);
@@ -93,10 +96,12 @@ sub read_string
 sub write { croak "Write access not permitted" }
 
 # Return last file used by read();
-sub np_getfile { return $CURRENT_FILE; }
+sub mp_getfile { return $CURRENT_FILE; }
 
 1;
 
+__END__
+
 =head1 NAME
 
 Monitoring::Plugin::Config - read nagios plugin .ini style config files
@@ -169,7 +174,8 @@ https://monitoring-plugins.org
 
 =head1 COPYRIGHT AND LICENSE
 
-Copyright (C) 2006-2014 Monitoring Plugin Development Team
+Copyright (C) 2014      by Monitoring Plugin Team
+Copyright (C) 2006-2014 by Nagios Plugin Development Team
 
 This library is free software; you can redistribute it and/or modify
 it under the same terms as Perl itself.
diff --git a/lib/Monitoring/Plugin/ExitResult.pm b/lib/Monitoring/Plugin/ExitResult.pm
index aa9f5da..ab79a19 100644
--- a/lib/Monitoring/Plugin/ExitResult.pm
+++ b/lib/Monitoring/Plugin/ExitResult.pm
@@ -1,8 +1,10 @@
-# Tiny helper class to return both output and return_code when testing
-
 package Monitoring::Plugin::ExitResult;
 
+# Tiny helper class to return both output and return_code when testing
+
+use 5.006;
 use strict;
+use warnings;
 
 # Stringify to message
 use overload '""' => sub { shift->{message} };
@@ -63,7 +65,8 @@ Originally:
 
 =head1 COPYRIGHT AND LICENSE
 
-Copyright (C) 2006-2014 Monitoring Plugin Development Team
+Copyright (C) 2014      by Monitoring Plugin Team
+Copyright (C) 2006-2014 by Nagios Plugin Development Team
 
 This library is free software; you can redistribute it and/or modify
 it under the same terms as Perl itself.
diff --git a/lib/Monitoring/Plugin/Functions.pm b/lib/Monitoring/Plugin/Functions.pm
index d2856e8..d362f9c 100644
--- a/lib/Monitoring/Plugin/Functions.pm
+++ b/lib/Monitoring/Plugin/Functions.pm
@@ -1,12 +1,12 @@
+package Monitoring::Plugin::Functions;
+
 # Functional interface to basic Monitoring::Plugin constants, exports,
 # and functions
 
-package Monitoring::Plugin::Functions;
-
 use 5.006;
-
 use strict;
 use warnings;
+
 use File::Basename;
 use Params::Validate qw(:types validate);
 use Math::Calc::Units;
@@ -437,7 +437,8 @@ https://monitoring-plugins.org
 
 =head1 COPYRIGHT AND LICENSE
 
-Copyright (C) 2006-2014 Monitoring Plugin Development Team
+Copyright (C) 2014      by Monitoring Plugin Team
+Copyright (C) 2006-2014 by Nagios Plugin Development Team
 
 This library is free software; you can redistribute it and/or modify
 it under the same terms as Perl itself.
diff --git a/lib/Monitoring/Plugin/Getopt.pm b/lib/Monitoring/Plugin/Getopt.pm
index ce1c0f9..ebdd559 100644
--- a/lib/Monitoring/Plugin/Getopt.pm
+++ b/lib/Monitoring/Plugin/Getopt.pm
@@ -1,11 +1,14 @@
+package Monitoring::Plugin::Getopt;
+
 #
 # Monitoring::Plugin::Getopt - OO perl module providing standardised argument
 #   processing for nagios plugins
 #
 
-package Monitoring::Plugin::Getopt;
-
+use 5.006;
 use strict;
+use warnings;
+
 use File::Basename;
 use Getopt::Long qw(:config no_ignore_case bundling);
 use Carp;
@@ -249,7 +252,7 @@ sub _load_config_section
   # TODO: is this check sane? Does --extra-opts=foo require a [foo] section?
   ## Nevertheless, if we die as UNKNOWN here we should do the same on default
   ## file *added eval/_die above*.
-  $file ||= $Config->np_getfile();
+  $file ||= $Config->mp_getfile();
   $self->_die("Invalid section '$section' in config file '$file'")
     unless exists $Config->{$section};
 
@@ -861,7 +864,8 @@ Originally:
 
 =head1 COPYRIGHT AND LICENSE
 
-Copyright (C) 2006-2014 Monitoring Plugin Development Team
+Copyright (C) 2014      by Monitoring Plugin Team
+Copyright (C) 2006-2014 by Nagios Plugin Development Team
 
 This library is free software; you can redistribute it and/or modify
 it under the same terms as Perl itself.
diff --git a/lib/Monitoring/Plugin/Performance.pm b/lib/Monitoring/Plugin/Performance.pm
index 90fc9f4..f1e7a16 100644
--- a/lib/Monitoring/Plugin/Performance.pm
+++ b/lib/Monitoring/Plugin/Performance.pm
@@ -1,7 +1,6 @@
 package Monitoring::Plugin::Performance;
 
 use 5.006;
-
 use strict;
 use warnings;
 
@@ -286,7 +285,8 @@ https://monitoring-plugins.org
 
 =head1 COPYRIGHT AND LICENSE
 
-Copyright (C) 2006-2014 Monitoring Plugin Development Team
+Copyright (C) 2014      by Monitoring Plugin Team
+Copyright (C) 2006-2014 by Nagios Plugin Development Team
 
 This library is free software; you can redistribute it and/or modify
 it under the same terms as Perl itself.
diff --git a/lib/Monitoring/Plugin/Range.pm b/lib/Monitoring/Plugin/Range.pm
index af19577..4cacfd4 100644
--- a/lib/Monitoring/Plugin/Range.pm
+++ b/lib/Monitoring/Plugin/Range.pm
@@ -1,7 +1,6 @@
 package Monitoring::Plugin::Range;
 
 use 5.006;
-
 use strict;
 use warnings;
 
@@ -161,7 +160,8 @@ https://monitoring-plugins.org
 
 =head1 COPYRIGHT AND LICENSE
 
-Copyright (C) 2006-2014 Monitoring Plugin Development Team
+Copyright (C) 2014      by Monitoring Plugin Team
+Copyright (C) 2006-2014 by Nagios Plugin Development Team
 
 This library is free software; you can redistribute it and/or modify
 it under the same terms as Perl itself.
diff --git a/lib/Monitoring/Plugin/Threshold.pm b/lib/Monitoring/Plugin/Threshold.pm
index e71e21b..06dbf0c 100644
--- a/lib/Monitoring/Plugin/Threshold.pm
+++ b/lib/Monitoring/Plugin/Threshold.pm
@@ -1,7 +1,6 @@
 package Monitoring::Plugin::Threshold;
 
 use 5.006;
-
 use strict;
 use warnings;
 
@@ -126,7 +125,8 @@ https://monitoring-plugins.org
 
 =head1 COPYRIGHT AND LICENSE
 
-Copyright (C) 2006-2014 Monitoring Plugin Development Team
+Copyright (C) 2014      by Monitoring Plugin Team
+Copyright (C) 2006-2014 by Nagios Plugin Development Team
 
 This library is free software; you can redistribute it and/or modify
 it under the same terms as Perl itself.
diff --git a/notes b/notes
index d1bddbf..fce006c 100644
--- a/notes
+++ b/notes
@@ -1,8 +1,8 @@
 RELEASING
 
-Change version number in lib/Nagios/Plugin.pm and lib/Nagios/Plugin/Functions.pm
+Change version number in lib/Monitoring/Plugin.pm and lib/Monitoring/Plugin/Functions.pm
 Add date to Changes file
-svn commit
+git commit
 
 perl Makefile.PL
 make
@@ -11,5 +11,6 @@ make dist
 
 Upload file to CPAN
 
-Send announcement to nagiosplug-help, nagios-announce
-Add news item to http://nagiosplugins.org
+Send announcement to announce at monitoring-plugins.org, help at monitoring-plugins.org and
+devel at monitoring-plugins.org
+Add news item to https://monitoring-plugins.org
diff --git a/t/check_stuff.pl b/t/check_stuff.pl
index 4fc125c..dca4e58 100755
--- a/t/check_stuff.pl
+++ b/t/check_stuff.pl
@@ -2,7 +2,7 @@
 
 ###  check_stuff.pl
 
-# an example Monitoring plugin using the Monitoring::Plugin modules.
+# an example plugin using the Monitoring::Plugin module.
 
 # Originally by Nathan Vonnahme, n8v at users dot sourceforge
 # dot net, July 19 2006
@@ -41,7 +41,7 @@ my $p = Monitoring::Plugin->new(
     version => $VERSION,
     blurb => 'This plugin is an example of a monitoring plugin written in Perl using the Monitoring::Plugin modules.  It will generate a random integer between 1 and 20 (though you can specify the number with the -n option for testing), and will output OK, WARNING or CRITICAL if the resulting number is outside the specified thresholds.',
 
-	extra => "
+    extra => "
 
 THRESHOLDs for -w and -c are specified 'min:max' or 'min:' or ':max'
 (or 'max'). If specified '\@min:max', a warning status will be generated
@@ -69,28 +69,28 @@ See more threshold examples at https://www.monitoring-plugins.org/doc/guidelines
 # usage, help, version, timeout and verbose are defined by default.
 
 $p->add_arg(
-	spec => 'warning|w=s',
+    spec => 'warning|w=s',
 
-	help =>
+    help =>
 qq{-w, --warning=INTEGER:INTEGER
    Minimum and maximum number of allowable result, outside of which a
    warning will be generated.  If omitted, no warning is generated.},
 
-#	required => 1,
-#	default => 10,
+#   required => 1,
+#   default => 10,
 );
 
 $p->add_arg(
-	spec => 'critical|c=s',
-	help =>
+    spec => 'critical|c=s',
+    help =>
 qq{-c, --critical=INTEGER:INTEGER
    Minimum and maximum number of the generated result, outside of
    which a critical will be generated. },
 );
 
 $p->add_arg(
-	spec => 'result|r=f',
-	help =>
+    spec => 'result|r=f',
+    help =>
 qq{-r, --result=INTEGER
    Specify the result on the command line rather than generating a
    random number.  For testing.},
@@ -106,7 +106,7 @@ if ( (defined $p->opts->result) && ($p->opts->result < 0 || $p->opts->result > 2
 }
 
 unless ( defined $p->opts->warning || defined $p->opts->critical ) {
-	$p->plugin_die( " you didn't supply a threshold argument " );
+    $p->plugin_die( " you didn't supply a threshold argument " );
 }
 
 
@@ -132,6 +132,6 @@ else {
 # check the result against the defined warning and critical thresholds,
 # output the result and exit
 $p->plugin_exit(
-	 return_code => $p->check_threshold($result),
-	 message => " sample result was $result"
+    return_code => $p->check_threshold($result),
+    message => " sample result was $result"
 );




More information about the Commits mailing list