CLI: set JJ_PAGER=cat for shell commands so jj output does not page
What version of Codex CLI is running?
codex-cli 0.130.0
What subscription do you have?
Pro
Which model were you using?
Any
What platform is your computer?
Darwin 24.6.0 arm64 arm
What terminal emulator and version are you using (if applicable)?
Any terminal.
Codex doctor report
N/A
What issue are you seeing?
Codex shell commands should avoid invoking pagers, but jj commands can still page because jj intentionally does not honor generic PAGER.
Codex already sets pager-related environment defaults such as PAGER=cat, GIT_PAGER=cat, and GH_PAGER=cat for unified exec commands. That works for many tools, but not for jj.
jj recently added a dedicated pager override, JJ_PAGER, in jj 0.41:
https://github.com/jj-vcs/jj/pull/9395
That PR explains why jj uses a jj-specific override instead of restoring generic $PAGER handling. So Codex needs to set JJ_PAGER=cat explicitly if it wants jj commands to behave like other non-interactive shell commands.
What steps can reproduce the bug?
- Use a jj version that supports
JJ_PAGER(jj0.41 or newer). - Run Codex in a jj repository.
- Ask Codex to run jj commands that can produce paged output, such as:
``sh``
jj log
jj diff
jj show
- Observe that jj may invoke its configured pager even though Codex already disables common pagers via
PAGER=cat,GIT_PAGER=cat, andGH_PAGER=cat.
What is the expected behavior?
Codex should set JJ_PAGER=cat in the same default shell-command environment where it sets other pager-disabling variables.
That would make jj commands behave consistently with git/GitHub CLI commands in Codex: output should be emitted directly to the command stream, not captured by an interactive pager.
Additional information
This should be a low-risk addition:
JJ_PAGERis jj-specific and only affects jj.- Older jj versions should ignore it.
- jj 0.41+ intentionally supports it as the correct tool-specific override.
- This is consistent with Codex already setting
GIT_PAGER=catandGH_PAGER=cat.
Workaround for users waiting on this, or if the Codex team decides this is too niche:
[shell_environment_policy.set]
JJ_PAGER = "cat"
Users do not need to repeat the existing pager variables in config. shell_environment_policy.set overlays specific variables on top of the inherited/default shell environment.
This issue has 2 comments on GitHub. Read the full discussion on GitHub ↗