Repository navigation
Fix manpage command synopsis - #2113
Conversation
|
Navigate logical layers of code changes, visualize relationships, and explore their blast radius. Note Reviews pausedIt looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the Use the following commands to manage reviews:
Use the checkboxes below for quick actions:
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Repository UI Review profile: ASSERTIVE Plan: Advanced Run ID: 📒 Files selected for processing (1)
Included review availability: Your plan provides up to 8 included reviews per hour; 6 remain after this review. 📝 WalkthroughWalkthroughThe SYNOPSIS section now lists the updated option sets for Suggested reviewers: Priority: ⬇️ Low Change: Other Merge Risk: ⚪ Minimal · up to This documentation-only update clarifies htop and pcp-htop command-line forms and aligns HOSTSPEC and timezone options with supported behavior; no merge-blocking risk remains. Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Synopsis lines align Comment |
There was a problem hiding this comment.
Actionable comments posted: 1
ℹ️ Review info
⚙️ Run configuration
Configuration used: Repository UI
Review profile: ASSERTIVE
Plan: Advanced
Run ID: ac0d8c47-0314-47b0-a467-876881f42939
📒 Files selected for processing (1)
htop.1.in
Included review availability: Your plan provides up to 8 included reviews per hour; 7 remain after this review.
|
Optimistically pushing more ambitious update of the manpage, but feel free to be more specific about which of these changes you like and I can reduce the scope of changes. For ease of review I'm adding a diff of the rendered manpage between what would be rendered from master vs from this PR: ```diff
--- main
+++ PR
@@ -4,8 +4,8 @@
htop, pcp-htop - interactive process viewer
SYNOPSIS
- htop [-dCFhpustvH]
- pcp-htop [-dCFhpustvH] [--host/-h host]
+ htop [-CdFHhMnpstUuV]
+ pcp-htop [-CdFHhMnpstUuV] [--host=HOSTSPEC] [--hostzone|--timezone=TZ]
DESCRIPTION
htop is a cross-platform ncurses-based process viewer.
@@ -50,11 +50,11 @@
-h --help
Display a help message and exit
- -p --pid=PID,PID...
+ -p --pid=PID[,PID...]
Show only the given PIDs
- -s --sort-key COLUMN
- Sort by this column (use --sort-key help for a column list).
+ -s --sort-key=COLUMN
+ Sort by this column (use --sort-key=help for a column list).
This will force a list view unless you specify -t at the same
time. Sorting in tree mode applies to the direct children of
each process.
@@ -71,7 +71,7 @@
--no-meters
Hide graph meters
- --keep-visible[=N]
+ --keep-visible[=N]
Keep the first N columns visible when scrolling sideways in the
process list. The argument is optional; if omitted, N is taken
to be 1, and 0 disables the feature (the default). If N is larger
@@ -94,8 +94,10 @@
to move the whole tree down, creating empty space above the root
when necessary.
- -H --highlight-changes=DELAY
- Highlight new and old processes
+ -H --highlight-changes[=DELAY]
+ Highlight new and old processes. If DELAY is omitted, the high‐
+ light time configured in the setup screen is used (5 seconds by
+ default).
--drop-capabilities[=off|basic|strict]
Linux only; this option needs to have been enabled at compile-
@@ -105,6 +107,22 @@
accounting information will not work due to fewer capabilities
being held.
+ --host=HOSTSPEC
+ pcp-htop only.
+ Read metrics from the PMCD daemon on HOSTSPEC rather than from
+ the local host; see PCPIntro(1) for the HOSTSPEC syntax.
+
+ --hostzone
+ pcp-htop only.
+ Set the reporting timezone to the local timezone of the host sup‐
+ plying the metrics, rather than that of the local host. Mutually
+ exclusive with --timezone.
+
+ --timezone=TZ
+ pcp-htop only.
+ Set the reporting timezone to TZ, using the syntax of the TZ en‐
+ vironment variable. Mutually exclusive with --hostzone.
+
INTERACTIVE COMMANDS
The following commands are supported while in htop:
|
|
I think except for the first hunk in your diff above, the changes are mostly for consistency or completeness. Hunk 1 is still discussed in the team, but there's a slight tendency against it (not final yet though). Updating the set of short options in the usage section is agreed upon though; mostly a matter of whether to use the long version though or not. |
|
I think the short options synopsis is better. Less noise to scroll by. |
|
Would also be nice to remove AI overshoots like "The value must be attached with an equals sign." |
|
Ok, removed the AI overshoots and made the synopsis only list the short options only (except for the 3 extra options of pcp-htop, for which @BenBE asked to be included in the synopsis and which don't have short variants). Also updated the manpage diff above to reflect the changes. |
Add COMMAND-LINE OPTIONS entries for --host, --hostzone and --timezone, which pcp-htop accepts but the page never documented; they appeared only in --help output. Correct notation against the parser: -H takes an optional argument, --pid repeats are optional, --sort-key uses '='. Terminate four unterminated \fB escapes, drop a stray leading space before --keep-visible, and remove a no-op .br before a .SH. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
The synopsis listed a lowercase '-v' option that has never existed; version info is printed by '-V'. It also omitted '-n', '-U' and '-M', which are all accepted and already documented further down in the page. The option letters now match the getopt string in CommandLine.c. For pcp-htop, '--host' is a long-only option (its val is PLATFORM_LONGOPT_HOST, not a character), so the advertised '-h host' short form does not work; '-h' prints the help screen. Its argument is a HOSTSPEC, as the --help output states. Also list the other two PCP-only options, --hostzone and --timezone, which are mutually exclusive. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
92ae42a to
2bc145d
Compare
|
Sure, I split it into 2 commits. |
|
Thank you! |
Fix for #2112 + all the other issues found in manpage command synopsis.
The synopsis listed a lowercase '-v' option that has never existed; version info is printed by '-V'. It also omitted '-n', '-U' and '-M', which are all accepted and already documented further down in the page. The option letters now match the getopt string in CommandLine.c.
For pcp-htop, '--host' is a long-only option (its val is PLATFORM_LONGOPT_HOST, not a character), so the advertised '-h host' short form does not work -- '-h' prints the help screen. Its argument is a HOSTSPEC, as the --help output states.