Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

automatic indentation in the irb shell?

7 views
Skip to first unread message

aidy

unread,
Apr 20, 2006, 11:32:00 AM4/20/06
to
I might be asking a bit much, but is it possible to have automatic
indentation in the irb shell?

Aidy

gabriele renzi

unread,
Apr 20, 2006, 1:12:51 PM4/20/06
to
aidy ha scritto:

> I might be asking a bit much, but is it possible to have automatic
> indentation in the irb shell?
>


put
IRB.conf[:AUTO_INDENT]=true
in your irbrc file, this should do the trick.

aidy

unread,
Apr 21, 2006, 5:57:34 AM4/21/06
to
Hi,
> in your irbrc file

I have done a full search on *irbrc* and nothing is returned. I am
using ruby-1.8.4.

Cheers

Aidy

olleolleolle

unread,
Apr 21, 2006, 7:40:39 AM4/21/06
to
Dear Aidy,

The file is called .irbrc (with a dot), and resides in your home
folder. ~/.irbrc as they say in UNIX-speak. If you are on Windows, I'm
not sure where that should live.

gabriele renzi

unread,
Apr 21, 2006, 5:03:12 PM4/21/06
to
olleolleolle ha scritto:

on win32 I have just set an IRBRC=\path\to\file env variable and it
works fine, I never investigated where my home was supposed to be :)

Mobody hackely

unread,
Apr 22, 2006, 9:53:51 AM4/22/06
to

[drive]:\documents and settings\[username]
I believe you can use _irbrc, as windows won't let you create .irbrc
through explorer. You can create it programatically though.

File.open( "C:\\documents and setting\\administrator\\.irbrc", "w" )
do |f|
f.puts "# Heres a comment"
end

0 new messages