Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Always use alternate sceen on alt-d #988

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

tompng
Copy link
Member

@tompng tompng commented Aug 14, 2024

Fixes screen corruption when PAGER=more is used.

When ALT+D is pressed while showing document dialog, document in shown in full screen using pager.
IRB assumes that the pager switches to alternate screen, turns off alternate screen at exit, and restore IRB's screen.

Some pager like more does not do that. Screen corrupts. We need to switch to alternate screen manually.

irb_with_pager_eq_more
To reproduce:
PAGER=more irb (make sure more is not aliased to less)
PAGER="sh -c 'cat;sleep 1'" irb

@st0012 st0012 added the bug Something isn't working label Aug 14, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Development

Successfully merging this pull request may close these issues.

2 participants