albacore 2.3.5 → 2.3.6

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: 901e30922303f765f41f212911ce9eebd2bd37dc
4
- data.tar.gz: b89dbbfc09371b22ce7f1c79dbbba0a291b0cf84
3
+ metadata.gz: ed4fdb27d392bf16eca6d48d8a1d98e2380316c7
4
+ data.tar.gz: b576fd55285d187a6ebe73e7503c41ff65cac2c6
5
5
  SHA512:
6
- metadata.gz: 69e554a5c31ea4d26551fcb15e09397c54f122808ba1e10119d73c348075fbe5f434ec9917d1fdbff003f23f8ae11bfa4975dc2f1413de14cb54f93e8e9bc5ed
7
- data.tar.gz: 9e0be39b88850f9b6f41431c4c10aa1a831960e89b0cbf9598d8b383ad8724ffc04fbb49506ef8b89ac22c73bd566cd3b568ea371b64aa74ca08a9962081e2b0
6
+ metadata.gz: 52de081a6d2011cf23a3074e92965e0a665be7ca538bc947a978a19be7207dc83aa933d2d4e82da1c465541b7cb03ebbe2109b369e20e721841699448959d99f
7
+ data.tar.gz: 01eae97ffbda667f1fe71c7abcd486bcae34537063a998d9b522db72bd99e33eb07b28cf78ffe29b688c95d3f158ffb1a5510494f0ab985f21731245ca68f2fd
@@ -66,7 +66,7 @@ module Albacore
66
66
  trace { "didn't have a valid project_path, trying to find first project at #{descriptor_path.inspect}" }
67
67
  dir = File.dirname descriptor_path
68
68
  abs_dir = File.expand_path dir
69
- Dir.glob(File.join(abs_dir, '*proj')).first
69
+ Dir.glob(File.join(abs_dir, '*proj')).sort.first
70
70
  end
71
71
 
72
72
  # path of the *.appspec
@@ -221,7 +221,7 @@ module Albacore
221
221
  return @all_paket_deps if @all_paket_deps
222
222
  arr = File.open('paket.lock', 'r') do |io|
223
223
  io.readlines.map(&:chomp).map do |line|
224
- if (m = line.match /^\s+(?<id>[\w\.]+) \((?<ver>[\.\d\w]+)\)$/i)
224
+ if (m = line.match /^\s*(?<id>[\w\-\.]+) \((?<ver>[\.\d\w]+)\)$/i)
225
225
  ver = Albacore::SemVer.parse(m[:ver], '%M.%m.%p', false)
226
226
  OpenStruct.new(:id => m[:id],
227
227
  :version => m[:ver],
@@ -235,24 +235,21 @@ module Albacore
235
235
 
236
236
  def paket_packages
237
237
  return nil unless has_paket_deps? || has_paket_refs?
238
- info { "extracting paket dependencies from '#{to_s}' and 'paket.{dependencies,references}' in its folder" }
239
-
238
+ info { "extracting paket dependencies from '#{to_s}' and 'paket.{dependencies,references}' in its folder [project: paket_package]" }
240
239
  all_refs = []
241
240
 
242
241
  if has_paket_refs?
243
242
  File.open paket_refs, 'r' do |io|
244
- io.readlines.map(&:chomp).each do |line|
245
- debug { "found referenced package '#{line}' [project paket_packages]" }
246
- all_refs << all_paket_deps[line]
243
+ io.readlines.map(&:chomp).compact.each do |line|
244
+ paket_package_by_id! line, all_refs, 'referenced'
247
245
  end
248
246
  end
249
247
  end
250
248
 
251
249
  if has_paket_deps?
252
250
  File.open paket_deps, 'r' do |io|
253
- io.readlines.map(&:chomp).each do |line|
254
- debug { "found dependent package '#{line}' [project paket_packages]" }
255
- all_refs << all_paket_deps[line]
251
+ io.readlines.map(&:chomp).compact.each do |line|
252
+ paket_package_by_id! line, all_refs, 'dependent'
256
253
  end
257
254
  end
258
255
  end
@@ -260,6 +257,16 @@ module Albacore
260
257
  all_refs
261
258
  end
262
259
 
260
+ def paket_package_by_id! id, arr, ref_type
261
+ pkg = all_paket_deps[id]
262
+ if pkg
263
+ debug { "found #{ref_type} package '#{id}' [project: paket_packages]" }
264
+ arr << pkg
265
+ else
266
+ warn { "found #{ref_type} package '#{id}' not in paket.lock [project: paket_packages]" }
267
+ end
268
+ end
269
+
263
270
  def sanity_checks
264
271
  warn { "project '#{@proj_filename}' has no name" } unless name
265
272
  end
@@ -1,3 +1,3 @@
1
1
  module Albacore
2
- VERSION = "2.3.5"
2
+ VERSION = "2.3.6"
3
3
  end
@@ -119,7 +119,6 @@ project_path: path/not/existent/proj.fsproj}, nil
119
119
  title: my.project}, nil
120
120
  }.to raise_error(ArgumentError)
121
121
  end
122
-
123
122
  end
124
123
 
125
124
  describe ::Albacore::AppSpec, 'when fetching ALL data from Project.fsproj' do
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: albacore
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.3.5
4
+ version: 2.3.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - Henrik Feldt