Giter Site home page Giter Site logo

Comments (5)

dgutov avatar dgutov commented on May 17, 2024

Yep, I've also seen the pry hooks error, but didn't have time to look into it.

Any suggestions how to fix it?

from robe.

bawalsh3000 avatar bawalsh3000 commented on May 17, 2024

Sorry, I'm just starting out with emacs/elisp , so no suggestions off the top my head :)
I'll try more fiddling

from robe.

dgutov avatar dgutov commented on May 17, 2024

This seems to help:

diff --git a/inf-ruby.el b/inf-ruby.el
index e6b55be..61cea16 100755
--- a/inf-ruby.el
+++ b/inf-ruby.el
@@ -229,8 +229,17 @@ The following commands are available:
   (when (eq system-type 'windows-nt)
     (setq comint-process-echoes t))
   (compilation-shell-minor-mode t)
+  (inf-ruby-set-window-size)
+  (add-hook 'window-configuration-change-hook 'inf-ruby-set-window-size nil t)
   (run-hooks 'inf-ruby-mode-hook))

+(defun inf-ruby-set-window-size ()
+  (let ((proc (get-buffer-process (current-buffer))))
+    (when proc
+      (set-process-window-size
+       proc (window-text-height) (1- (window-body-width))))))
+
 (defun inf-ruby-output-filter (output)
   "Check if the current prompt is a top-level prompt."
   (unless (zerop (length output))

Although I do wonder if that's something Pry should handle itself. It's not like it ends up using the returned values in any meaningful way, AFAICS.

from robe.

dgutov avatar dgutov commented on May 17, 2024

I've reverted the workaround, but see the update in the inf-ruby README now.

from robe.

bawalsh3000 avatar bawalsh3000 commented on May 17, 2024

Ya, I finally wound up turning off pager too. It's shame that Pry just
checks for nil window size before triggering the default.

On Wed, Jul 30, 2014 at 10:02 PM, Dmitry Gutov [email protected]
wrote:

I've reverted the workaround, but see the update in the inf-ruby README
now.


Reply to this email directly or view it on GitHub
#37 (comment).

from robe.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.