Subject: bug#72426: 29.2.50; comint-pager doesn't affect async-shell-command

From: Spencer Baugh <[email-masked]>
Date: Sat, 3 Aug 2024 06:47:10 -0400

On Sat, Aug 3, 2024, 1:48 AM Eli Zaretskii <[email-masked]> wrote:

> > From: Spencer Baugh <[email-masked]>
> > Date: Fri, 02 Aug 2024 14:35:25 -0400
> >
> >
> > 1. PAGER=less 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?

If the fact that the variable is in comint is the problem, I can rename it
and move it elsewhere.

Lisp programs that use async-shell-command can arrange for
> process-environment to have PAGER=SOMETHING as they see fit.
>

My intention is primarily to affect interactive usage of
async-shell-command.