diff options
| author | Adrian Ratiu <adrian.ratiu@collabora.com> | 2026-04-10 12:06:07 +0300 |
|---|---|---|
| committer | Junio C Hamano <gitster@pobox.com> | 2026-04-10 07:58:55 -0700 |
| commit | 495b7d54dc006556548e2fd3ca15c4f533917329 (patch) | |
| tree | da1d2646ff4d7d677de257a002a9f1fa288133ff /Documentation/CodingGuidelines | |
| parent | dcfb5af67e7d7156c4d1ede66de18088c990356c (diff) | |
| download | git-495b7d54dc006556548e2fd3ca15c4f533917329.tar.gz git-495b7d54dc006556548e2fd3ca15c4f533917329.zip | |
hook: allow hook.jobs=-1 to use all available CPU cores
Allow -1 as a value for hook.jobs, hook.<event>.jobs, and the -j
CLI flag to mean "use as many jobs as there are CPU cores", matching
the convention used by fetch.parallel and other Git subsystems.
The value is resolved to online_cpus() at parse time so the rest
of the code always works with a positive resolved count.
Other non-positive values (0, -2, etc) are rejected with a warning
(config) or die (CLI).
Suggested-by: Patrick Steinhardt <ps@pks.im>
Signed-off-by: Adrian Ratiu <adrian.ratiu@collabora.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'Documentation/CodingGuidelines')
0 files changed, 0 insertions, 0 deletions
