Method: ListTool::App::RenameListCommand.parse

Defined in:
lib/list_tool/app/commands/rename_list_command.rb

.parse(argv) ⇒ Object



11
12
13
14
15
16
17
18
# File 'lib/list_tool/app/commands/rename_list_command.rb', line 11

def parse argv
  fail_if_not_an_array(argv)
  
  list, name = argv.shift(2)
  ensure_existence_of('new name' => name)
  
  { name: name, list: parse_list_number!(list) }
end