This file contains 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
diff --git a/lib/god.rb b/lib/god.rb | |
index 388179a..df39592 100644 | |
--- a/lib/god.rb | |
+++ b/lib/god.rb | |
@@ -534,6 +531,9 @@ module God | |
watches = self.pending_watches.dup | |
self.pending_watches.clear | |
self.pending_watch_states.clear | |
+ | |
+ # make sure we quit capturing when we're done |
This file contains 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
[alias] | |
up = !sh -c 'git pull && git --no-pager log --pretty=format:\"%Cred%ae %Creset- %C(yellow)%s %Creset(%ar)\" HEAD@{1}.. && echo' |
This file contains 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
namespace :test do | |
task :populate_testopts do | |
if ENV['TESTNAME'].present? | |
ENV['TESTOPTS'] = ENV['TESTOPTS'] ? "#{ENV['TESTOPTS']} " : '' | |
ENV['TESTOPTS'] += "--name=#{ENV['TESTNAME'].inspect}" | |
end | |
end | |
end | |
%w(test:units test:functionals test:integration).each do |task_name| |
This file contains 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
[2 : 0] eric@morizo:/Users/eric > cat > 'this is a test.sh' | |
#!/bin/sh | |
echo "we are so cool" | |
[3 : 0] eric@morizo:/Users/eric > chmod 755 'this is a test.sh' | |
[4 : 0] eric@morizo:/Users/eric > irb | |
>> system "this is a test.sh" | |
=> false | |
>> system ["this is a test.sh", "this is a test.sh"] | |
we are so cool |
This file contains 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
namespace :bundler do | |
task :symlink_vendor do | |
shared_gems = File.join(shared_path, 'vendor/bundler_gems/ruby/1.8') | |
release_gems = File.join(release_path, 'vendor/bundler_gems/ruby/1.8') | |
cmd = %w(gems specifications).collect do |sub_dir| | |
shared_sub_dir = File.join(shared_gems, sub_dir) | |
"mkdir -p #{shared_sub_dir} && mkdir -p #{release_gems} && ln -s #{shared_sub_dir} #{release_gems}/#{sub_dir}" | |
end.join(' && ') |
This file contains 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 | |
# | |
# linux-meminfo | |
# | |
# by Eric Lindvall <[email protected]> | |
# | |
# Gather more useful memory statistics for SNMP | |
# | |
# To see the example output, run: | |
# linux-meminfo.rb -g .1.3.6.1.4.1.2021.4.6.0 |
This file contains 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
<!-- You'll need this in your <head> somewhere --> | |
<script src="http://www.google.com/jsapi" type="text/javascript"></script> | |
<script type="text/javascript"> | |
google.load("gdata", "1.x", { packages : ["calendar"] }); | |
</script> |
This file contains 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 | |
# | |
# A simple tool to run php-based AGIs | |
# | |
# by Eric Lindvall <[email protected]> | |
# | |
# Usage: agi_handler.rb 4755 'php php_agi.php' | |
# |
This file contains 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
# List what ports are in use on OS X | |
sudo lsof -iTCP -sTCP:LISTEN |
This file contains 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
CRYPT [132 : 0] eric@alien:/home/eric > sudo gem install memcached | |
Building native extensions. This could take a while... | |
ERROR: Error installing memcached: | |
ERROR: Failed to build gem native extension. | |
/usr/bin/ruby extconf.rb | |
Building libmemcached. | |
tar xzf libmemcached-0.32.tar.gz 2>&1 | |
Patching libmemcached source. | |
patch -p1 -Z < libmemcached.patch |