class Thor::Task::Dynamic
A dynamic task that handles method missing scenarios.
def initialize(name)
def initialize(name) super(name.to_s, "A dynamically-generated task", name.to_s) end
def run(instance, args=[])
def run(instance, args=[]) unless (instance.methods & [name.to_s, name.to_sym]).empty? raise Error, "could not find Thor class or task '#{name}'" end super end