こちらから。
Rubyリファレンスマニュアル刷新計画(るりま)をanything.elで検索して生産性を向上する - (rubikitch loves (Emacs Ruby CUI Books))
anything-rurimaの導入
install-elisp-from-emacswikiとかからanything-rurima.elを落とし、
イントロダクションを見てみると、まあインストールの方法とかは記載されているので、
あとはそっからやってみたらいいんじゃないだろうか。
以下をそのまんまやればいいと思うよ。Ruby1.9必須らしいけど。
;; Rubyリファレンスマニュアル刷新計画(るりま)をanythingで検索します。 ;; ;; (1) るりまのリポジトリをチェックアウトする。~/compile/rurima以下に展開するものとする。 ;; $ cd ~/compile; mkdir rurima; cd rurima ;; $ svn co http://jp.rubyist.net/svn/rurema/doctree/trunk rubydoc ;; (2) http://www.rubyist.net/~rubikitch/archive/ar-index.rb から ;; ダウンロードして、以下のコマンドでドキュメントのインデックスを作成する。 ;; Ruby 1.9必須! ;; ~/compile/rurima/rubydoc/rurima.eというファイルが作成される。 ;; $ ruby1.9 ar-index.rb ~/compile/rurima/rubydoc rurima.e ;; (3) http://www.emacswiki.org/cgi-bin/wiki/download/auto-install.elをインストールする。 ;; (4) auto-install.elの設定を加える。 ;; (require 'auto-install) ;; (setq auto-install-directory "~/.emacs.d/auto-install/") ;; (auto-install-update-emacswiki-package-name t) ;; (auto-install-compatibility-setup) ;; (5) M-x auto-install-batch anything を実行して anything 一式をインストールする。 ;; (6) anything-rurima.elの設定を加える。 ;; (require 'anything-rurima) ;; (setq anything-rurima-index-file "~/compile/rurima/rubydoc/rurima.e") ;; ;; M-x anything-rurima でマニュアルを検索するためのプロンプトが出ます。 ;; M-x anything-rurima-at-point でカーソル位置の単語をマニュアル検索します。
あと、僕は便宜上compileではなくprojectsというディレクトリでやっています。
で、anything-rurima-at-pointで、カーソル位置の単語をるりまで調べることが出来るわけだけど、
これってデフォルトでは何のキーバインドも割り当てられていないので、
ruby-modeが起動しているときはC-c C-fで単語を調べられるようにした。
;; anything-rurima (require 'anything-rurima) (setq anything-rurima-index-file "~/projects/rurima/rubydoc/rurima.e") ;; ruby-modeが起動しているときだけanything-rurima-at-pointが使えるようにする (when (require 'ruby-mode nil t) (global-set-key (kbd "C-c C-f") 'anything-rurima-at-point))
これで、Rubyの単語も自在に調べられるぞ。