Help us understand the problem. What is going on with this article?


More than 5 years have passed since last update.


(defvar anything-c-sources-local-gem-file
  '((name . "gems (local)")
    (init . (lambda ()
              (unless (anything-candidate-buffer)
                 "gem list" nil (anything-candidate-buffer 'global)
    (action . (lambda (gem-name)
                (setq gem-name (replace-regexp-in-string "\s+(.+)$" "" gem-name))
                  (call-process "gem" nil t nil "which" gem-name)
                  (let ((path (buffer-substring-no-properties (point-min)
                                                              (- (point-max) 1))))
                    (if (file-exists-p path)
                        (find-file path)
                      (message "no such file or directory:\"%s\"" path))))

(defun anything-local-gems ()
   "*anything local gems*"

M-x anything-local-gems で、インストールされているgemの一覧が出るので、選ぶと、それのソース開きます。

ffap + devel-whichあればそんなに必要ないか…

Why not register and get more from Qiita?
  1. We will deliver articles that match you
    By following users and tags, you can catch up information on technical fields that you are interested in as a whole
  2. you can read useful information later efficiently
    By "stocking" the articles you like, you can search right away