From owner-freebsd-stable@freebsd.org Mon Aug 24 14:16:49 2015 Return-Path: Delivered-To: freebsd-stable@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id DAA5D9C2BBD for ; Mon, 24 Aug 2015 14:16:49 +0000 (UTC) (envelope-from baptiste.daroussin@gmail.com) Received: from mailman.ysv.freebsd.org (mailman.ysv.freebsd.org [IPv6:2001:1900:2254:206a::50:5]) by mx1.freebsd.org (Postfix) with ESMTP id B641FB06 for ; Mon, 24 Aug 2015 14:16:49 +0000 (UTC) (envelope-from baptiste.daroussin@gmail.com) Received: by mailman.ysv.freebsd.org (Postfix) id B33849C2BBC; Mon, 24 Aug 2015 14:16:49 +0000 (UTC) Delivered-To: stable@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 98F1D9C2BBB for ; Mon, 24 Aug 2015 14:16:49 +0000 (UTC) (envelope-from baptiste.daroussin@gmail.com) Received: from mail-wi0-x234.google.com (mail-wi0-x234.google.com [IPv6:2a00:1450:400c:c05::234]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 2F971B05 for ; Mon, 24 Aug 2015 14:16:49 +0000 (UTC) (envelope-from baptiste.daroussin@gmail.com) Received: by wicja10 with SMTP id ja10so73739703wic.1 for ; Mon, 24 Aug 2015 07:16:47 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=sender:date:from:to:cc:subject:message-id:references:mime-version :content-type:content-disposition:in-reply-to:user-agent; bh=d6wnkRzuqxEI7mxADR+yo4iJ87qzdq4sCLPV2HFteQg=; b=tkUHAO8Su85G4R7Q70+77rOQLQNQoDcqx95y1yR8sZXhJxoGh6iwhAhsOPPn3BygdH sWWC+gwLyyVl20H7ARMEhNsO+VX4s3mjmyD1usBYbSZdp8viviLmXqDqUEmWrkM91azP wdUS7eRBbxr2rJR3hpAv/WpWu++XfbqLJHp5FYzJGLmyaJm0fPF8ew1e/aLPWOtXBPXj 1D/sOqTCwP84A9stWsTnwlYnAJOSV+aWBG80iw8nWTGixgPOGJPskeh16w+yt/RQg22m /AIWyGersaFQv8uDov/bWj1oEEpL3eychucpC00ChMnUO4G731zLnLODXxfmowSBK7ga mtzA== X-Received: by 10.180.75.243 with SMTP id f19mr30229655wiw.52.1440425807297; Mon, 24 Aug 2015 07:16:47 -0700 (PDT) Received: from ivaldir.etoilebsd.net ([2001:41d0:8:db4c::1]) by smtp.gmail.com with ESMTPSA id du6sm16388865wib.24.2015.08.24.07.16.45 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 24 Aug 2015 07:16:46 -0700 (PDT) Sender: Baptiste Daroussin Date: Mon, 24 Aug 2015 16:16:44 +0200 From: Baptiste Daroussin To: Willem Jan Withagen Cc: "stable@freebsd.org" Subject: Re: regression from previous version of pw Message-ID: <20150824141644.GI93486@ivaldir.etoilebsd.net> References: <55DB2100.4070304@digiware.nl> <20150824140133.GG93486@ivaldir.etoilebsd.net> <55DB2521.5030502@digiware.nl> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="o7gdRJTuwFmWapyH" Content-Disposition: inline In-Reply-To: <55DB2521.5030502@digiware.nl> User-Agent: Mutt/1.5.23 (2014-03-12) X-BeenThere: freebsd-stable@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Production branch of FreeBSD source code List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 24 Aug 2015 14:16:49 -0000 --o7gdRJTuwFmWapyH Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable 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. > >=20 > > The code has been changed to respect what the manual and the help outpu= t was > > showing: -V should be passed before the subcommand >=20 > 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 expla= ins. >=20 > > The reason for this is was to make the code more easily maintenable and > > understandable. >=20 > 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 th= ings 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 report= ed and fixed). >=20 > > if really that is too painful I can allow again -V to be also passed af= ter the > > subcommand but at the price of complicating the code. >=20 > Nope, I've already changed the code I have. > Was about 5 lines in a shell script. >=20 > 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 anyway= s. You are actually the second to report, the first was crochet which has be f= ixed straight forward. Best regards, Bapt --o7gdRJTuwFmWapyH Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 iEYEARECAAYFAlXbJ0wACgkQ8kTtMUmk6EyMbwCdFCYQHSiYxKIsK7YWr19ZQzI1 wJQAoInx1Ur9mJPk135W+C5K65KUfeiZ =Kmlf -----END PGP SIGNATURE----- --o7gdRJTuwFmWapyH--