On Mon, Aug 24, 2015 at 04:07:29PM +0200, Willem Jan Withagen
wrote:> On 24-8-2015 16:01, Baptiste Daroussin wrote:
> > On Mon, Aug 24, 2015 at 03:49:52PM +0200, Willem Jan Withagen wrote:
> >> Hi,
> >>
> >> In the previous version before Bapt upgraded pw(8) I was allowed
to do
> >> pw useradd -V /etc
> >>
> >> Even though the manual page instructed otherwise.
> >>
> >> The new version sticks to the manual page and generates:
> >> pw: illegal option -- V
> >>
> >> I'm going to change the scripts, but perhaps others will be
bitten too.
> >> Up to Bapt to decide what to do with this.
> >
> > The code has been changed to respect what the manual and the help
output was
> > showing: -V should be passed before the subcommand
>
> You just changed that now? Or my version is lagging behind?
> Text is much more clear than the 'illegal option' espacially now
there
> is also the -R stuff. So it made me wonder.
I changed that when bringing in the -R stuff so long ago. Illegal option is made
by getopt(3) directly but I can make it nicer and show a message that
explains.>
> > The reason for this is was to make the code more easily maintenable
and
> > understandable.
>
> You fixed the code, so it is your prerogative.
Well I also want the feedback from users, as if it is only me, given how things
are documented and the whole organisation of the pw(8) code (even before my
refactoring) it makes more sense as it is now. (this is the only behaviour that
changed on purpose, all others are considered as a bug and should be reported
and fixed).>
> > if really that is too painful I can allow again -V to be also passed
after the
> > subcommand but at the price of complicating the code.
>
> Nope, I've already changed the code I have.
> Was about 5 lines in a shell script.
>
> My comment was more as general notification, in case somebody else ran
> into the same. Nobody thus far ran into this, so it won't be major
anyways.
You are actually the second to report, the first was crochet which has be fixed
straight forward.
Best regards,
Bapt
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 181 bytes
Desc: not available
URL:
<http://lists.freebsd.org/pipermail/freebsd-stable/attachments/20150824/6653aa1a/attachment.bin>