Isn't that all the things? Well, almost.
We've got:
- Things That Are Stuff (Data Objects)
- Things That Do Stuff (Service Objects, etc)
- Things That Both Do And Are Stuff (Object-Oriented Code)
I hereby claim:
To claim this, I am signing this object:
:+1:, we need this.
(this is called 'delsmanning' :-P)| module Converter | |
| def self.nested_hash(h, parts, val) | |
| if parts.length > 1 | |
| key = parts.first | |
| h[key] ||= {} | |
| h[key] = self.nested_hash(h[key], parts[1..-1], val) | |
| else | |
| h[parts.first] = val | |
| end | |
| h |
I hereby claim:
To claim this, I am signing this object:
| [user] | |
| name = Eric Mueller | |
| email = emueller@emcien.com | |
| [core] | |
| pager = cat | |
| excludesfile = /Users/nevinera/.gitignore_global | |
| [color] | |
| branch = auto |
| RED="\[\033[0;31m\]" | |
| YELLOW="\[\033[0;33m\]" | |
| GREEN="\[\033[0;32m\]" | |
| BLUE="\[\033[0;34m\]" | |
| LIGHT_RED="\[\033[1;31m\]" | |
| LIGHT_GREEN="\[\033[1;32m\]" | |
| WHITE="\[\033[1;37m\]" | |
| LIGHT_GRAY="\[\033[0;37m\]" | |
| COLOR_NONE="\[\e[0m\]" |
| RED="\[\033[0;31m\]" | |
| YELLOW="\[\033[0;33m\]" | |
| GREEN="\[\033[0;32m\]" | |
| BLUE="\[\033[0;34m\]" | |
| LIGHT_RED="\[\033[1;31m\]" | |
| LIGHT_GREEN="\[\033[1;32m\]" | |
| WHITE="\[\033[1;37m\]" | |
| LIGHT_GRAY="\[\033[0;37m\]" | |
| COLOR_NONE="\[\e[0m\]" |
| #!/usr/bin/ruby | |
| RAILS_ENV = 'production' | |
| `ln -sf database.yml.demo config/database.yml` | |
| require File.expand_path('../config/boot', __FILE__) | |
| require File.expand_path('../config/environment', __FILE__) | |
| require 'highline/import' |
| module Delayed | |
| class Worker | |
| def start | |
| say "Starting job worker" | |
| trap('TERM') { $exit = true; raise SignalException.new("TERM")} | |
| trap('INT') { say 'Exiting...'; $exit = true } | |
| loop do | |
| result = nil |