diff options
| author | mo <mo.khan@gmail.com> | 2018-03-18 17:28:50 -0600 |
|---|---|---|
| committer | mo <mo.khan@gmail.com> | 2018-03-18 17:28:50 -0600 |
| commit | cfc92965c19d31630ff41f75f43d835e1ac71880 (patch) | |
| tree | ded457214c1327ff6ecdb95bad7e68f2dfc24e4d /lib | |
| parent | 92f232c58f4d33dcc09006c43bf9ada20df720ec (diff) | |
add computers show command.
Diffstat (limited to 'lib')
| -rw-r--r-- | lib/ats/amp4e/computers.rb | 4 | ||||
| -rw-r--r-- | lib/ats/cli/amp4e/computers.rb | 5 |
2 files changed, 9 insertions, 0 deletions
diff --git a/lib/ats/amp4e/computers.rb b/lib/ats/amp4e/computers.rb index c1f49a1..595b04c 100644 --- a/lib/ats/amp4e/computers.rb +++ b/lib/ats/amp4e/computers.rb @@ -10,6 +10,10 @@ module ATS def list api.get("computers") end + + def show(id) + api.get("computers/#{id}") + end end end end diff --git a/lib/ats/cli/amp4e/computers.rb b/lib/ats/cli/amp4e/computers.rb index 741584f..0e854e0 100644 --- a/lib/ats/cli/amp4e/computers.rb +++ b/lib/ats/cli/amp4e/computers.rb @@ -8,6 +8,11 @@ module ATS def list print_json api.computers.list end + + desc 'show <UUID>', 'list' + def show(id) + print_json api.computers.show(id) + end end end end |
