Emacs 安装与体验
2024-10-21 14:27:40
Emacs 安装与体验
下载与安装
首先是下载最新的x64版本的Emacs。
将下载下来的文件解压到你喜欢的磁盘目录下,我选择的是
C:\Program Files
。放在D盘可能是更好的选择,因为待会的配置文件因此可以更方便的同安装文件一起保存到D盘,而不是C盘。进入
C:\Program Files\emacs\bin
目录下,运行addpm.exe
。启动Emacs,点击
Options
下的Highlight Matching Parenheses
,随后点击Save Options
。我们此举的目的是因为我们是第一次使用Emacs,以此来触发Emacs生成配置文件目录。可以发现在c:/Users/<username>/AppData/Roaming/
下生成了.emacs
文件以及.emacs.d
文件夹。下面我们要动一些手脚,因为将配置文件放在C盘是不理想的,比如重装系统等,容易丢失配置信息。我们打开刚刚生成的
.emacs
文件,按如下修改1.(custom-set-variables
2.;; custom-set-variables was added by Custom.
3.;; If you edit it by hand, you could mess it up, so be careful.
4.;; Your init file should contain only one such instance.
5.;; If there is more than one, they won't work right.
6.'(show-paren-mode t))
7.(custom-set-faces
8.;; custom-set-faces was added by Custom.
9.;; If you edit it by hand, you could mess it up, so be careful.
10.;; Your init file should contain only one such instance.
11.;; If there is more than one, they won't work right.
12.)
13.(load-file "C:/Program Files/emacs/.emacs")这是什么意思呢?就是说,Emacs在启动的时候会加载
c:/Users/<username>/AppData/Roaming/.emacs
,我们修改这个文件,使得其又加载了C:\Program Files\emacs\.emacs
文件。这样就实现了配置的转移。等等,我们的
C:\Program Files\emacs
下似乎并没有.emacs
文件,好吧,我们现在创建一个吧,只能用命令行创建,先随便创建一个什么文件,然后用命令行进行改名,比方说,我们创建了一个emacs.txt
文件,然后使用rename emacs.txt .emacs
命令,间接的创建了一个Emasc配置文件。修改刚刚创建的
.emacs
文件内容如下:1.;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
2.;; emacs in windows
3.;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
4.(setenv "HOME" "C:/Program Files/emacs")
5.(setenv "PATH" "C:/Program Files/emacs")
6.;; set the default file path
7.(setq default-directory "~/")
最新文章
- UI自动化,你值得拥有
- jQuery基础1
- SPOJ:ABCDEF
- CSS的4种引入方式及优先级
- spring配置定时器的时间设置
- jQuery.loadTemplate客户端模板
- 【收藏】win7打开word每次提示配置解决办法
- 判断直线与线段相交 POJ 3304 Segments
- [Windows Phone] 地图控制项的经纬度
- C#的扩展方法简介
- 基于Orangpi Zero和Linux ALSA实现WIFI无线音箱(二)
- yarn安装
- java8新特性:interface中的static方法和default方法
- k-mean 拐点
- Python 语言之 map/reduce
- Bzoj4480: [Jsoi2013]快乐的jyy 广义后缀自动机 倍增 哈希 manacher
- 跟着ZooKeeper学Java——CountDownLatch和Join的使用
- rpm: /root/anaconda3/lib/liblzma.so.5: version `XZ_5.1.2alpha&#39; not found (required by /lib64/librpmio.so.3)
- ALGO-143_蓝桥杯_算法训练_字符串变换
- 如何使用navicat远程连接服务器上的oracle数据库
热门文章
- Android 使用NestedScrollView+ViewPager+RecyclerView+SmartRefreshLayout打造酷炫下拉视差效果并解决各种滑动冲突
- 如何用Windows PowerShell替换命令提示符
- Autoit3脚本编写举例
- mysql-练级查询
- MovieReview—Coco(寻梦环游记)
- 【UML】部署图Deployment diagram(实现图)(转)
- HDU 5459 Jesus Is Here (递推,组合数学)
- 2018.2.12 PHP 如何读取一亿行的大文件
- java基础—static关键字
- sencha touch 入门学习资料大全