From nobody Thu Oct 2 13:07:13 2025 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id E3BE031BCBC; Wed, 17 Sep 2025 12:15:55 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1758111356; cv=none; b=DfEvyGdfQwW17NgK94bDvAhhUvz/SWytEm0ABBYe2tfvI6ew0anCFfwD1IeEa5pt6ujlO3hkaYE2llK2mEEZvfNWCWJeTxUNCjHPjsK/tK9oxypfUXc+95vsoHotcYAkEuE9s6fRpswkpaW/y5oGrDEId6r7c6L4VEQYKY81GIw= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1758111356; c=relaxed/simple; bh=jlol1TuhVNcZDXlNqsLBvYWROc27W0iXgTQpgdIUTbU=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=AGuqbGtGe6PQBpFK2SwFW3+aGmDCBfbWUOHjRWBHfUZ50aJPzkEWqBYMZRdCsoivnk0yfLFV3vE5JozHzh7l06IEp6f3UmfdlqCjPVOOOXfVF21R0YsfDYQS2Kg7jNXxrZakQXciBZwVkkYmd5rcpPugUr5yaNTlQnSw+nFKZfI= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=eO1nP3vg; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="eO1nP3vg" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 9E87BC4CEFA; Wed, 17 Sep 2025 12:15:55 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1758111355; bh=jlol1TuhVNcZDXlNqsLBvYWROc27W0iXgTQpgdIUTbU=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=eO1nP3vgZcBN0PFJ1WsBVBVikAoR58lAtSZf05IqGO+LxsUA/yV8CxVE5f2VM38wF t88aW82Q7xc+55m++oeYNi7oy4FLYP7W/kaaH0b8ijREQSNgCKq2hTIA7ru5Me+4fc P3FQumb2iuem4VLcx1srENMrE4fyzQKbwGOUNoADtJaR5bjQs55PvRC0lonAOod2LY fAo16jXql7ndhmr9zSEmDW7PQXLbPrm+R8GXZ1VPnR69QQa9T/2bze283miY29uoUs 6DlH60ItBAN4vvGVb/dMez1OFmUt7IAbBPPgmsxb1TUJluQp8PurTR37QXndZ72wkP m7Hyp7nYrWmpA== Received: from mchehab by mail.kernel.org with local (Exim 4.98.2) (envelope-from ) id 1uyr4h-0000000CGdM-0Tq4; Wed, 17 Sep 2025 14:15:51 +0200 From: Mauro Carvalho Chehab To: Jonathan Corbet , Linux Doc Mailing List Cc: Mauro Carvalho Chehab , "Akira Yokosawa" , "Mauro Carvalho Chehab" , linux-kernel@vger.kernel.org Subject: [PATCH v7 03/24] scripts/jobserver-exec: add a help message Date: Wed, 17 Sep 2025 14:14:57 +0200 Message-ID: X-Mailer: git-send-email 2.51.0 In-Reply-To: References: Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Sender: Mauro Carvalho Chehab Content-Type: text/plain; charset="utf-8" Currently, calling it without an argument shows an ugly error message. Instead, print a message using pythondoc as description. Signed-off-by: Mauro Carvalho Chehab --- scripts/jobserver-exec | 22 +++++++++++++--------- 1 file changed, 13 insertions(+), 9 deletions(-) diff --git a/scripts/jobserver-exec b/scripts/jobserver-exec index 40a0f0058733..ae23afd344ec 100755 --- a/scripts/jobserver-exec +++ b/scripts/jobserver-exec @@ -1,6 +1,15 @@ #!/usr/bin/env python3 # SPDX-License-Identifier: GPL-2.0+ =20 +""" +Determines how many parallel tasks "make" is expecting, as it is +not exposed via any special variables, reserves them all, runs a subprocess +with PARALLELISM environment variable set, and releases the jobs back agai= n. + +See: + https://www.gnu.org/software/make/manual/html_node/POSIX-Jobserver.htm= l#POSIX-Jobserver +""" + import os import sys =20 @@ -12,17 +21,12 @@ sys.path.insert(0, os.path.join(SRC_DIR, LIB_DIR)) from jobserver import JobserverExec # pylint: disable=3DC= 0415 =20 =20 -""" -Determines how many parallel tasks "make" is expecting, as it is -not exposed via an special variables, reserves them all, runs a subprocess -with PARALLELISM environment variable set, and releases the jobs back agai= n. - -See: - https://www.gnu.org/software/make/manual/html_node/POSIX-Jobserver.htm= l#POSIX-Jobserver -""" - def main(): """Main program""" + if len(sys.argv) < 2: + name =3D os.path.basename(__file__) + sys.exit("usage: " + name +" command [args ...]\n" + __doc__) + with JobserverExec() as jobserver: jobserver.run(sys.argv[1:]) =20 --=20 2.51.0