Skip to content

Commit 000f019

Browse files
deivid-rodriguezhsbt
authored andcommitted
[rubygems/rubygems] Simplify passing "gemspec" option to path sources
ruby/rubygems@9c6b57c01d
1 parent c55cc01 commit 000f019

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

lib/bundler/dsl.rb

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ def gemspec(opts = nil)
7777

7878
@gemspecs << spec
7979

80-
path path, "glob" => glob, "name" => spec.name do
80+
path path, "glob" => glob, "name" => spec.name, "gemspec" => spec do
8181
add_dependency spec.name
8282
end
8383

@@ -141,8 +141,7 @@ def git_source(name, &block)
141141
def path(path, options = {}, &blk)
142142
source_options = normalize_hash(options).merge(
143143
"path" => Pathname.new(path),
144-
"root_path" => gemfile_root,
145-
"gemspec" => gemspecs.find {|g| g.name == options["name"] }
144+
"root_path" => gemfile_root
146145
)
147146

148147
source_options["global"] = true unless block_given?

0 commit comments

Comments
 (0)