pub_grub 0.4.2 → 0.4.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile.lock +1 -1
- data/lib/pub_grub/basic_package_source.rb +9 -2
- data/lib/pub_grub/version.rb +3 -0
- data/pub_grub.gemspec +3 -1
- metadata +2 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 3fb8a4eb75ab624c0460ae89a756058d8fc98747296d5b0422b63c0d915756e3
|
4
|
+
data.tar.gz: 99a4e76956dd0368acb67f87afe5f36357496fe1504bc4eb6f9670e10095cbf7
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: d9977b304c9ca7f483d95cbc1c3a385a6bb553d780600f07b7669368afdb3d07cd86e5021df4e5f63f1e31dd2fb607ff9d8f427024828b26a82af38248e4cd37
|
7
|
+
data.tar.gz: 1545a55656626c8b0575dc4b058f6eed4bf63c40f58f8cf25268bcdd1623e72e6ea7df9914727ab262783579ff154463146da0cddf2ceafd3a719390ebab9ea4
|
data/Gemfile.lock
CHANGED
@@ -95,7 +95,7 @@ module PubGrub
|
|
95
95
|
|
96
96
|
@cached_versions = Hash.new do |h,k|
|
97
97
|
if k == @root_package
|
98
|
-
h[k] = [
|
98
|
+
h[k] = [@root_version]
|
99
99
|
else
|
100
100
|
h[k] = all_versions_for(k)
|
101
101
|
end
|
@@ -118,7 +118,14 @@ module PubGrub
|
|
118
118
|
|
119
119
|
def versions_for(package, range=VersionRange.any)
|
120
120
|
versions = range.select_versions(@sorted_versions[package])
|
121
|
-
|
121
|
+
|
122
|
+
# Conditional avoids (among other things) calling
|
123
|
+
# sort_versions_by_preferred with the root package
|
124
|
+
if versions.size > 1
|
125
|
+
sort_versions_by_preferred(package, versions)
|
126
|
+
else
|
127
|
+
versions
|
128
|
+
end
|
122
129
|
end
|
123
130
|
|
124
131
|
def incompatibilities_for(package, version)
|
data/pub_grub.gemspec
CHANGED
@@ -2,9 +2,11 @@
|
|
2
2
|
lib = File.expand_path("../lib", __FILE__)
|
3
3
|
$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
|
4
4
|
|
5
|
+
require "pub_grub/version"
|
6
|
+
|
5
7
|
Gem::Specification.new do |spec|
|
6
8
|
spec.name = "pub_grub"
|
7
|
-
spec.version =
|
9
|
+
spec.version = PubGrub::VERSION
|
8
10
|
spec.authors = ["John Hawthorn"]
|
9
11
|
spec.email = ["john@hawthorn.email"]
|
10
12
|
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: pub_grub
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.4.
|
4
|
+
version: 0.4.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- John Hawthorn
|
@@ -109,6 +109,7 @@ files:
|
|
109
109
|
- lib/pub_grub/solve_failure.rb
|
110
110
|
- lib/pub_grub/static_package_source.rb
|
111
111
|
- lib/pub_grub/term.rb
|
112
|
+
- lib/pub_grub/version.rb
|
112
113
|
- lib/pub_grub/version_constraint.rb
|
113
114
|
- lib/pub_grub/version_range.rb
|
114
115
|
- lib/pub_grub/version_solver.rb
|