简体   繁体   中英

Emacs: Symbol's value as variable is void: Removes (init.el)

Sorry if this is a silly question; I am a complete novice when it comes to emacs.

Recently, I began to do research on how to set up emacs and stumbled upon a great video series by Mike Zamansky . However, whilst following this video (creating an org init file), all of the packages I installed onto my emacsclient proceeded to not work. During initialization, there was an error - namely, "Symbol's value as variable is void: Removes." I copied his tutorial verbatim and I don't see any potential syntactical errors - perhaps I overlooked some errors. However, I've been searching throughout the internet, but could not find any answers to this problem.

Here is the contents of the init.el file:

(require 'package)
(setq package-enable-at-startup nil)
(add-to-list 'package-archives
     '("melpa" . "http://melpa.org/packages/"))

(package-initialize)

;; Bootstrap 'use-package'
(unless (package-installed-p 'use-package)
  (package-refresh-contents)
  (package-install 'use-package))

(org-babel-load-file (expand-file-name "~/.emacs.d/myinit.org"))

Here is the error:

Warning (initialization): An error occurred while loading 
‘/Users/Kyojin/.emacs.d/init.el’:

Symbol's value as variable is void: Removes

To ensure normal operation, you should investigate and remove the
cause of the error in your initialization file.  Start Emacs with
the ‘--debug-init’ option to view a complete error backtrace.

Debugger Output (--debug-init):

Debugger entered--Lisp error: (void-variable Removes)
  eval-buffer(#<buffer  *load*-527594> nil 
"/Users/Kyojin/.emacs.d/myinit.el" nil t)  ; Reading at buffer position 
8
  load-with-code-conversion("/Users/Kyojin/.emacs.d/myinit.el" 
"/Users/Kyojin/.emacs.d/myinit.el" nil nil)
  load("/Users/Kyojin/.emacs.d/myinit.el" nil nil t)
  load-file("/Users/Kyojin/.emacs.d/myinit.el")
  (progn (load-file exported-file) "Loaded")
  (if compile (progn (byte-compile-file exported-file (quote load)) 
"Compiled and loaded") (progn (load-file exported-file) "Loaded"))
  (message "%s %s" (if compile (progn (byte-compile-file exported-file 
(quote load)) "Compiled and loaded") (progn (load-file exported-file) 
"Loaded")) exported-file)
  (let* ((age (function (lambda (file) (float-time (time-subtract 
(current-time) (nth 5 ...)))))) (base-name (file-name-sans-extension 
file)) (exported-file (concat base-name ".el"))) (if (and (file-exists-
p exported-file) (> (funcall age file) (funcall age exported-file))) 
nil (setq exported-file (car (last (org-babel-tangle-file file 
exported-file "emacs-lisp"))))) (message "%s %s" (if compile (progn 
(byte-compile-file exported-file (quote load)) "Compiled and loaded") 
(progn (load-file exported-file) "Loaded")) exported-file))
  org-babel-load-file("/Users/Kyojin/.emacs.d/myinit.org")
  eval-buffer(#<buffer  *load*> nil "/Users/Kyojin/.emacs.d/init.el" 
nil t)  ; Reading at buffer position 358
  load-with-code-conversion("/Users/Kyojin/.emacs.d/init.el" 
"/Users/Kyojin/.emacs.d/init.el" t t)
  load("/Users/Kyojin/.emacs.d/init" t t)
#[0"\205\266\306=\203\307\310Q\202?\311=\204\307\312Q\202?\313\307
\314\315#\203* \316\202?\313\307\314\317#\203>\320\321\322!D\nB\323
\202?\316\324\325\324\211#\210\324=\203e\326\327\330\307\331Q!\"\325
\324\211#\210\324=\203d\210\203\247\332!\333\232\203\247\334!  
\211\335P\336!\203\201\211\202\214\336!\203\213\202\214\314\262\
\203\245\337\"\203\243\340\341#\210\342\343!\210\266\f\205\264\314\325
\344\324\211#)\262\207"[init-file-user system-type 
delayed-warnings-list user-init-file inhibit-default-init inhibit-
startup-screen ms-dos "~" "/_emacs" windows-nt "/.emacs" directory-
files nil "^\\.emacs\\(\\.elc?\\)?$" "~/.emacs" "^_emacs\\(\\.elc?\\)?
$" initialization format-message "`_emacs' init file is deprecated, 
please use `.emacs'" "~/_emacs" t load expand-file-name "init" file-
name-as-directory "/.emacs.d" file-name-extension "elc" file-name-sans-
extension ".el" file-exists-p file-newer-than-file-p message "Warning: 
%s is newer than %s" sit-for 1 "default"] 7]()
  command-line()
  normal-top-level()

Search for the word Removes in your init file, "/Users/Kyojin/.emacs.d/myinit.el" (or possibly in some file that it loads).

If you don't find it immediately then recursively bisect your init file to find the code that is problematic. You can do that by commenting out first 1/2, then 3/4, then 7/8,... of the file until you locate the problem. You can comment a block of text/code by selecting it and then using Mx comment-region . You can uncomment a selection the same way, but with Cu first: Cu Mx comment-region .

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM