Skip to content
This repository has been archived by the owner on Jun 23, 2020. It is now read-only.

Commit

Permalink
Fix a few small regressions (rev 1)
Browse files Browse the repository at this point in the history
  - honor devel flag in gem dependency checker
  - flatten targets list in version checker
  • Loading branch information
movitto committed Apr 22, 2014
1 parent 97f9f48 commit fd36b69
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
6 changes: 4 additions & 2 deletions bin/gem_dependency_checker.rb
Original file line number Diff line number Diff line change
Expand Up @@ -211,13 +211,15 @@ def print_dep(tgt, dep, versions)

if conf[:gemname]
gem = Polisher::Gem.retrieve(conf[:gemname])
gem.versions(:recursive => true, :dev_deps => true) do |tgt, dep, versions|
gem.versions(:recursive => true,
:dev_deps => conf[:devel_deps]) do |tgt, dep, versions|
print_dep(tgt, dep, versions)
end

elsif conf[:gemspec]
gem = Polisher::Gem.from_gemspec(conf[:gemspec])
gem.versions(:recursive => true, :dev_deps => true) do |tgt, dep, versions|
gem.versions(:recursive => true,
:dev_deps => conf[:devel_deps]) do |tgt, dep, versions|
print_dep(tgt, dep, versions)
end

Expand Down
2 changes: 1 addition & 1 deletion lib/polisher/version_checker.rb
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ class VersionChecker
# Enable the specified target(s) in the list of target to check
def self.check(*target)
@check_list ||= []
target.each { |t| @check_list << t }
target.flatten.each { |t| @check_list << t }
end

def self.should_check?(target)
Expand Down

0 comments on commit fd36b69

Please sign in to comment.