vanagon 0.5.10 → 0.6.0

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 931b3b9e351487626cfc70250f5515612364a25d
4
- data.tar.gz: 41efa48f0508c3c030650b13991b7049153f1e56
3
+ metadata.gz: bd91238696bb5b6eded5bff5caaa11367bdb9a72
4
+ data.tar.gz: 2b06dab33a59ae1230dadfa8a7173a76f0ae6779
5
5
  SHA512:
6
- metadata.gz: 3b15f73c6cee6de81dd0b4e0b53d7d72bd1dc02dd4d9eb1e11f5b114dba410828089552fb68db206907514d853d0c5a88d8f43718d3c2ccd7f16e5dabaa9bee2
7
- data.tar.gz: 2bb2d911f8046369d1807937e017a56aaff4c0f8ee82ae6a13cfda544765a487158be6e4d9e1be2dad9b4ac762fb7d42f988c575ad01c90f58d9d796f6f5e3f0
6
+ metadata.gz: 69e00da92f02f69ff0033d860c8f4a597963eafe1a23d207d2db12467090c5ac2cb90e02a28687d21a82cdd6fcaec206b017ab8c24e04398d49bda85837c7991
7
+ data.tar.gz: ca04ff31f4265f13886605a00402b86955b13468dd42e17284c8020670a971ab1bd8673d2a8255fdef5aaa99799f8fc0c2faeca03dcccb02289c49c042c1c56f
@@ -1,6 +1,6 @@
1
1
  require 'vanagon/component/source/http'
2
2
  require 'vanagon/component/source/git'
3
- require 'vanagon/component/source/localsource'
3
+ require 'vanagon/component/source/local'
4
4
 
5
5
  class Vanagon
6
6
  class Component
@@ -65,7 +65,7 @@ class Vanagon
65
65
  when /^http/
66
66
  Vanagon::Component::Source::Http.new(self.rewrite(url, 'http'), options[:sum], workdir)
67
67
  when /^file/
68
- Vanagon::Component::Source::LocalSource.new(self.rewrite(url, 'file'), workdir)
68
+ Vanagon::Component::Source::Local.new(self.rewrite(url, 'file'), workdir)
69
69
  when /^git/
70
70
  Vanagon::Component::Source::Git.new(self.rewrite(url, 'git'), options[:ref], workdir)
71
71
  else
@@ -5,7 +5,7 @@ require 'uri'
5
5
  class Vanagon
6
6
  class Component
7
7
  class Source
8
- class LocalSource
8
+ class Local
9
9
  include Vanagon::Utilities
10
10
  attr_accessor :url, :file, :extension, :workdir, :cleanup
11
11
 
@@ -179,7 +179,7 @@ class Vanagon
179
179
  # Candle.exe preprocessor vars are required due to the above double run of heat.exe, both runs of heat use
180
180
  # preprocessor variables
181
181
  candle_preprocessor = "-dAppSourcePath=\"#{app_source_path}\" "
182
- candle_flags = "-dPlatform=#{@architecture} -arch #{@architecture} #{wix_extensions}"
182
+ candle_flags = "-arch #{@architecture} #{wix_extensions}"
183
183
  # Enable verbose mode for the moment (will be removed for production)
184
184
  # localisation flags to be added
185
185
  light_flags = "-v -cultures:en-us #{wix_extensions}"
@@ -230,6 +230,11 @@ class Vanagon
230
230
  def bill_of_materials(target)
231
231
  @project.bill_of_materials = Vanagon::Common::Pathname.new(target)
232
232
  end
233
+
234
+ # Counter for the number of times a project should retry a task
235
+ def retry_count(retry_count)
236
+ @project.retry_count = retry_count
237
+ end
233
238
  end
234
239
  end
235
240
  end
@@ -10,10 +10,19 @@ Package: <%= @name %>
10
10
  Architecture: <%= @noarch ? 'all' : 'any' %>
11
11
  Section: admin
12
12
  Priority: optional
13
+ <%- unless get_replaces.empty? -%>
13
14
  Replaces: <%= get_replaces.map { |replace| "#{replace.replacement} #{replace.version ? "(<< #{replace.version})" : ""}" }.join(", ") %>
15
+ Breaks: <%= get_replaces.map { |replace| "#{replace.replacement} #{replace.version ? "(<< #{replace.version})" : ""}" }.join(", ") %>
16
+ <%- end -%>
17
+ <%- unless get_conflicts.empty? -%>
14
18
  Conflicts: <%= get_conflicts.map { |conflict| "#{conflict.pkgname} #{conflict.version ? "(<< #{conflict.version})" : ""}" }.join(", ") %>
19
+ <%- end -%>
20
+ <%- unless get_requires.empty? -%>
15
21
  Depends: <%= get_requires.join(", ") %>
22
+ <%- end -%>
23
+ <%- unless get_provides.empty? -%>
16
24
  Provides: <%= get_provides.map { |prov| prov.provide }.join(", ") %>
25
+ <%- end -%>
17
26
  Description: <%= @description.lines.first.chomp %>
18
27
  <%= @description.lines[1..-1].join("\s") -%>
19
28
  .
@@ -8,7 +8,7 @@ describe "Vanagon::Component::Source::File" do
8
8
 
9
9
  describe "#fetch" do
10
10
  it "puts the source file in to the workdir" do
11
- file = Vanagon::Component::Source::LocalSource.new(plaintext_filename, workdir)
11
+ file = Vanagon::Component::Source::Local.new(plaintext_filename, workdir)
12
12
  file.fetch
13
13
  expect(File).to exist("#{workdir}/fake_file.txt")
14
14
  end
@@ -16,13 +16,13 @@ describe "Vanagon::Component::Source::File" do
16
16
 
17
17
  describe "#dirname" do
18
18
  it "returns the name of the tarball, minus extension for archives" do
19
- file = Vanagon::Component::Source::LocalSource.new(tar_filename, workdir)
19
+ file = Vanagon::Component::Source::Local.new(tar_filename, workdir)
20
20
  file.fetch
21
21
  expect(file.dirname).to eq("fake_dir")
22
22
  end
23
23
 
24
24
  it "returns the current directory for non-archive files" do
25
- file = Vanagon::Component::Source::LocalSource.new(plaintext_filename, workdir)
25
+ file = Vanagon::Component::Source::Local.new(plaintext_filename, workdir)
26
26
  file.fetch
27
27
  expect(file.dirname).to eq("./")
28
28
  end
@@ -30,9 +30,9 @@ describe "Vanagon::Component::Source::File" do
30
30
 
31
31
  describe "#get_extension" do
32
32
  it "returns the extension for valid extensions" do
33
- Vanagon::Component::Source::LocalSource::ARCHIVE_EXTENSIONS.each do |ext|
33
+ Vanagon::Component::Source::Local::ARCHIVE_EXTENSIONS.each do |ext|
34
34
  filename = "#{file_base}#{ext}"
35
- file = Vanagon::Component::Source::LocalSource.new(filename, workdir)
35
+ file = Vanagon::Component::Source::Local.new(filename, workdir)
36
36
  file.fetch
37
37
  expect(file.get_extension).to eq(ext)
38
38
  end
@@ -43,7 +43,7 @@ describe "Vanagon::Component::Source" do
43
43
  end
44
44
 
45
45
  it "returns an object of the correct type for file:// urls" do
46
- expect(Vanagon::Component::Source.source(file_url, {:sum => sum }, workdir).class).to equal(Vanagon::Component::Source::LocalSource)
46
+ expect(Vanagon::Component::Source.source(file_url, {:sum => sum }, workdir).class).to equal(Vanagon::Component::Source::Local)
47
47
  end
48
48
 
49
49
  it "applies any rewrite rules before defining an http Source" do
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: vanagon
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.10
4
+ version: 0.6.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Puppet Labs
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-04-08 00:00:00.000000000 Z
11
+ date: 2016-04-15 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rspec
@@ -80,7 +80,7 @@ files:
80
80
  - lib/vanagon/component/source.rb
81
81
  - lib/vanagon/component/source/git.rb
82
82
  - lib/vanagon/component/source/http.rb
83
- - lib/vanagon/component/source/localsource.rb
83
+ - lib/vanagon/component/source/local.rb
84
84
  - lib/vanagon/driver.rb
85
85
  - lib/vanagon/engine/base.rb
86
86
  - lib/vanagon/engine/docker.rb
@@ -203,7 +203,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
203
203
  version: '0'
204
204
  requirements: []
205
205
  rubyforge_project:
206
- rubygems_version: 2.5.1
206
+ rubygems_version: 2.2.5
207
207
  signing_key:
208
208
  specification_version: 3
209
209
  summary: All of your packages will fit into this van with this one simple trick.