From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Spencer Baugh Newsgroups: gmane.emacs.bugs Subject: bug#72426: 29.2.50; comint-pager doesn't affect async-shell-command Date: Sat, 3 Aug 2024 12:42:00 -0400 Message-ID: References: <86sevmupgo.fsf@gnu.org> <86bk29vcof.fsf@gnu.org> Mime-Version: 1.0 Content-Type: multipart/alternative; boundary="000000000000149c0c061eca20ea" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="26606"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 72426@debbugs.gnu.org To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Sat Aug 03 18:43:05 2024 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 1saHqS-0006lT-WD for geb-bug-gnu-emacs@m.gmane-mx.org; Sat, 03 Aug 2024 18:43:05 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1saHq7-0001QY-Fh; Sat, 03 Aug 2024 12:42:43 -0400 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 1saHq6-0001QK-8e for bug-gnu-emacs@gnu.org; Sat, 03 Aug 2024 12:42:42 -0400 Original-Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1saHq5-0004Nr-VW for bug-gnu-emacs@gnu.org; Sat, 03 Aug 2024 12:42:41 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=debbugs.gnu.org; s=debbugs-gnu-org; h=Date:From:In-Reply-To:References:MIME-Version:To:Subject; bh=KC6rdOzEydZZTB1pLIShG5qSlN7aJEcFz2+yali87qU=; b=PE71an+WTV6LV1Nntn5+RmTQDCJqD9wXRCdPvMoiL3Ycfsh5732F8w5rWBDBLVUUFxJ+0L1WUVsnlt9RmW0maDuK/ecwkD7sdxgzrPlj7wLKeVR17ByngPRkjOb5FeqTCBSNWCCza0qfgenqNdDBAp8vYa/AsAmQvH26OTu1d0sX9bCWbU6BiJm2T3o9FCILLBFeLK7aMd7QHmlkG8w7ZXkwmou4URvwtIRIqre0dePnLvIxuPwJXx0IMf876af1GDMeQlIRZiPcoruc7jBy/woeIKyP5sw9MtJ//Y+AIxqb5zkVdUIGNaiWEDbdOqw5xW+95het/k74XPJgq28f2A==; Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1saHqP-0002fH-JZ for bug-gnu-emacs@gnu.org; Sat, 03 Aug 2024 12:43:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Spencer Baugh Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 03 Aug 2024 16:43:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 72426 X-GNU-PR-Package: emacs Original-Received: via spool by 72426-submit@debbugs.gnu.org id=B72426.172270336210173 (code B ref 72426); Sat, 03 Aug 2024 16:43:01 +0000 Original-Received: (at 72426) by debbugs.gnu.org; 3 Aug 2024 16:42:42 +0000 Original-Received: from localhost ([127.0.0.1]:54734 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1saHq6-0002dy-2H for submit@debbugs.gnu.org; Sat, 03 Aug 2024 12:42:42 -0400 Original-Received: from mxout1.mail.janestreet.com ([38.105.200.78]:50407) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1saHq1-0002dR-IV for 72426@debbugs.gnu.org; Sat, 03 Aug 2024 12:42:40 -0400 Original-Received: from mail-ej1-f72.google.com ([209.85.218.72]) by mxgoog2.mail.janestreet.com with esmtps (TLS1.3:TLS_AES_128_GCM_SHA256:128) (Exim 4.98) id 1saHpb-00000003DpA-2nxp for 72426@debbugs.gnu.org; Sat, 03 Aug 2024 12:42:12 -0400 Original-Received: by mail-ej1-f72.google.com with SMTP id a640c23a62f3a-a77f0eca75bso827243066b.1 for <72426@debbugs.gnu.org>; Sat, 03 Aug 2024 09:42:12 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=janestreet.com; s=google; t=1722703331; x=1723308131; darn=debbugs.gnu.org; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=KC6rdOzEydZZTB1pLIShG5qSlN7aJEcFz2+yali87qU=; b=aABoo53iD5Fe9Bp3BRRV9/LAx71Py05Jhna6B94AelxKIyDh2dBjpj2gFGIZCq20oV HkE4XFZmZvAtEdY8rkq7WyBEROa0ZpN2NvAPbigsIncli5b88UZyOwArK08X9FO0VYII AlKvVPKRXX6Qrqg6UhH4+0bGc/E2R8r5zejRg= DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=janestreet.com; s=waixah; t=1722703332; bh=KC6rdOzEydZZTB1pLIShG5qSlN7aJEcFz2+yali87qU=; h=References:In-Reply-To:From:Date:Subject:To:Cc; b=MEhXThTMoJ+CjZ+CrBL+Dmp5ZtF90YOYuFoRj48EtqnzRwCVXogDZGklBhXw7+t4h aOZ/Qn6qzQkNV0QnzjJ+QU65xYcKfFgNrLu1y00X5D9wRUborAiYS9nbJTYJvhIikx tf1r6gCI1BOEi2vuu0pz64uFYEvKAHBKPcb8iYdDoLrA1LYhh35w9z5HCCAQOXJudB I8y2ZOb72vl2j7v2DmdPA1FfDLWxqZNXBBQCAL429T9L5vZXmz57U1rXwetVuUp8rx B3ZklG4AW6/BtFKjesIhUpDywxsbY/Yv1ZimXMvk8g0sNJYCJxpST7MAf4pMrKR3G3 SirQzOH8QF5NA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1722703331; x=1723308131; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=KC6rdOzEydZZTB1pLIShG5qSlN7aJEcFz2+yali87qU=; b=R4yFq0B92We2MtLqkRUBHR811VYnYSQ7nwx98mjqdTgRAddzdmLjhEBGdPrVkgZhtI 19BSg+rDxSZ+ql4GfIvYefOA5zrxNTd5Y5l+uFl0nqL/qdN+ruhg17J2TTO+4IB5PTGt hzlge+BH7nXgHErlOPLMq6j3HdESIWEGC0Y6S5+P3EDdnf++7MljmrVs2LlMUodVuMxT wb7wvat8UmmSfxA39SmHRAHz1QN4kAJdTaJV032PkqeZqE+D4DlvRaMNVa0BazVfPcMX gNtxKJ1HN+yh9VxsEEdLGU1lqiQQ3/AY1sa846SoioIKeGVqtbHXxB5Finlr8UY/NVyk 4O1Q== X-Gm-Message-State: AOJu0YwT6hp4t+JRld+OXMFPQTABDZsKLlNrlGWnTET9kIj2JBPMVjw6 fwDSMuHni10dxEDOryCreXgZ6vG4u2OJk3ptIOq2IS4oT2UePlzwCkMqcZGAhbJwF01imibYc30 5LoDIcscjyBvkSUQGehjsb6TPLELL5zgsbDi5ntXcMteumLrWwP24iEnkhEMxiPqGkXhlVZCvxZ YPQf+GbMitQG2OR5mcrVIgwFvg1Q== X-Received: by 2002:a17:907:724b:b0:a72:7d5c:ace0 with SMTP id a640c23a62f3a-a7dc4db39fcmr501351966b.11.1722703331248; Sat, 03 Aug 2024 09:42:11 -0700 (PDT) X-Google-Smtp-Source: AGHT+IE3bRoEv2Lq3uE7Q+WNfCfgwQR/qQ0JFs3SVyLzzkRW/GmS91wLhfLaWaYZvuFh4M9g4Yds5qI0KyAv4if5O6Q= X-Received: by 2002:a17:907:724b:b0:a72:7d5c:ace0 with SMTP id a640c23a62f3a-a7dc4db39fcmr501350666b.11.1722703330706; Sat, 03 Aug 2024 09:42:10 -0700 (PDT) In-Reply-To: <86bk29vcof.fsf@gnu.org> 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-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:289686 Archived-At: --000000000000149c0c061eca20ea Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Sat, Aug 3, 2024, 11:39=E2=80=AFAM Eli Zaretskii wrote: > > From: Spencer Baugh > > Date: Sat, 3 Aug 2024 06:47:10 -0400 > > Cc: 72426@debbugs.gnu.org > > > > On Sat, Aug 3, 2024, 1:48=E2=80=AFAM Eli Zaretskii wrote= : > > > > > From: Spencer Baugh > > > Date: Fri, 02 Aug 2024 14:35:25 -0400 > > > > > > > > > 1. PAGER=3Dless emacs -Q > > > 2. (setq comint-pager "cat") > > > 3. (async-shell-command "echo $PAGER") > > > 4. Observe "less" rather than "cat". > > > > > > I intended async-shell-command to also be affected when I added > > > comint-pager; a patch to fix this will follow. > > > > Thanks, I don't think this is right: comint stuff should not affect > > lower-level primitives, it should only affect comint and its callers. > > > > comint-terminfo-terminal affects async-shell-command, why not this? > > Ugh! A mistake, IMNSHO. But that ship sailed a long time ago, so we > cannot fix the mistake. We can avoid enlarging the mistake, though. > > > If the fact that the variable is in comint is the problem, I can rename > it and move it elsewhere. > > I don't think functions that are almost primitives should pay > attention to application-level features such as this one. > If we're not going to make the variable apply to all usage, I think it should just be deleted before 30 is released. There's no point to it in that case, because it's still necessary to add (setenv "PAGER" "cat") to one's configuration. Alternatively, the default of comint-pager should be set to "cat". But I see no value in a variable like this if it neither applies to all (or at least most) users, nor provides better default behavior. > > Lisp programs that use async-shell-command can arrange for > > process-environment to have PAGER=3DSOMETHING as they see fit. > > > > My intention is primarily to affect interactive usage of > async-shell-command. > > But comint-term-environment also affects "M-x compile". > Yes, I would like comint-pager to also affect that. > --000000000000149c0c061eca20ea Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable

On Sat, Aug 3, 2024, 11:39=E2=80=AFAM Eli Zaretskii <eliz@gnu.org> wrote:
> From: Spencer Baugh <sbaugh@janestreet.co= m>
> Date: Sat, 3 Aug 2024 06:47:10 -0400
> Cc: 72426@debbugs.gnu.org
>
> On Sat, Aug 3, 2024, 1:48=E2=80=AFAM Eli Zaretskii <eliz@gnu.org> = wrote:
>
>=C2=A0 > From: Spencer Baugh <sbaugh@janestreet.com> >=C2=A0 > Date: Fri, 02 Aug 2024 14:35:25 -0400
>=C2=A0 >
>=C2=A0 >
>=C2=A0 > 1. PAGER=3Dless emacs -Q
>=C2=A0 > 2. (setq comint-pager "cat")
>=C2=A0 > 3. (async-shell-command "echo $PAGER")
>=C2=A0 > 4. Observe "less" rather than "cat". >=C2=A0 >
>=C2=A0 > I intended async-shell-command to also be affected when I a= dded
>=C2=A0 > comint-pager; a patch to fix this will follow.
>
>=C2=A0 Thanks, I don't think this is right: comint stuff should not= affect
>=C2=A0 lower-level primitives, it should only affect comint and its cal= lers.
>
> comint-terminfo-terminal affects async-shell-command, why not this?
Ugh!=C2=A0 A mistake, IMNSHO.=C2=A0 But that ship sailed a long time ago, s= o we
cannot fix the mistake.=C2=A0 We can avoid enlarging the mistake, though.
> If the fact that the variable is in comint is the problem, I can renam= e it and move it elsewhere.

I don't think functions that are almost primitives should pay
attention to application-level features such as this one.
<= /div>

If we're not g= oing to make the variable apply to all usage, I think it should just be del= eted before 30 is released.=C2=A0 There's no point to it in that case, = because it's still necessary to add (setenv "PAGER" "cat= ") to one's configuration.

Alternatively, the default of comint-pager should be set to &qu= ot;cat".

But I see = no value in a variable like this if it neither applies to all (or at least = most) users, nor provides better default behavior.
<= br>

>=C2=A0 Lisp programs that use async-shell-command can arrange for
>=C2=A0 process-environment to have PAGER=3DSOMETHING as they see fit. >
> My intention is primarily to affect interactive usage of async-shell-c= ommand.

But comint-term-environment also affects "M-x compile".

Yes, I wou= ld like comint-pager to also affect that.
--000000000000149c0c061eca20ea--