lib/spring/commands.rb in spring-1.0.0 vs lib/spring/commands.rb in spring-1.1.0.beta1

- old
+ new

@@ -1,15 +1,16 @@ require "spring/watcher" +require "spring/command_wrapper" module Spring @commands = {} class << self attr_reader :commands end - def self.register_command(name, klass) - commands[name] = klass + def self.register_command(name, command = nil) + commands[name] = CommandWrapper.new(name, command) end def self.command?(name) commands.include? name end