Class: Textus::CLI::Group::Refresh

Inherits:
Textus::CLI::Group show all
Defined in:
lib/textus/cli/group/refresh.rb

Instance Attribute Summary

Attributes inherited from Verb

#positional

Instance Method Summary collapse

Methods inherited from Textus::CLI::Group

#call, inherited, needs_store?, subcommands

Methods inherited from Verb

#context_for, #emit, inherited, #initialize, needs_store?, option, options, #resolved_role

Constructor Details

This class inherits a constructor from Textus::CLI::Verb

Instance Method Details

#parse(argv) ⇒ Object



8
9
10
11
12
13
14
15
16
17
# File 'lib/textus/cli/group/refresh.rb', line 8

def parse(argv)
  if argv.first == "stale"
    argv.shift
    @sub_klass = Verb::RefreshStale
  else
    @sub_klass = Verb::Refresh
  end
  @sub = @sub_klass.new(stdin: @stdin, stdout: @stdout, stderr: @stderr, cwd: @cwd)
  @sub.parse(argv)
end