1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00
ruby--ruby/doc/irb/irb-tools.rd.ja

186 lines
4 KiB
Text
Raw Normal View History

irb<EFBFBD><EFBFBD>Ϣ<EFBFBD><EFBFBD><EFBFBD>ޤ<EFBFBD><EFBFBD><EFBFBD><EFBFBD>ޥ<EFBFBD><EFBFBD>ɤȥ饤<EFBFBD>֥<EFBFBD><EFBFBD><EFBFBD>
$Release Version: 0.7.1 $
$Revision$
$Date$
by Keiju ISHITSUKA(Nihon Rational Co.,Ltd.)
=begin
:<3A><><EFBFBD>ޥ<EFBFBD><DEA5><EFBFBD>:
* rtags -- ruby tags command
:<3A>ؿ<EFBFBD><D8BF><EFBFBD>֥<EFBFBD><D6A5><EFBFBD>:
* xmp -- irb version of gotoken xmp-function
:<3A><><EFBFBD><EFBFBD><EFBFBD>֥<EFBFBD><D6A5><EFBFBD>:
* frame.rb -- frame tracer
* completion.rb -- irb completor
= rtags
rtags<EFBFBD><EFBFBD>emacs<EFBFBD>ڤ<EFBFBD>vi<EFBFBD>Ѥ<EFBFBD>, TAG<41>ե<EFBFBD><D5A5><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ĥ<EFBFBD><C4A4><EFBFBD>ޥ<EFBFBD><DEA5>ɤǤ<C9A4>.
== <20>Ȥ<EFBFBD><C8A4><EFBFBD>
rtags [-vi] file....
<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ȥǥ<EFBFBD><EFBFBD><EFBFBD>ȥ<EFBFBD><EFBFBD><EFBFBD>emacs<EFBFBD>Ѥ<EFBFBD>TAGS<EFBFBD>ե<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ǥ<EFBFBD><EFBFBD>ޤ<EFBFBD>. -vi<76><69><EFBFBD>ץ<EFBFBD><D7A5><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
<EFBFBD>Ĥ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ˤ<EFBFBD>vi<EFBFBD>Ѥ<EFBFBD>tags<EFBFBD>ե<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ޤ<EFBFBD>.
emacs<EFBFBD>ξ<EFBFBD><EFBFBD><EFBFBD>, <20>̾<EFBFBD><CCBE><EFBFBD>etags.el<65><6C><EFBFBD><EFBFBD><EFBFBD>Τޤ޻Ȥ<DEBB><C8A4>ޤ<EFBFBD>. <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ǽ<EFBFBD>ʤΤ<CAA4>,
* <20><><EFBFBD>
* <20><EFBFBD>å<EFBFBD>
* <20>ðۥ᥽<DBA5>å<EFBFBD>
* alias
* attr<74><72><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>줿<EFBFBD><ECA4BF><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>(<28>ѥ<EFBFBD><D1A5><EFBFBD><E1A1BC><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ܥ뤫ʸ<EBA4AB><CAB8><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ƥ<EFBFBD><C6A5><EFBFBD><EFBFBD>˸¤<CBB8>)
* attr_XXX<58><58><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>줿<EFBFBD><ECA4BF><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>(<28>ѥ<EFBFBD><D1A5><EFBFBD><E1A1BC><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ܥ뤫ʸ<EBA4AB><CAB8><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ƥ<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FBFBD><EFBFBD><EFBFBD>Ƥ<EFBFBD><EFBFBD>ޤ<EFBFBD>. <20>ޥ<EFBFBD><DEA5><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>åɤ<C3A5>
<EFBFBD><EFBFBD><EFBFBD>б<EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ƥ<EFBFBD><EFBFBD>ޤ<EFBFBD><EFBFBD><EFBFBD>.
= completion.rb
irb<EFBFBD><EFBFBD>completion<EFBFBD><EFBFBD>ǽ<EFBFBD><EFBFBD><EFBFBD>󶡤<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ΤǤ<EFBFBD>.
== <20>Ȥ<EFBFBD><C8A4><EFBFBD>
% irb -r irb/completion
<EFBFBD>Ȥ<EFBFBD><EFBFBD>뤫, ~/.irbrc <20><><EFBFBD><EFBFBD>
require "irb/completion"
<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ƥ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>. irb<72>¹<EFBFBD><C2B9><EFBFBD><EFBFBD><EFBFBD> require "irb/completion" <20><><EFBFBD>Ƥ<EFBFBD><C6A4><EFBFBD>Ǥ<EFBFBD>.
irb<EFBFBD>¹<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> (TAB) <20>򲡤<EFBFBD><F2B2A1A4>ȥ<EFBFBD><C8A5><EFBFBD><EFBFBD>ץ졼<D7A5><ECA1BC><EFBFBD><EFBFBD><EFBFBD>󤷤ޤ<F3A4B7A4>.
<EFBFBD>ȥåץ<EFBFBD><EFBFBD>٥<EFBFBD><EFBFBD><EFBFBD>(TAB)<29>򲡤<EFBFBD><F2B2A1A4>Ȥ<EFBFBD><C8A4>٤Ƥι<C6A4>ʸ<EFBFBD><CAB8><EFBFBD><EFBFBD>, <20><><EFBFBD>饹, <20><EFBFBD>åɤθ<C9A4><CEB8><EFBFBD><E4A4AC>
<EFBFBD>ޤ<EFBFBD>. <20><><EFBFBD>䤬ͣ<E4A4AC><CDA3><EFBFBD>ʤ<EFBFBD><CAA4>д<EFBFBD><D0B4><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><E4B4B0><EFBFBD>ޤ<EFBFBD>.
irb(main):001:0> in
in inspect instance_eval
include install_alias_method instance_of?
initialize install_aliases instance_variables
irb(main):001:0> inspect
"main"
irb(main):002:0> foo = Object.new
#<Object:0x4027146c>
((|<7C>ѿ<EFBFBD>̾.|))<29>θ<EFBFBD><CEB8><EFBFBD>(TAB)<29>򲡤<EFBFBD><F2B2A1A4><EFBFBD>, <20><><EFBFBD>Υ<EFBFBD><CEA5>֥<EFBFBD><D6A5><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ȤΥ<CEA5>åɰ<C3A5><C9B0><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ǥ<EFBFBD>
<20><>.
irb(main):003:0> foo.
foo.== foo.frozen? foo.protected_methods
foo.=== foo.hash foo.public_methods
foo.=~ foo.id foo.respond_to?
foo.__id__ foo.inspect foo.send
foo.__send__ foo.instance_eval foo.singleton_methods
foo.class foo.instance_of? foo.taint
foo.clone foo.instance_variables foo.tainted?
foo.display foo.is_a? foo.to_a
foo.dup foo.kind_of? foo.to_s
foo.eql? foo.method foo.type
foo.equal? foo.methods foo.untaint
foo.extend foo.nil?
foo.freeze foo.private_methods
=end
% Begin Emacs Environment
% Local Variables:
% mode: text
% comment-column: 0
% comment-start: "%"
% comment-end: "\n"
% End:
%