1
0
mirror of https://github.com/openSUSE/osc.git synced 2025-02-16 07:17:16 +01:00

Merge pull request #1562 from dmach/build-jobs

Change 'build' command to pass '--jobs' option to 'build' tool only if 'build_jobs' > 0
This commit is contained in:
Daniel Mach 2024-05-10 13:26:23 +02:00 committed by GitHub
commit b2f4ea2fcd
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 2 additions and 2 deletions

View File

@ -816,7 +816,7 @@ def main(apiurl, store, opts, argv):
buildargs.append('--threads=%s' % opts.threads) buildargs.append('--threads=%s' % opts.threads)
if opts.jobs: if opts.jobs:
buildargs.append('--jobs=%s' % opts.jobs) buildargs.append('--jobs=%s' % opts.jobs)
elif config['build-jobs'] > 1: elif config['build-jobs'] > 0:
buildargs.append('--jobs=%s' % config['build-jobs']) buildargs.append('--jobs=%s' % config['build-jobs'])
if opts.icecream or config['icecream'] != '0': if opts.icecream or config['icecream'] != '0':
if opts.icecream: if opts.icecream:

View File

@ -1014,7 +1014,7 @@ class Options(OscOptions):
The number of parallel processes during the build. The number of parallel processes during the build.
Defaults to the number of available CPU threads. Defaults to the number of available CPU threads.
Passed as ``--jobs`` to the build tool. If the value is greater than ``0`` then it is passed as ``--jobs`` to the build tool.
""" """
), ),
ini_key="build-jobs", ini_key="build-jobs",