Reputation: 2424
The rails server is slow when I run it within emacs shell-mode. It seems to me that the page does not load until all the output has been printed inside the emacs shell. I thought about just opening it in a terminal and tailing the output in emacs, but I often use the debugger and I love to have it in emacs. When you run the server in the terminal it seems as if it dumps all the output at once, where emacs seems to get the data in buffered chunks which slows the page load down. Does anyone know a way to speed this up?
Thanks!
Upvotes: 3
Views: 330
Reputation: 2424
seems like this is a well known issue,
http://debbugs.gnu.org/cgi/bugreport.cgi?bug=13675
edit
If I open the shell like this
(let ((process-connection-type nil)) ; use a pipe
(shell "blarg"))
this makes the shell open using a pipe instead of a tty. It also has the effect of making the server not wait for the text to finish rendering in emacs. It can cause the output to buffer though which I get around by starting the server like so script -q /dev/null rails server
Upvotes: 1
Reputation: 36
Try using rinari-mode (available in melpa or marmalade). Rinari has a command rinari-web-server that runs a Rails server from Emacs, and as I remember loads as fast as if you ran "rails server" in the terminal.
Also, try switching from WEBrick to something faster like Thin.
Upvotes: 1