# How to setup Emacs with inferior ruby-interpreter?

**URL:** <https://www.ruby-forum.com/t/how-to-setup-emacs-with-inferior-ruby-interpreter/146740>\
**Category:** Ruby\
**Created:** [August 24, 2008, 10:21pm UTC](https://www.ruby-forum.com/t/how-to-setup-emacs-with-inferior-ruby-interpreter/146740 "2008-08-24T22:21:40Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![ssecorp](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/s/f04885/32.png) [@ssecorp](https://www.ruby-forum.com/u/ssecorp)\
**Post date:** [August 24, 2008, 10:21pm UTC](https://www.ruby-forum.com/t/how-to-setup-emacs-with-inferior-ruby-interpreter/146740/1 "2008-08-24T22:21:40Z")

</div>

I have tried to get Emacs to run an inferior ruby process.

I can run the interpreter with comint-run irb.bat but then I can’t  
load a program into the interpreter.

I already have ruby-mode for emacs so I got syntax hightlighting and  
all that stuff, just want to be able to run an integrated interpreter.

also, is there a compiler for ruby?

---

<div class="post-metadata">

**Author:** ![ssecorp](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/s/f04885/32.png) [@ssecorp](https://www.ruby-forum.com/u/ssecorp)\
**Post date:** [August 24, 2008, 10:46pm UTC](https://www.ruby-forum.com/t/how-to-setup-emacs-with-inferior-ruby-interpreter/146740/2 "2008-08-24T22:46:16Z")

</div>

ssecorp [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid) writes:

> I have tried to get Emacs to run an inferior ruby process.
> 
> I can run the interpreter with comint-run irb.bat but then I can’t  
> load a program into the interpreter.
> 
> I already have ruby-mode for emacs so I got syntax hightlighting and  
> all that stuff, just want to be able to run an integrated interpreter.

ruby-mode has built in support for inferior-ruby. From any buffer that  
is in ruby-mode, you can type M-x run-ruby to start inferior ruby.

The run-ruby function is in inf-ruby.el

See [EmacsWiki: Ruby Mode](http://www.emacswiki.org/cgi-bin/wiki/RubyMode)
