puppetsdb 0.0.3 → 0.0.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
data/lib/puppetsdb/cli.rb CHANGED
@@ -11,7 +11,7 @@ module PuppetSDB
11
11
  class << self
12
12
  COL_WIDTH = 40
13
13
  def ask_confirm(question)
14
- print "Are you sure you want to delete this node? (yes/[no]) "
14
+ print question
15
15
  answer = $stdin.gets.chomp
16
16
  accepted_confirms = ['y','yes']
17
17
  accepted_confirms.include?(answer.downcase)
@@ -87,6 +87,7 @@ module PuppetSDB
87
87
  puppet_enc.create_domain(domain_name)
88
88
  puts "Domain create successfully"
89
89
  when "deletedomain"
90
+ (puts deletedomain_cmd.call.help; exit 1) if ARGV.empty?
90
91
  domain_name = ARGV.shift
91
92
  unless options[:deletedomain_force]
92
93
  (puts "Cancelled..."; exit 0) unless ask_confirm("Are you sure you want to delete this domain? (yes/[no]) ")
@@ -1,3 +1,3 @@
1
1
  module PuppetSDB
2
- VERSION = "0.0.3"
2
+ VERSION = "0.0.4"
3
3
  end
metadata CHANGED
@@ -5,8 +5,8 @@ version: !ruby/object:Gem::Version
5
5
  segments:
6
6
  - 0
7
7
  - 0
8
- - 3
9
- version: 0.0.3
8
+ - 4
9
+ version: 0.0.4
10
10
  platform: ruby
11
11
  authors:
12
12
  - Brian Wong
@@ -14,7 +14,7 @@ autorequire:
14
14
  bindir: bin
15
15
  cert_chain: []
16
16
 
17
- date: 2012-11-06 00:00:00 -05:00
17
+ date: 2012-11-14 00:00:00 -05:00
18
18
  default_executable:
19
19
  dependencies:
20
20
  - !ruby/object:Gem::Dependency