maas-client 0.2.1 → 0.2.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 0793b93d5d84f0ce1d8128e9dfd4f1bd5fc9f20b
4
- data.tar.gz: 50d29a8ff09b9cf83c93be1f447628447ad57f2b
3
+ metadata.gz: 802cdd43b4c3d759f23267d0a6fa5d5ed916774e
4
+ data.tar.gz: a239e5a7de585d8f0e6dee87033c9a650458c194
5
5
  SHA512:
6
- metadata.gz: ee66e9de784f895834deba994d54e93179ceac02baaadad54b16f5a9a30bbd74f2480d8db5bf262a6db0fb5582b003d4005a336a83b83f4478df9841f0a0d32f
7
- data.tar.gz: f8813f010893d8f78cf78b52aebd5de6ffb5cd2f76e7593158a716dea71db5a140d5c6e2ac440ef95a4a7dbfc9147085c6c2c6091a9f7f24e00cdbe47f4d7192
6
+ metadata.gz: 2d3e20859819de4ff0e34bcd8866ba3effc2157ebdbbfefd4c2550870b48e15e5b939efe38b00b424f0d7bf5f9ef81385ea0777da4ba20e4814ec76573ffc6f1
7
+ data.tar.gz: 5e0bdf081607520cdd2af429f456f146d333fbc7fad45d16e2e79db798f89b09dbd28672ebe7228de6c5807a85c10cf5ed890e0f399b84df850fa1e2886aeef7
@@ -47,15 +47,17 @@ module Maas
47
47
 
48
48
  domains.each do |d|
49
49
  puts "Deleting #{d[:fqdn]}..."
50
- puts 'Do you really want to delete this? y or n'
51
- answer = gets.chomp
50
+ # use Thor basic functions such as 'ask' or 'say'
51
+ answer = ask(
52
+ 'Do you really want to delete this?',
53
+ :echo => true,
54
+ :limited_to => ['y', 'n']
55
+ )
52
56
  case answer
53
57
  when 'y'
54
58
  conn.request(:delete, ['dnsresources', d[:id].to_s])
55
59
  when 'n'
56
60
  puts "Canceling to delete #{d[:fqdn]}..."
57
- else
58
- puts 'Invalid input was entered.'
59
61
  end
60
62
  end
61
63
  else
@@ -2,6 +2,6 @@
2
2
 
3
3
  module Maas
4
4
  module Client
5
- VERSION = '0.2.1'
5
+ VERSION = '0.2.2'
6
6
  end
7
7
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: maas-client
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.1
4
+ version: 0.2.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Don Draper
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-09-11 00:00:00.000000000 Z
11
+ date: 2017-10-02 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rake
@@ -198,7 +198,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
198
198
  version: '0'
199
199
  requirements: []
200
200
  rubyforge_project:
201
- rubygems_version: 2.6.11
201
+ rubygems_version: 2.5.1
202
202
  signing_key:
203
203
  specification_version: 4
204
204
  summary: A client library for MAAS