-
-
Notifications
You must be signed in to change notification settings - Fork 2k
Handle recursive bundle package loop when multiple gemspecs present #4439
Handle recursive bundle package loop when multiple gemspecs present #4439
Conversation
gemspec = gemspec_cache_hash.values.first | ||
root_gem_name = gemspec.name unless gemspec.nil? | ||
gemspecs = gemspec_cache_hash.values | ||
root_gem_names = gemspecs.map(&:name) unless gemspecs.empty? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
the unless
seems unnecessary to me?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
oh, gemspec_cache_hash.values
will return an empty array if the hash is empty. Good call.
👍 other than the one comment |
Thanks for the catch. Removed the extraneous |
gemspec :name => 'mygem' | ||
gemspec :name => 'mygem_client' | ||
D | ||
sleep 10 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🔥🔥🔥🔥
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hm, not sure how that got in since I don't think it was there on the previous iterations of this PR. Major thanks for the catch though. Think it's worth adding a spec quality check for this?
A quality spec that checks for focused tests, binding.pry, debugger, and sleep sounds awesome to me. :) |
Awesome but separate :P |
@homu r+ |
📌 Commit 762ddfa has been approved by |
⚡ Test exempted - status |
…p-with-multiple-gemspecs, r=segiddins Handle recursive bundle package loop when multiple gemspecs present `root_gem_names` should contain the names of the gems that the gemspecs in the directory are correlated with. Gems are packaged unless they're called `bundler` or their names match with the gems specified in the gemspecs. - Handles multiple gemspecs in directory - Handles case where gemspec file name does not match with the gem name specified in the gemspec - Fixes #4430
…echanisms, r=segiddins Create quality check spec for leftover debugging/development mechanisms Example mechanisms that are screened for: - `sleep` - `binding.pry` - `debugger` - focused `rspec` tests via `fit` - Related to discussion at #4439 (comment)
…echanisms, r=segiddins Create quality check spec for leftover debugging/development mechanisms Example mechanisms that are screened for: - `sleep` - `binding.pry` - `debugger` - focused `rspec` tests via `fit` - Related to discussion at #4439 (comment)
root_gem_names
should contain the names of the gems that the gemspecs in the directory are correlated with. Gems are packaged unless they're calledbundler
or their names match with the gems specified in the gemspecs.