ENV.rb: Always return integers from make_jobs
When referencing `Hardware.processor_count`, `ENV.make_jobs` will return an integer. If referencing the environment variable `HOMEBREW_MAKE_JOBS`, it returned a string. Now, the function always returns an integer. Fixes Homebrew/homebrew#12033.
This commit is contained in:
parent
7b24382d14
commit
52834b8617
@ -432,7 +432,7 @@ Please take one of the following actions:
|
||||
def make_jobs
|
||||
# '-j' requires a positive integral argument
|
||||
if self['HOMEBREW_MAKE_JOBS'].to_i > 0
|
||||
self['HOMEBREW_MAKE_JOBS']
|
||||
self['HOMEBREW_MAKE_JOBS'].to_i
|
||||
else
|
||||
Hardware.processor_count
|
||||
end
|
||||
|
Loading…
x
Reference in New Issue
Block a user