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
class TeamBuilder | |
attr_reader :domain, :params | |
def initialize(domain, params = {}) | |
@domain = domain | |
@params = params | |
end | |
def build |
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
kev@torquebox:~/torquebox_examples/rails_example$ torquebox deploy | |
Errno::ENOENT: No such file or directory - /jboss/standalone/deployments/rails_example-knob.yml | |
initialize at org/jruby/RubyFile.java:333 | |
open at org/jruby/RubyIO.java:1179 | |
deploy_yaml at /home/kev/.rvm/gems/jruby-1.7.2@tb_rails_example/gems/torquebox-rake-support-2.1.2/lib/torquebox/deploy_utils.rb:244 | |
deploy at /home/kev/.rvm/gems/jruby-1.7.2@tb_rails_example/gems/torquebox-2.1.2/bin/torquebox:97 | |
__send__ at org/jruby/RubyBasicObject.java:1659 | |
run at /home/kev/.rvm/gems/jruby-1.7.2@tb_rails_example/gems/thor-0.17.0/lib/thor/task.rb:27 | |
invoke_task at /home/kev/.rvm/gems/jruby-1.7.2@tb_rails_example/gems/thor-0.17.0/lib/thor/invocation.rb:120 | |
dispatch at /home/kev/.rvm/gems/jruby-1.7.2@tb_rails_example/gems/thor-0.17.0/lib/thor.rb:344 |
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
# put this in spec/watchr | |
# use with Spork | |
# run with `watchr spec/watchr` | |
# images are from Tango icon theme | |
# http://commons.wikimedia.org/wiki/Tango_icons#Weather | |
# for added bonus: | |
# set keyboard shortcuts Ctrl-Alt-S to run "pkill -USR2 -f spork" | |
# ...and Ctrl-Alt-T to run "pkill -USR2 -f watchr" |
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
# app/models/user.rb | |
class User < ActiveRecord::Base | |
end | |
# lib/user_logger.rb | |
module UserLogger | |
def self.included(mod) | |
mod.send :after_create, :log_creation | |
end |