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 +4 -4
- data/lib/albacore/app_spec.rb +1 -1
- data/lib/albacore/project.rb +16 -9
- data/lib/albacore/version.rb +1 -1
- data/spec/app_spec_spec.rb +0 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: ed4fdb27d392bf16eca6d48d8a1d98e2380316c7
|
4
|
+
data.tar.gz: b576fd55285d187a6ebe73e7503c41ff65cac2c6
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 52de081a6d2011cf23a3074e92965e0a665be7ca538bc947a978a19be7207dc83aa933d2d4e82da1c465541b7cb03ebbe2109b369e20e721841699448959d99f
|
7
|
+
data.tar.gz: 01eae97ffbda667f1fe71c7abcd486bcae34537063a998d9b522db72bd99e33eb07b28cf78ffe29b688c95d3f158ffb1a5510494f0ab985f21731245ca68f2fd
|
data/lib/albacore/app_spec.rb
CHANGED
@@ -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
|
data/lib/albacore/project.rb
CHANGED
@@ -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
|
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
|
-
|
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
|
-
|
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
|
data/lib/albacore/version.rb
CHANGED
data/spec/app_spec_spec.rb
CHANGED