This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[Wed, 11 Jan 2012 17:02:10 +0000] INFO: Processing service[nagios-nrpe-server] action enable (nagios::client line 63) | |
[Wed, 11 Jan 2012 17:02:10 +0000] INFO: Processing nagios_nrpecheck[check_load] action add (nagios::client line 69) | |
[Wed, 11 Jan 2012 17:02:10 +0000] INFO: Adding check_load to /etc/nagios/nrpe.d/ | |
[Wed, 11 Jan 2012 17:02:10 +0000] INFO: Processing template[/etc/nagios/nrpe.d/check_load.cfg] action create (/var/chef/cache/cookbooks/nagios/providers/nrpecheck.rb line 23) | |
... | |
[Wed, 11 Jan 2012 17:02:10 +0000] INFO: template[/etc/nagios/nrpe.d/check_load.cfg] sending restart action to service[nagios-nrpe-server] (delayed) | |
[Wed, 11 Jan 2012 17:02:10 +0000] ERROR: Running exception handlers |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env ruby | |
require 'rubygems' | |
require 'nokogiri' | |
require 'net/http' | |
# check_aws_status.rb | |
# A nagios plugin for fetching RSS feeds from http://status.aws.amazon.com. | |
# Source: https://gist.github.com/1604786 | |
# Written by Aaron Suggs: https://github.com/ktheory |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env ruby | |
def slow_fib(n) | |
case n | |
when 0, 1 | |
1 | |
else | |
slow_fib(n-1) + slow_fib(n-2) | |
end | |
end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Gem::Specification.new do |s| | |
s.name = 'git_io' | |
s.version = '1.0.0' | |
s.platform = Gem::Platform::RUBY | |
s.author = 'Aaron Suggs' | |
s.email = '[email protected]' | |
s.summary = 'Shorten urls with git.io' | |
s.description = 'GitIo.shorten(url)' | |
s.homepage = 'https://gist.github.com/1762136' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Did you upgrade to rails 3 yet? | |
I made a rake task for that. | |
1.8.7, or 1.9.3? | |
Did you know there's a rake task for that? | |
Did you upgrade to rails 3.1 yet? | |
Did you see my pull request? | |
Did you upgrade to rails 3.2 yet? | |
I commented on your pull request. | |
You need to run bundle install first | |
rb-env or rvm? |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
module Enumerable | |
def pluck(key) | |
map {|obj| obj[key] } | |
end | |
end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'term/ansicolor' | |
# yeilds a stacktrace for each SQL query | |
# put this file in config/initializers | |
class QueryTrace < ActiveSupport::LogSubscriber | |
include Term::ANSIColor | |
attr_accessor :trace_queries | |
def sql(event) #:nodoc: | |
return unless QueryTrace.enabled? && logger.debug? && Rails.env.development? |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Gem::Specification.new do |s| | |
s.name = 'bang' | |
s.version = '0.1.0' | |
s.platform = Gem::Platform::RUBY | |
s.author = 'Jeff Kreeftmeijer' | |
s.email = '[email protected]' | |
s.summary = 'Bang!' | |
s.description = 'Bangs existing model methods' | |
s.files = ['bang.rb'] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
From 130b610b4e67bcad522a268f1d3f221e8d12ebb0 Mon Sep 17 00:00:00 2001 | |
From: Aaron Suggs <[email protected]> | |
Date: Fri, 6 Apr 2012 18:35:38 -0400 | |
Subject: [PATCH 1/2] Whitespace: tabs to spaces | |
--- | |
examples/init.sh | 90 +++++++++++++++++++++++++++--------------------------- | |
1 file changed, 45 insertions(+), 45 deletions(-) | |
diff --git a/examples/init.sh b/examples/init.sh |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
From 233f504a39aca6e8b2d9332ef324b4c5cc397eca Mon Sep 17 00:00:00 2001 | |
From: Aaron Suggs <[email protected]> | |
Date: Fri, 6 Apr 2012 18:35:38 -0400 | |
Subject: [PATCH 1/2] Whitespace: tabs to spaces | |
--- | |
examples/init.sh | 90 +++++++++++++++++++++++++++--------------------------- | |
1 files changed, 45 insertions(+), 45 deletions(-) | |
diff --git a/examples/init.sh b/examples/init.sh |