util-linux.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Phil Auld <pauld@redhat.com>
To: Benno Schulenberg <bensberg@telfort.nl>
Cc: util-linux@vger.kernel.org, Thijs Raymakers <thijs@raymakers.nl>
Subject: Re: [PATCH 09/10] coresched: reduce excessive whitespace and verbosity in usage text
Date: Mon, 31 Mar 2025 07:00:00 -0400	[thread overview]
Message-ID: <20250331110000.GA120637@pauld.westford.csb> (raw)
In-Reply-To: <20250331094443.9619-9-bensberg@telfort.nl>

On Mon, Mar 31, 2025 at 11:44:42AM +0200 Benno Schulenberg wrote:
> Also, use semicolons instead of periods in option descriptions.
> 
> And consistently use an uppercased "PID" in feedback messages.
> 
> CC: Phil Auld <pauld@redhat.com>
> CC: Thijs Raymakers <thijs@raymakers.nl>
> Signed-off-by: Benno Schulenberg <bensberg@telfort.nl>

This looks like a reasonble cleanup I guess.


Acked-by; Phil Auld <pauld@redhat.com>


Cheers,
Phil

> ---
>  schedutils/coresched.c | 33 +++++++++++++--------------------
>  1 file changed, 13 insertions(+), 20 deletions(-)
> 
> diff --git a/schedutils/coresched.c b/schedutils/coresched.c
> index 9d8be3e12..7634d988c 100644
> --- a/schedutils/coresched.c
> +++ b/schedutils/coresched.c
> @@ -80,31 +80,24 @@ static void __attribute__((__noreturn__)) usage(void)
>  		program_invocation_short_name);
>  
>  	fputs(USAGE_SEPARATOR, stdout);
> -	fputsln(_("Manage core scheduling cookies for tasks."), stdout);
> +	fputsln(_("Manage core-scheduling cookies for tasks."), stdout);
>  
>  	fputs(USAGE_FUNCTIONS, stdout);
> -	fputsln(_(" get                      retrieve the core scheduling cookie of a PID"),
> -		stdout);
> -	fputsln(_(" new                      assign a new core scheduling cookie to an existing\n"
> -		  "                            PID or execute a program with a new cookie"),
> -		stdout);
> -	fputsln(_(" copy                     copy the core scheduling cookie from an existing PID\n"
> -		  "                            to another PID, or execute a program with that\n"
> -		  "                            copied cookie"),
> -		stdout);
> +	fputsln(_(" get      retrieve the core-scheduling cookie of a PID"), stdout);
> +	fputsln(_(" new      assign a new cookie to an existing PID,\n"
> +		  "            or execute a program with a new cookie"), stdout);
> +	fputsln(_(" copy     copy the cookie from an existing PID to another PID,\n"
> +		  "            or execute a program with that copied cookie"), stdout);
>  
>  	fputs(USAGE_OPTIONS, stdout);
>  	fprintf(stdout,
> -		_(" -s, --source <PID>       which PID to get the cookie from\n"
> -		  "                            If omitted, it is the PID of %s itself\n"),
> +		_(" -s, --source <PID>       which PID to get the cookie from; if this option\n"
> +		  "                            is omitted, the PID of %s itself is used\n"),
>  		program_invocation_short_name);
> -	fputsln(_(" -d, --dest <PID>         which PID to modify the cookie of\n"),
> -		stdout);
> -	fputsln(_(" -t, --dest-type <TYPE>   type of the destination PID, or the type of the PID\n"
> -		  "                            when a new core scheduling cookie is created.\n"
> -		  "                            Can be one of the following: pid, tgid or pgid.\n"
> -		  "                            The default is tgid."),
> -		stdout);
> +	fputsln(_(" -d, --dest <PID>         which PID to modify the cookie of"), stdout);
> +	fputsln(_(" -t, --dest-type <TYPE>   type of the new or destination PID; can be one\n"
> +		  "                            of: pid, tgid, pgid; default: tgid"), stdout);
> +
>  	fputs(USAGE_SEPARATOR, stdout);
>  	fputsln(_(" -v, --verbose      verbose"), stdout);
>  	fprintf(stdout, USAGE_HELP_OPTIONS(20));
> @@ -341,7 +334,7 @@ int main(int argc, char **argv)
>  	switch (args.cmd) {
>  	case SCHED_CORE_CMD_GET:
>  		cookie = core_sched_get_cookie(args.src);
> -		printf(_("cookie of pid %d is 0x%llx\n"), args.src, cookie);
> +		printf(_("cookie of PID %d is 0x%llx\n"), args.src, cookie);
>  		break;
>  	case SCHED_CORE_CMD_NEW:
>  		if (args.exec_argv_offset) {
> -- 
> 2.48.1
> 
> 

-- 


  reply	other threads:[~2025-03-31 11:00 UTC|newest]

Thread overview: 25+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-03-31  9:44 [PATCH 01/10] enosys: add the missing arguments of -s and -i to the usage text Benno Schulenberg
2025-03-31  9:44 ` [PATCH 02/10] uclampset: simplify the synopsis in the --help " Benno Schulenberg
2025-03-31  9:44 ` [PATCH 03/10] last: don't use a tab character " Benno Schulenberg
2025-03-31  9:44 ` [PATCH 04/10] irqtop: improve the description of --batch, and align it with others Benno Schulenberg
2025-03-31 14:57   ` Joe Jin
2025-03-31  9:44 ` [PATCH 05/10] irqtop: improve several more option descriptions, and align them all Benno Schulenberg
2025-03-31 15:02   ` Joe Jin
2025-03-31 15:47     ` Benno Schulenberg
2025-03-31 16:12       ` Joe Jin
2025-04-01  9:17         ` Benno Schulenberg
2025-04-02 10:58           ` Karel Zak
2025-03-31  9:44 ` [PATCH 06/10] findmnt: (man) remove duplicated option, and correct a description Benno Schulenberg
2025-03-31  9:44 ` [PATCH 07/10] hardlink: fix typoed semicolon to colon in error message Benno Schulenberg
2025-03-31  9:44 ` [PATCH 08/10] lsblk: (man) remove the incorrect spaces between the arguments of --ct Benno Schulenberg
2025-03-31  9:44 ` [PATCH 09/10] coresched: reduce excessive whitespace and verbosity in usage text Benno Schulenberg
2025-03-31 11:00   ` Phil Auld [this message]
2025-04-03  8:11   ` Karel Zak
2025-04-03  9:55     ` Benno Schulenberg
2025-04-03 12:08       ` Karel Zak
2025-03-31  9:44 ` [PATCH 10/10] coresched: rename option '--dest-type' to just '--type' Benno Schulenberg
2025-03-31 11:09   ` Phil Auld
2025-04-01  8:35     ` Karel Zak
2025-04-01  9:25       ` Benno Schulenberg
2025-04-01 12:20         ` Karel Zak
2025-04-02 11:11 ` [PATCH 01/10] enosys: add the missing arguments of -s and -i to the usage text Karel Zak

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20250331110000.GA120637@pauld.westford.csb \
    --to=pauld@redhat.com \
    --cc=bensberg@telfort.nl \
    --cc=thijs@raymakers.nl \
    --cc=util-linux@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).