Page MenuHomeFreeBSD

sysctl has not -R option
ClosedPublic

Authored by alfix86_gmail.com on Jan 29 2019, 1:18 AM.

Details

Summary

This commit 244106 implemented -T and -W options but -R was added to the manual page (.Sh SYNOPSIS).

Test Plan
% sysctl -Ra
sysctl: illegal option -- R
usage: sysctl [-bdehiNnoqTtWx] [ -B <bufsize> ] [-f filename] name[=value] ...
       sysctl [-bdehNnoqTtWx] [ -B <bufsize> ] -a

Diff Detail

Repository
rS FreeBSD src repository
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

alfix86_gmail.com edited the summary of this revision. (Show Details)Jan 29 2019, 1:27 AM
0mp accepted this revision.Jan 29 2019, 10:18 AM
0mp added a subscriber: 0mp.

Nice find!

This revision is now accepted and ready to land.Jan 29 2019, 10:18 AM
crees added a subscriber: crees.Jan 29 2019, 3:29 PM

I think it should be NRTbdehnotqx, shouldn't it? I'm sure most of our manpages are like that.

0mp added a comment.EditedJan 30 2019, 8:50 AM

I think it should be NRTbdehnotqx, shouldn't it? I'm sure most of our manpages are like that.

It depends. ls(1) has -ABab while grep(1) has -AaBb. Personally, I prefer -AaBb. It's also what the example for the Fl macro suggests in mdoc(7):

.Op Fl 1AaCcdFfgHhikLlmnopqRrSsTtux
imp added a comment.Jan 30 2019, 4:20 PM
In D19012#406701, @0mp wrote:

I think it should be NRTbdehnotqx, shouldn't it? I'm sure most of our manpages are like that.

It depends. ls(1) has -ABab while grep(1) has -AaBb. Personally, I prefer -AaBb. It's also what the example for the Fl macro suggests in mdoc(7):

.Op Fl 1AaCcdFfgHhikLlmnopqRrSsTtux

The official style is AaBbCc not ABCabc. This is true for both the usage() message in the program and the usage in the man page. longopts are a total crap shoot, we have no standard for those, but single letter ops are well known: alphabetical order, with the upper case of the letter immediately before the lower case.

imp accepted this revision.Jan 30 2019, 4:21 PM

Thank you all for the comments,
Could you commit the diff? Thanks.

ygy accepted this revision.Feb 9 2019, 3:28 AM
ygy added a subscriber: ygy.

I will go ahead and commit it.

This revision was automatically updated to reflect the committed changes.