eschulte / rinari

Rinari Is Not A Rails IDE (it is an Emacs minor mode for Rails)
http://rinari.rubyforge.org
GNU General Public License v3.0
412 stars 68 forks source link

Support PRY input from rinari-web-server Ruby Compilation buffer #69

Closed localredhead closed 11 years ago

localredhead commented 11 years ago

When I use pry (in lieu of debugger for Ruby 2.0) I run my webserver using rinari-web-server.

When I stop on a Pry breakpoint, I would like to interact with the Pry console inside the rinari compilation buffer.

Thoughts?

I basically want to do M-x send-invisible , without it being invisible.

dgutov commented 11 years ago

Run it in comint-mode? See pezra/rspec-mode#45.

localredhead commented 11 years ago

I visited the linked issue but it is not clear how I can run the server in comint mode using rinari ?

asok commented 11 years ago

Yup it's similar issue. I guess there are several choices to run webserver in comint-mode:

    (comint-mode)
    (setq buffer-read-only nil)
    (compilation-shell-minor-mode)
localredhead commented 11 years ago

asok - your last suggestion kind of works, almost exactly as I want. I'm having some issues but I'll see if I can't work them out. Thank you for suggesting this. I'll tinker with it more

(defun rinari-pry-jack-in ()
  (interactive)
  (comint-mode)
  (setq buffer-read-only nil)
  (compilation-shell-minor-mode))
dgutov commented 11 years ago

Here's what I'm doing now (with rspec-mode, actually):

C-x C-q M-x inf-ruby-mode

Seems shorter.

purcell commented 11 years ago

@dgutov Nice.