简体   繁体   English

无法在emacs启动时加载cl-lib

[英]cannot load cl-lib at emacs startup

I have downloaded autopair from Github and extracted it to ~/.emacs.d . 我从Github下载了~/.emacs.d并将其解压缩到~/.emacs.d Also I added the lines given in the installation instructions 我还添加了安装说明中给出的行

(add-to-list 'load-path "/path/to/autopair") ;; comment if autopair.el is in standard load path 
(require 'autopair)
(autopair-global-mode) ;; enable autopair in all buffers

I modified (add-to-list 'load-path "/path/to/autopair") as (add-to-list 'load-path "~/.emacs.d/autopair-master/") as that folder contains the autopair.el file. (add-to-list 'load-path "/path/to/autopair") (add-to-list 'load-path "~/.emacs.d/autopair-master/") (add-to-list 'load-path "/path/to/autopair")(add-to-list 'load-path "~/.emacs.d/autopair-master/")因为该文件夹包含autopair.el文件。 But when I open emacs it shows 但是,当我打开emacs时,它会显示出来

Warning (initialization): An error occurred while loading `/home/karthikeyan/.emacs':

File error: Cannot open load file, cl-lib

I use emacs 23.4.1 in Linux Mint 15 and is there any alternate way to autocomplete the braces with a function at startup? 我在Linux Mint 15中使用emacs 23.4.1并且有没有其他方法可以在启动时使用函数自动完成大括号? . Also it doesn't showup autopair mode in Meta-x 它也没有在Meta-x autopair模式

try this (my emacs version is 23): 试试这个(我的emacs版本是23):

  1. create new directory cl-lib in your .emacs.d directory .emacs.d目录中创建新目录cl-lib
  2. put this file into this cl-lib directory 将此文件放入此cl-lib目录中
  3. add at top of your .emacs file these strings: 在.emacs文件的顶部添加以下字符串:
    • (add-to-list 'load-path "/path_to_your.emacs.d/cl-lib/") (add-to-list'load-path“/path_to_your.emacs.d/cl-lib/”)
    • (require 'cl-lib) (需要'cl-lib)

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

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