Commit graph

7 commits

Author SHA1 Message Date
Stan Lo
f55746a93d [ruby/irb] Disable pager when TERM is not set too
(https://github.com/ruby/irb/pull/802)

173980974b
2023-12-05 16:32:13 +00:00
Stan Lo
ef387e6730 [ruby/irb] Pager should be disabled when TERM=dumb
(https://github.com/ruby/irb/pull/800)

For apps/libs that test against IRB, it's recommended to set `TERM=dumb`
so they get minimum disruption from Reline's interactive-focus features.

Therefore, we should follow the convention to disable pager when `TERM=dumb`.

8a3002a39e
2023-12-05 16:03:06 +00:00
Stan Lo
f193f96d31 [ruby/irb] Page evaluation result's output
(https://github.com/ruby/irb/pull/784)

* Page evaluation result's output

This will make it easier to work with long output that exceeds the terminal's height.

* Use consistent TERM in rendering tests

This makes sure we get consistent result on all platforms.

4fedce93d3
2023-11-30 15:22:22 +00:00
Stan Lo
9cd086ba4b [ruby/irb] Support disabling pager
(https://github.com/ruby/irb/pull/783)

With either `IRB.conf[:USE_PAGER] = false` or `--no-pager` commnad line flag.

I decided use `--no-pager` instead of `--use-pager` because it matches with
Pry and git's command line flags.

df1c3b9042
2023-11-26 11:07:50 +00:00
hogelog
e2078ccd5a [ruby/irb] Fix failure of more command with -R option
(https://github.com/ruby/irb/pull/781)

7d6849e44e
2023-11-23 07:24:35 +00:00
Stan Lo
283b2fdab4 [ruby/irb] Page ls's output (https://github.com/ruby/irb/pull/657)
* Page ls command's output

* Use Pager.page_content in show_cmds too

82d1687302
2023-07-26 08:32:02 +00:00
Stan Lo
d8cee55073 [ruby/irb] Display show_cmds's output in a pager when in TTY
environment
(https://github.com/ruby/irb/pull/647)

This can:

- Make it easier to scroll up and down the commands list
- Avoid pushing up users' previous output
- Allow users to do basic search with `/<word>`

f94e8a66dd
2023-07-25 18:33:23 +00:00