Only need a single, more readable, print_stderr
This commit is contained in:
parent
34b4cc796f
commit
66e50846e2
@ -330,12 +330,17 @@ module PyPI
|
||||
# Resolve the dependency tree of all input packages
|
||||
show_info = !print_only && !silent
|
||||
ohai "Retrieving PyPI dependencies for \"#{input_packages.join(" ")}\"..." if show_info
|
||||
print_stderr = !(verbose && show_info).nil?
|
||||
|
||||
print_stderr = if verbose && show_info
|
||||
true
|
||||
else
|
||||
false
|
||||
end
|
||||
|
||||
found_packages = pip_report(input_packages, python_name:, print_stderr:)
|
||||
# Resolve the dependency tree of excluded packages to prune the above
|
||||
exclude_packages.delete_if { |package| found_packages.exclude? package }
|
||||
ohai "Retrieving PyPI dependencies for excluded \"#{exclude_packages.join(" ")}\"..." if show_info
|
||||
print_stderr = !(verbose && show_info).nil?
|
||||
exclude_packages = pip_report(exclude_packages, python_name:, print_stderr:)
|
||||
if (main_package_name = main_package&.name)
|
||||
exclude_packages += [Package.new(main_package_name)]
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user