Sha256: 46d92679de55ea5efa19a8a228a43a19f7dd8123350d5835a02f52c2f139889a

Contents?: true

Size: 555 Bytes

Versions: 6

Compression:

Stored size: 555 Bytes

Contents

module Commander
  module Delegates
    %w(
      add_command
      command
      program
      error_handler
      run!
      global_option
      alias_command
      default_command
      always_trace!
      never_trace!
      silent_trace!
    ).each do |meth|
      eval <<-END, binding, __FILE__, __LINE__
        def #{meth}(*args, &block)
          ::Commander::Runner.instance.#{meth}(*args, &block)
        end
      END
    end

    def defined_commands(*args, &block)
      ::Commander::Runner.instance.commands(*args, &block)
    end
  end
end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
commander-openflighthpc-1.2.0 lib/commander/delegates.rb
commander-openflighthpc-1.1.2 lib/commander/delegates.rb
commander-openflighthpc-1.1.1 lib/commander/delegates.rb
commander-openflighthpc-1.1.0 lib/commander/delegates.rb
commander-openflighthpc-1.0.0 lib/commander/delegates.rb
commander-openflighthpc-1.0.0.pre.alpha1 lib/commander/delegates.rb