From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#52999: 29.0.50; [PATCH v3] `eshell-eval-using-options' should follow POSIX/GNU argument conventions Date: Wed, 05 Jan 2022 16:50:01 +0200 Message-ID: <83h7ai9qzq.fsf@gnu.org> References: <8c7a7765-2d40-e685-1d93-c60496a4f626@gmail.com> <83k0ffbqo1.fsf@gnu.org> Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="35395"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 52999@debbugs.gnu.org To: Jim Porter Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Wed Jan 05 15:54:12 2022 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1n57g3-00090g-9j for geb-bug-gnu-emacs@m.gmane-mx.org; Wed, 05 Jan 2022 15:54:11 +0100 Original-Received: from localhost ([::1]:32906 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1n57g2-0008Jg-6v for geb-bug-gnu-emacs@m.gmane-mx.org; Wed, 05 Jan 2022 09:54:10 -0500 Original-Received: from eggs.gnu.org ([209.51.188.92]:36254) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1n57c4-0001Z0-DU for bug-gnu-emacs@gnu.org; Wed, 05 Jan 2022 09:50:06 -0500 Original-Received: from debbugs.gnu.org ([209.51.188.43]:56509) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1n57c2-0004ln-7B for bug-gnu-emacs@gnu.org; Wed, 05 Jan 2022 09:50:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1n57c1-0005dV-V7 for bug-gnu-emacs@gnu.org; Wed, 05 Jan 2022 09:50:01 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 05 Jan 2022 14:50:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 52999 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch Original-Received: via spool by 52999-submit@debbugs.gnu.org id=B52999.164139420021653 (code B ref 52999); Wed, 05 Jan 2022 14:50:01 +0000 Original-Received: (at 52999) by debbugs.gnu.org; 5 Jan 2022 14:50:00 +0000 Original-Received: from localhost ([127.0.0.1]:39822 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n57c0-0005dB-ES for submit@debbugs.gnu.org; Wed, 05 Jan 2022 09:50:00 -0500 Original-Received: from eggs.gnu.org ([209.51.188.92]:35434) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n57bz-0005cv-Cg for 52999@debbugs.gnu.org; Wed, 05 Jan 2022 09:49:59 -0500 Original-Received: from [2001:470:142:3::e] (port=44424 helo=fencepost.gnu.org) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1n57br-0004k5-BX; Wed, 05 Jan 2022 09:49:52 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=Bb7aVKeZC2R0w8aqp10nTIuLZ9ORJbgQHuL1nelx9PU=; b=BxT851VyBIJA /v3E7wDYGKAzi5Ud1lZOeBiL3t0MzOAcDR6PFCz8h6WZmhPP+ysBvV7cCukfeFbQFD2XeAlw9yO6A MfyG3kDdJr/u7lGmmPDs9HaMJ+iJfZU5saFcFY0zGuxFKJlHAuz6Zicib8LA2VkvFhEc17Ik61w+/ GB37ctrYTQLjEBzh4oLZXZy4J2/QzsjkgrwplDPgtUv3J2nlOCQkaD0R5zSQidXnA79AsWWQe4jVW 8meiDS5IMriPM3SvlaqRyJ/SH86Ny9h+NEZQ8K1VA2NaTygN8aY8M4X2FeumCzAYluUa7fJUCBVUG EX+mFR0ndNSNbrV53wkK6A==; Original-Received: from [87.69.77.57] (port=3521 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1n57br-000189-CZ; Wed, 05 Jan 2022 09:49:51 -0500 In-Reply-To: (message from Jim Porter on Tue, 4 Jan 2022 13:09:29 -0800) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:223689 Archived-At: > Cc: 52999@debbugs.gnu.org > From: Jim Porter > Date: Tue, 4 Jan 2022 13:09:29 -0800 > > I just wasn't sure if `eshell-eval-using-options' should be in the > manual or not. Thinking it over a bit more, it would have helped me if > it had been in the manual (I encountered this bug while trying to write > my own Eshell built-in command), so I added some info about it to the > manual, mostly adapted from the docstring for > `eshell-eval-using-options'. Hopefully I followed the right conventions > here; I'm only vaguely familiar with the Texinfo format. Yes, the documentation part is fine, modulo some minor comments below. > > Can these tests be made less platform-specific? For example, not all > > the supported platforms have /dev/null, and we have a portable > > abstraction for it. > > They should actually work cross-platform, since the tests don't invoke > the commands at all; they just make sure that > `eshell-eval-using-options' can parse the switches correctly. To make > this a bit clearer though, I replaced "/dev/null" with "/some/path". > Hopefully when people see that, they'll understand that this is a "fake" > path not corresponding to anything on the actual filesystem. Apologies for misreading this part of the code. > +@item symbol > +This element is the name of the Lisp symbol that will be bound to > +@var{value}. Is it a symbol or its name (a string)? You say "name", but the example: > If @var{symbol} is @code{nil}, specifying this switch uses a symbol, not its name. > +@item :preserve-args > +If present, do not pass @var{macro-args} through @code{flatten-tree} > +and @code{eshell-stringify-list}. I think this should explain the effect of that, or the difference between using and not using this keyword. > +--- > +** 'eshell-eval-using-options' now follows POSIX/GNU argument syntax conventions. > +This now accepts command-line options with values passed as a single ^^^^ "Eshell" instead of "This" will make it more clear what you mean. Thanks.