Configurations

irb reads `~/.irbrc' when it is invoked. If `~/.irbrb' doesn't exist
irb try to read in the order `.irbrc', `irb.rc', `_irbrc' then `$irbrc'.
The following is altanative to the command line option. To use them
type as follows in an irb session.

Constants PROMPT_I, PROMPT_S and PROMPT_C specifies the format.
In the prompt specification, some special strings are available.

%N command name which is running
%m to_s of main object (self)
%M inspect of main object (self)
%l type of string(", ', /, ]), `]' is inner %w[...]
%NNi indent level. NN is degits and means as same as printf("%NNd").
It can be ommited
%NNn line number.
%% %

For instance, the default prompt mode is defined as follows:
IRB.conf[:PROMPT_MODE][:DEFAULT] = {

PROMPT_I => "%N(%m):%03n:%i> ",

PROMPT_S => "%N(%m):%03n:%i%l ",

PROMPT_C => "%N(%m):%03n:%i* ",

RETURN => "%s\n"
}
RETURN is used to printf.

Configurating subirb

The command line option or IRB.conf specify the default behavior of
(sub)irb. On the other hand, each conf of in the next sction `6. Command'
is used to individually configurate (sub)irb.
If proc is set to IRB.conf[:IRB_RC], its subirb will be invoked after
execution of that proc under giving the context of irb as its
aregument. By this mechanism each subirb can be configurated.

Command

For irb commands, both simple name and `irb_'-prefixed name are prepared.