From 8bfb4ea2b962f57ca5ac662ea6829ec4f43ad034 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Sun, 16 Sep 2012 23:19:10 +0200 Subject: [PATCH] Fix 'lesspipe' for ri. --- lib/pry/commands/ri.rb | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) mode change 100644 => 100755 lib/pry/commands/ri.rb diff --git a/lib/pry/commands/ri.rb b/lib/pry/commands/ri.rb old mode 100644 new mode 100755 index fcb5dd2c..b9c69961 --- a/lib/pry/commands/ri.rb +++ b/lib/pry/commands/ri.rb @@ -21,7 +21,9 @@ class Pry subclass.class_eval do def page - Pry::Helpers::BaseHelpers.lesspipe {|less| yield less} + paging_text = StringIO.new + yield paging_text + Pry::Pager.page(paging_text.string) end def formatter(io)