Repository navigation
Commit 72a8316
committed
gh-161039: fix detection of less >= 706 in _pyrepl/pager.py
Since less tag v706¹, less exits with a failure status when no filename
is provided. Pass the `-?` option and redirect both stdout and stderr
to /dev/null.
Failure to detect `less` results in using `more` for users who don't
have MANPAGER or PAGER set, which is unexpected.
¹ gwsw/less@7c85230 (Exit with a failure
status in more cases, 2026-06-14)1 parent e80962a commit 72a8316
1 file changed
Lines changed: 1 addition & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
36 | 36 | | |
37 | 37 | | |
38 | 38 | | |
39 | | - | |
| 39 | + | |
40 | 40 | | |
41 | 41 | | |
42 | 42 | | |
| |||
0 commit comments