summaryrefslogtreecommitdiff
path: root/lib/custodian/util
AgeCommit message (Collapse)Author
2016-04-22Fixed up more rubocop warnings.Steve Kemp
Again these were whitespace-related.
2016-04-22Readded file.Steve Kemp
It was required after all.
2016-04-22Removed obsolete file.Steve Kemp
2016-04-22Deleted trailing whitespace.Steve Kemp
Made minor formatting cleanups
2016-04-21added a simple tftp utilityJames F. Carter
2015-12-02Added swordfish range - 5.28.56.0/21Steve Kemp
2015-04-16Mark unused variables as unused.Steve Kemp
We do that with the standard "_"-prefix.
2015-03-09Updated to test for more whitespace issues.Steve Kemp
2015-03-09Removed trailing whitespace from the codeSteve Kemp
2015-03-09Whitespace fixups.Steve Kemp
These were all identified and suggested by rubocop.
2015-03-09Removed spaces inside parenthesis.Steve Kemp
2015-03-09Prefer single-quotes when you don't need interpolation.Steve Kemp
So "foo" is less good than 'foo'.
2015-03-09Do not terminate expressions with ";".Steve Kemp
Ruby is not Perl, much as I sometimes wish it were.
2015-03-09Avoid redudent returns.Steve Kemp
The last expression of a method is the return value. So: def foo; false ; end Is the same as: def foo; return false; end
2015-03-09Don't use parenthesis aroudn conditions in an if.Steve Kemp
2015-03-09Do not use parentheses for method calls with no arguments.Steve Kemp
This is neater. Flagged by rubocop
2015-03-09Don't use "::" for method-calls.Steve Kemp
Instead prefer ".". Flagged by rubocop
2015-02-13Added 5.28.58.0/24 to the Bytemark ranges.Steve Kemp
2015-01-30Removed executable permissions, this is a library.Steve Kemp
2015-01-29Removed shebang.Steve Kemp
This refereed to ruby1.8 in a versioned way which was wrong.
2014-12-11Use getnameinfo rather than getaddrinfoPatrick J Cherry
2013-07-11 Updated the first IPv6 range.Steve Kemp
2013-07-11 Added 2001:41c9::/32 as a Bytemark range.Steve Kemp
2013-06-24Updated the code to be more module.Steve Kemp
Broke down the inside? function into a function for returning the hours in a period, and for sanitizing hour strings "14" vs. "2pm", etc. Updated test-cases to match.
2013-06-24The worst-case for testing a time-period, and one used in theSteve Kemp
parser test, is matching against a period that covers the full 24 hours. Correctly terminate this case, and add a new test-case to ensure that this is always correct.
2013-06-24Removed obsolete debug-code.Steve Kemp
2013-06-24Use the global timeout-period for DNS lookups.Steve Kemp
The rest of custodian will use the configuration file to read the timeout value (with a default of 30 seconds), but the DNS-lookups were hardwired to timeout after four seconds. This is now resolved; the DNS lookups will use the global timeout period too now.
2013-06-24 Added Custodian::Util::TimeSpanSteve Kemp
This class is used to determine whether an "hour" is within a given hour-span. e.g. To cope with: foo must run ping except between 04-06 otherwise 'alert'. This updates issue #4551.
2012-11-24 Removed test/driver-code.Steve Kemp
2012-11-23 Moved the code to detect whether an IP-address is inside/outside the ↵Steve Kemp
Bytemark range into its own class & added _simple_ test-cases.
2012-11-23 Ensure we have a sane argument to our constructor.Steve Kemp
2012-11-22 Whitespace updates.Steve Kemp
2012-11-22 Renamed.Steve Kemp