From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Greg Minshall Newsgroups: gmane.emacs.devel Subject: Re: Emacs script options Date: Sat, 18 Nov 2023 06:38:24 -0800 Message-ID: <1496758.1700318304@archlinux> References: <1325582.1700277236@archlinux> <83cyw7o6m3.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="7930"; mail-complaints-to="usenet@ciao.gmane.io" Cc: emacs-devel@gnu.org To: Eli Zaretskii Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Sat Nov 18 15:39:27 2023 Return-path: Envelope-to: ged-emacs-devel@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 1r4MTm-0001qZ-BG for ged-emacs-devel@m.gmane-mx.org; Sat, 18 Nov 2023 15:39:26 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1r4MSw-0001TE-NW; Sat, 18 Nov 2023 09:38:34 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1r4MSv-0001T3-Ch for emacs-devel@gnu.org; Sat, 18 Nov 2023 09:38:33 -0500 Original-Received: from relay-egress-host.us-east-2.a.mail.umich.edu ([13.59.128.245] helo=friendly-aeron.relay-egress.a.mail.umich.edu) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1r4MSt-0006U7-8I; Sat, 18 Nov 2023 09:38:33 -0500 Original-Received: from amenable-duende.authn-relay.a.mail.umich.edu (ip-10-0-73-242.us-east-2.compute.internal [10.0.73.242]) by friendly-aeron.relay-egress.a.mail.umich.edu with ESMTPS id 6558CC65.47EC295.19579AA5.962914; Sat, 18 Nov 2023 09:38:29 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=umich.edu; s=relay-2018-08-29; t=1700318308; bh=i1u1vXTp5+sDy6nUi0GSsRuKHfo80RrZSFCF7nr2GvM=; h=To:cc:From:Subject:In-reply-to:References:Date; b=dc+zWrz3dc33WssJrqWipNhyB2SAhvHTnzoEhunTHaRjamCKnyo7EcuTCfoEhGrT+ alGgyov0TQE0184ec+Wod/kozFhF2nEcBLtqjLK9XtrNbpoJQpQL5AOnHYa1NpHIXS kVFN8sD8GLihVmeHVTxNQbfO9+xm35d/MRcqplYj6yUZbz1ooP4z/zitPkmNClAMW3 UUlF48FddjxM4PyJhQK3wf3ckvH/K+thQQVyJEMP3XaB4UYmucjfEiBsC+mekUrK9k sBOdqX6YJLqVG1ZxLOTC9OCj/RvLcZv6NzD+7dks72TgC4Us9U9tiITf899E3kM679 6RXyLivB7vy7A== Authentication-Results: amenable-duende.authn-relay.a.mail.umich.edu; iprev=pass policy.iprev=134.16.93.10 (134-016-093-010.res.spectrum.com); auth=pass smtp.auth=minshall Original-Received: from localhost (134-016-093-010.res.spectrum.com [134.16.93.10]) by amenable-duende.authn-relay.a.mail.umich.edu with ESMTPSA id 6558CC64.3034B05.4E36FF3A.1465438; Sat, 18 Nov 2023 09:38:28 -0500 In-reply-to: <83cyw7o6m3.fsf@gnu.org> Comments: In-reply-to Eli Zaretskii message dated "Sat, 18 Nov 2023 09:36:36 +0200." X-Mailer: MH-E 8.6+git; nmh 1.7.1; Emacs 30.0.50 Content-ID: <1496757.1700318304.1@archlinux> Received-SPF: pass client-ip=13.59.128.245; envelope-from=minshall@umich.edu; helo=friendly-aeron.relay-egress.a.mail.umich.edu X-Spam_score_int: -43 X-Spam_score: -4.4 X-Spam_bar: ---- X-Spam_report: (-4.4 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_MED=-2.3, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.devel:312909 Archived-At: Eli Zaretskii wrote: > But if we change that, how can we pass additional options to Emacs > when invoking it from a script? That is also an important capability, > and replacing it with what you want seems to be an incompatible > change, which takes away a capability we have now. > > If we want to be able to pass options to the script itself, we need to > do it in a compatible way, that doesn't lose what we have now. > > In any case, could you please show a real-life case where this is > needed? The -x option was intended to support the use cases where the > rest of the script is Emacs Lisp code, so what would such a script do > with an option that is not interpreted by Emacs, and why is that > needed? this last point is maybe all i can answer now (your other points are food for thought, and code-staring). the idea is a generalized facility that allows script-writers to do whatever they want, define whatever options they want. plus, trying to stay out of the way of even current, let alone future, Emacs options is tricky; realistically, script-writers would need to require their users to always type double-dashes, e.g., ---- ls-emacs -- -F ---- which doesn't seem so user-friendly. in my case, for example, i want to write an Emacs script that has some familiar options like "-d", "-V", etc., in addition to options to specify how the script should run (what input files to process, output files to produce, alterations to behavior). i could have users do that in an Emacs'y way ('--eval (setq debug 1)'). but, the idea is to provide something that, to the end user, looks like a standard Unix'y script. if that makes any sense. cheers, Greg