librarian-puppet 0.9.2.pre → 0.9.2

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.
@@ -42,9 +42,13 @@ module Librarian
42
42
  option "clean", :type => :boolean, :default => false
43
43
  option "strip-dot-git", :type => :boolean
44
44
  option "path", :type => :string
45
+ option "destructive", :type => :boolean, :default => false
45
46
  def install
46
47
  ensure!
47
48
  clean! if options["clean"]
49
+ unless options["destructive"].nil?
50
+ environment.config_db.local['destructive'] = options['destructive'].to_s
51
+ end
48
52
  if options.include?("strip-dot-git")
49
53
  strip_dot_git_val = options["strip-dot-git"] ? "1" : nil
50
54
  environment.config_db.local["install.strip-dot-git"] = strip_dot_git_val
@@ -1,5 +1,5 @@
1
1
  module Librarian
2
2
  module Puppet
3
- VERSION = "0.9.2.pre"
3
+ VERSION = "0.9.2"
4
4
  end
5
5
  end
@@ -40,7 +40,7 @@ module Librarian
40
40
  end
41
41
 
42
42
  def create_install_path
43
- install_path.rmtree if install_path.exist?
43
+ install_path.rmtree if install_path.exist? && destructive?
44
44
  install_path.mkpath
45
45
  end
46
46
 
@@ -54,6 +54,10 @@ module Librarian
54
54
  ManifestSet.sort(lock.manifests)
55
55
  end
56
56
 
57
+ def destructive?
58
+ environment.config_db.local['destructive'] == 'true'
59
+ end
60
+
57
61
  def specfile_name
58
62
  environment.specfile_name
59
63
  end
metadata CHANGED
@@ -1,13 +1,12 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: librarian-puppet
3
3
  version: !ruby/object:Gem::Version
4
- prerelease: true
4
+ prerelease: false
5
5
  segments:
6
6
  - 0
7
7
  - 9
8
8
  - 2
9
- - pre
10
- version: 0.9.2.pre
9
+ version: 0.9.2
11
10
  platform: ruby
12
11
  authors:
13
12
  - Tim Sharpe
@@ -199,13 +198,11 @@ required_ruby_version: !ruby/object:Gem::Requirement
199
198
  version: "0"
200
199
  required_rubygems_version: !ruby/object:Gem::Requirement
201
200
  requirements:
202
- - - ">"
201
+ - - ">="
203
202
  - !ruby/object:Gem::Version
204
203
  segments:
205
- - 1
206
- - 3
207
- - 1
208
- version: 1.3.1
204
+ - 0
205
+ version: "0"
209
206
  requirements: []
210
207
 
211
208
  rubyforge_project: