我.emacs
文件具有以下內容:錯誤而載入.emacs文件
$ cat ~/.emacs
(setq vc-handled-backends nil)
(global-linum-mode t)
$ od -xcb ~/.emacs
0000000 7328 7465 2071 6376 682d 6e61 6c64 6465
( s e t q v c - h a n d l e d
050 163 145 164 161 040 166 143 055 150 141 156 144 154 145 144
0000020 622d 6361 656b 646e 2073 696e 296c 280a
- b a c k e n d s n i l ) \n (
055 142 141 143 153 145 156 144 163 040 156 151 154 051 012 050
0000040 6c67 626f 6c61 6c2d 6e69 6d75 6d2d 646f
g l o b a l - l i n u m - m o d
147 154 157 142 141 154 055 154 151 156 165 155 055 155 157 144
0000060 2065 2974
e t )
145 040 164 051
0000064
這些是絕對有效的Emacs的LISP表達式。 但最近每當我啓動Emacs,行號不再出現,取而代之的是,一個錯誤出現:
$emacs --debug-init ~/.emacs
Debugger entered--Lisp error: (void-function global-linum-mode)
(global-linum-mode t)
eval-buffer(#<buffer *load*> nil "/Users/user/.emacs" nil t) ; Reading at buffer position 53
load-with-code-conversion("/Users/user/.emacs" "/Users/user/.emacs" t t)
load("~/.emacs" t t)
#[nil "^H\205\276^@ \306=\203^Q^@\307^H\310Q\202A^@ \311=\2033^@\312\307\313\314#\203#^@\315\202A^@\312\307\313\316$
command-line()
normal-top-level()
版本的Emacs:
$ emacs --version
GNU Emacs 22.1.1
Copyright (C) 2007 Free Software Foundation, Inc.
GNU Emacs comes with ABSOLUTELY NO WARRANTY.
You may redistribute copies of Emacs
under the terms of the GNU General Public License.
For more information about these matters, see the file named COPYING.
有沒有人有一個想法,什麼可能導致這個? 感謝
你使用的是什麼版本的emacs?我很想知道你是否默認了一個沒有linum模式的emacs版本。 'emacs --version' –
剛剛編輯了該版本的更多信息。 (22.1.1)但正如我所說的那樣,linum模式以前是工作的。 – user1508893
您的平臺上是否有多個emacs(例如/ usr/local/bin/emacs,/ usr/bin/emacs等)?你使用和以前一樣的emacs嗎?請檢查。 – syohex