[英]Cannot open load file | Emacs doesn't see my .el files even if they exist on MAC OS X?
[英]Where is my .emacs file on Mac OS X
所以我试图将google go模块添加到我的.emacs文件中,以便当我使用emacs编辑我的.go文件时,它将具有相应的缩进和突出显示的单词。 我看了网上,似乎我需要将以下代码片段添加到我的.emacs文件(我找不到!)
;; go mode
(setq load-path (cons "/usr/local/go/misc/emacs" load-path))
(require 'go-mode-load)
我在我的.emacs.d /目录中放了go-mode-load.el和go-mode.el我相信我仍然需要找到.emacs文件来添加上面列出的代码我运行OS X如果这有帮助的话。 有人可以帮我搞定这个工作谢谢!
使用M-:
评估此M-:
(find-file user-init-file)
然后,Emacs将打开它认为您的用户初始化文件。
我有
(global-set-key (kbd "<f12>") (lambda () (interactive) (find-file-other-window user-init-file)))
在我的.emacs
以便我可以轻松编辑它。
Emacs手册告诉您:
This file, if it exists, specifies how to initialize Emacs for you.
Emacs looks for your init file using the filenames `~/.emacs', `~/.emacs.el',
or `~/.emacs.d/init.el'; you can choose to use any one of these three
names. Here, `~/' stands for your home directory.
我想大多数人都使用~/.emacs
。 如果您还没有Cx Cf ~/.emacs
,请创建它。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.