bundler 1.2.0.rc → 1.2.0.rc.2
Sign up to get free protection for your applications and to get access to all the features.
Potentially problematic release.
This version of bundler might be problematic. Click here for more details.
- data/CHANGELOG.md +7 -1
- data/lib/bundler/definition.rb +6 -2
- data/lib/bundler/endpoint_specification.rb +1 -1
- data/lib/bundler/runtime.rb +2 -1
- data/lib/bundler/version.rb +1 -1
- data/spec/other/clean_spec.rb +25 -23
- metadata +5 -4
data/CHANGELOG.md
CHANGED
@@ -1,3 +1,9 @@
|
|
1
|
+
## 1.2.0.rc.2 (Aug 8, 2012)
|
2
|
+
|
3
|
+
Bugfixes:
|
4
|
+
|
5
|
+
- `clean` doesn't remove gems that are included in the lockfile
|
6
|
+
|
1
7
|
## 1.2.0.rc (Jul 17, 2012)
|
2
8
|
|
3
9
|
Features:
|
@@ -6,7 +12,7 @@ Features:
|
|
6
12
|
- loosen ruby directive for engines
|
7
13
|
- prune git/path directories inside vendor/cache (@josevalim, #1988)
|
8
14
|
- update vendored thor to 0.15.2 (@sferik)
|
9
|
-
- add .txt to
|
15
|
+
- add .txt to LICENSE (@postmodern, #2001)
|
10
16
|
- add `config disable_local_branch_check` (@josevalim, #1985)
|
11
17
|
- fall back on the full index when experiencing syck errors (#1419)
|
12
18
|
- handle syntax errors in Ruby gemspecs (#1974)
|
data/lib/bundler/definition.rb
CHANGED
@@ -108,9 +108,9 @@ module Bundler
|
|
108
108
|
specs
|
109
109
|
end
|
110
110
|
|
111
|
-
def specs
|
111
|
+
def specs(deps = requested_dependencies)
|
112
112
|
@specs ||= begin
|
113
|
-
specs = resolve.materialize(
|
113
|
+
specs = resolve.materialize(deps)
|
114
114
|
|
115
115
|
unless specs["bundler"].any?
|
116
116
|
local = Bundler.settings[:frozen] ? rubygems_index : index
|
@@ -130,6 +130,10 @@ module Bundler
|
|
130
130
|
@locked_specs - specs
|
131
131
|
end
|
132
132
|
|
133
|
+
def all_specs
|
134
|
+
specs(dependencies)
|
135
|
+
end
|
136
|
+
|
133
137
|
def new_platform?
|
134
138
|
@new_platform
|
135
139
|
end
|
data/lib/bundler/runtime.rb
CHANGED
@@ -120,12 +120,13 @@ module Bundler
|
|
120
120
|
gem_files = Dir["#{Gem.dir}/cache/*.gem"]
|
121
121
|
gemspec_files = Dir["#{Gem.dir}/specifications/*.gemspec"]
|
122
122
|
spec_gem_paths = []
|
123
|
+
# need to keep git sources around
|
123
124
|
spec_git_paths = []
|
124
125
|
spec_git_cache_dirs = []
|
125
126
|
spec_gem_executables = []
|
126
127
|
spec_cache_paths = []
|
127
128
|
spec_gemspec_paths = []
|
128
|
-
|
129
|
+
@definition.all_specs.each do |spec|
|
129
130
|
spec_gem_paths << spec.full_gem_path
|
130
131
|
# need to check here in case gems are nested like for the rails git repo
|
131
132
|
md = %r{(.+bundler/gems/.+-[a-f0-9]{7,12})}.match(spec.full_gem_path)
|
data/lib/bundler/version.rb
CHANGED
@@ -2,5 +2,5 @@ module Bundler
|
|
2
2
|
# We're doing this because we might write tests that deal
|
3
3
|
# with other versions of bundler and we are unsure how to
|
4
4
|
# handle this better.
|
5
|
-
VERSION = "1.2.0.rc" unless defined?(::Bundler::VERSION)
|
5
|
+
VERSION = "1.2.0.rc.2" unless defined?(::Bundler::VERSION)
|
6
6
|
end
|
data/spec/other/clean_spec.rb
CHANGED
@@ -100,29 +100,6 @@ describe "bundle clean" do
|
|
100
100
|
vendored_gems("bin/rackup").should exist
|
101
101
|
end
|
102
102
|
|
103
|
-
it "remove gems in bundle without groups" do
|
104
|
-
gemfile <<-G
|
105
|
-
source "file://#{gem_repo1}"
|
106
|
-
|
107
|
-
gem "foo"
|
108
|
-
|
109
|
-
group :test_group do
|
110
|
-
gem "rack", "1.0.0"
|
111
|
-
end
|
112
|
-
G
|
113
|
-
|
114
|
-
bundle "install --path vendor/bundle"
|
115
|
-
bundle "install --without test_group"
|
116
|
-
bundle :clean
|
117
|
-
|
118
|
-
out.should eq("Removing rack (1.0.0)")
|
119
|
-
|
120
|
-
should_have_gems 'foo-1.0'
|
121
|
-
should_not_have_gems 'rack-1.0.0'
|
122
|
-
|
123
|
-
vendored_gems("bin/rackup").should_not exist
|
124
|
-
end
|
125
|
-
|
126
103
|
it "does not remove cached git dir if it's being used" do
|
127
104
|
build_git "foo"
|
128
105
|
revision = revision_for(lib_path("foo-1.0"))
|
@@ -232,6 +209,31 @@ describe "bundle clean" do
|
|
232
209
|
vendored_gems("bundler/gems/rails-#{revision[0..11]}").should exist
|
233
210
|
end
|
234
211
|
|
212
|
+
it "does not remove git sources that are in without groups" do
|
213
|
+
build_git "foo", :path => lib_path("foo")
|
214
|
+
git_path = lib_path('foo')
|
215
|
+
revision = revision_for(git_path)
|
216
|
+
|
217
|
+
gemfile <<-G
|
218
|
+
source "file://#{gem_repo1}"
|
219
|
+
|
220
|
+
gem "rack", "1.0.0"
|
221
|
+
group :test do
|
222
|
+
git "#{git_path}", :ref => "#{revision}" do
|
223
|
+
gem "foo"
|
224
|
+
end
|
225
|
+
end
|
226
|
+
G
|
227
|
+
bundle "install --path vendor/bundle --without test"
|
228
|
+
|
229
|
+
bundle :clean
|
230
|
+
|
231
|
+
out.should eq("")
|
232
|
+
vendored_gems("bundler/gems/foo-#{revision[0..11]}").should exist
|
233
|
+
digest = Digest::SHA1.hexdigest(git_path.to_s)
|
234
|
+
vendored_gems("cache/bundler/git/foo-#{digest}").should exist
|
235
|
+
end
|
236
|
+
|
235
237
|
it "displays an error when used without --path" do
|
236
238
|
install_gemfile <<-G
|
237
239
|
source "file://#{gem_repo1}"
|
metadata
CHANGED
@@ -1,14 +1,15 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: bundler
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
hash:
|
4
|
+
hash: -430324494
|
5
5
|
prerelease: 6
|
6
6
|
segments:
|
7
7
|
- 1
|
8
8
|
- 2
|
9
9
|
- 0
|
10
10
|
- rc
|
11
|
-
|
11
|
+
- 2
|
12
|
+
version: 1.2.0.rc.2
|
12
13
|
platform: ruby
|
13
14
|
authors:
|
14
15
|
- "Andr\xC3\xA9 Arko"
|
@@ -19,7 +20,7 @@ autorequire:
|
|
19
20
|
bindir: bin
|
20
21
|
cert_chain: []
|
21
22
|
|
22
|
-
date: 2012-
|
23
|
+
date: 2012-08-09 00:00:00 Z
|
23
24
|
dependencies:
|
24
25
|
- !ruby/object:Gem::Dependency
|
25
26
|
name: ronn
|
@@ -287,7 +288,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
287
288
|
requirements: []
|
288
289
|
|
289
290
|
rubyforge_project: bundler
|
290
|
-
rubygems_version: 1.8.
|
291
|
+
rubygems_version: 1.8.24
|
291
292
|
signing_key:
|
292
293
|
specification_version: 3
|
293
294
|
summary: The best way to manage your application's dependencies
|