single require to use like optparse
-
bahuvrihi
- State changed from new to resolved
- Assigned user set to bahuvrihi
Ok, so it works like this:
#!/usr/bin/env ruby require 'rubygems' require 'tap' # Goodnight::manifest your basic goodnight moon task # Says goodnight with a configurable message. Tap.tasc('goodnight', :message => 'goodnight') do |name| log message, name "#{message} #{name}" end.execute -
bahuvrihi
Maybe even better (so that the class definition can be used in other context without executing):
#!/usr/bin/env ruby require 'rubygems' require 'tap' # Goodnight::manifest your basic goodnight moon task # Says goodnight with a configurable message. Tap.tasc('goodnight', :message => 'goodnight') do |name| log message, name "#{message} #{name}" end Goodnight.execute if __FILE__ == $0
Please Sign in or create a free account to add a new ticket.
With your very own profile, you can contribute to projects, track your activity, watch tickets, receive and update tickets through your email and much more.