My開発メモ

Emacsの拡張機能Anythingのインストール(Ubuntu 24.04)

Anything を更新したので、その手順をメモしておく。

(参考) anything のサイト
https://www.emacswiki.org/emacs/Anything

このページに書かれてある手順でおこなった。

(1) anythingのダウンロード

$ git clone git://repo.or.cz/anything-config.git

ダウンロードしたフォルダ anything-config は ~/.emacs.d/elisp/ に anything とリネームしておく。

$ mv ./anything-config ~/.emacs.d/elisp/anything

(2) init.elの修正

$ vi ~/.emacs.d/init.el
;;;===========================================
;;; anything.el 設定
;; -------------------------------------------------------------
;; emacs起動時に以下のエラーが出るので、
;; Symbol's value as variable is void: browse-url-galeon-program
;; 以下のようにした。
(defvar browse-url-galeon-program nil)
(defvar browse-url-netscape-program nil)
(defvar browse-url-mosaic-program nil)
;; 古いブラウザ変数ということだが、どういうことかな。
;; ---------------------------------------------
(add-to-list 'load-path "~/.emacs.d/elisp/anything")
(require 'anything-config)
(setq anything-enable-shortcuts 'prefix)
(define-key anything-map (kbd "@") 'anything-select-with-prefix-shortcut)
(global-set-key (kbd "C-x b") 'anything-mini)

(3) init.elの末尾に次を追記する

init.elの末尾に次を追記する。

(setq imenu-auto-rescan nil)

これは、anything-config.el の中で t になっているので、
haskellファイルを開くと、Scanning declarations が何度も繰り返され、
ミニバッファに常に Sorting declarations … done が表示され、困るのである。

詳しいことは、次に書いた。

ミニバッファに”Sorting declarations … done.”のメッセージが出て困る(Emacs)
http://nukblog.work/2026/08/24/sorting-declarations-done/

参考

anything のサイト
https://www.emacswiki.org/emacs/Anything

ミニバッファに”Sorting declarations … done.”のメッセージが出て困る(Emacs)
http://nukblog.work/2026/08/24/sorting-declarations-done/

カテゴリー: Emacs, memo, Ubuntu

タグ: Anything, emacs, init.el

カウント: 28