8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
|
# File 'lib/appril-cli/app.rb', line 8
def app args
opted_dir = args[2]
assert_directory_provided(opted_dir)
dir = expanded_path(opted_dir)
case instruction = args[1]
when 'i', 'install'
app_install(dir, {
working_dir_opted: working_dir_opted?(opted_dir),
namespace: (args),
crudle_app: args.find {|a| a == '-crudle'}
})
when 'u', 'update'
app_update(dir)
else
unknown_instruction_error!(instruction, 'install (or i)', 'update (or u)')
end
end
|