Sha256: 6eb96fcee1273390a639565d1c473af190ce40b9531f71031bd995723967024c
Contents?: true
Size: 929 Bytes
Versions: 11
Compression:
Stored size: 929 Bytes
Contents
require 'forwardable' ## # Delegates the following methods: # # * Commander::Runner#add_command # * Commander::Runner#command # * Commander::Runner#commands # * Commander::Runner#program # * Commander::UI::ProgressBar#progress # class Object extend Forwardable include Commander::UI def_delegators Commander::UI::ProgressBar, :progress def_delegators :$command_runner, :add_command, :command, :program, :run!, :commands, :alias_command, :default_command, :global_option ## # Return the current binding. def get_binding binding end ## # Return the current command runner. def command_runner $command_runner end ## # Implement #ask_for_CLASS. include Module.new { def method_missing meth, *args, &block case meth.to_s when /^ask_for_([\w]+)/ ; $terminal.ask(args.first, eval($1.capitalize)) else super end end } end
Version data entries
11 entries across 11 versions & 1 rubygems