[nagiosplug] Added additional documentation to the check_range ...
"Nagios Plugin Development" <[email protected]> Tue, 9 Oct 2012 08:00:30 +0000
| Newsgroups | gmane.network.nagios.plugins.cvs |
|---|---|
| Message-ID | <[email protected]> |
Module: nagiosplug
Branch: master
Commit: 0656a0e284ed94f8c195592d62e9232e3c6d04b7
Author: Marc Huffnagle <[email protected]>
Committer: Holger Weiss <[email protected]>
Date: Fri Oct 5 11:07:01 2012 -0400
URL: http://nagiosplug.git.sf.net/git/gitweb.cgi?p=nagiosplug/nagiosplug;a=commit;h=0656a0e
Added additional documentation to the check_range function
---
plugins-scripts/utils.sh.in | 11 ++++++++++-
1 files changed, 10 insertions(+), 1 deletions(-)
diff --git a/plugins-scripts/utils.sh.in b/plugins-scripts/utils.sh.in
index 5fae6ad..4a07df8 100644
--- a/plugins-scripts/utils.sh.in
+++ b/plugins-scripts/utils.sh.in
@@ -23,7 +23,16 @@ support() {
#
# check_range takes a value and a range string, returning successfully if an
-# alert should be raised based on the range.
+# alert should be raised based on the range. Range values are inclusive.
+# Values may be integers or floats.
+#
+# Example usage:
+#
+# Generating an exit code of 1:
+# check_range 5 2:8
+#
+# Generating an exit code of 0:
+# check_range 1 2:8
#
check_range() {
local v range yes no err decimal start end cmp match
------------------------------------------------------------------------------
Don't let slow site performance ruin your business. Deploy New Relic APM
Deploy New Relic app performance management and know exactly
what is happening inside your Ruby, Python, PHP, Java, and .NET app
Try New Relic at no cost today and get our sweet Data Nerd shirt too!
http://p.sf.net/sfu/newrelic-dev2dev