legend_noa 的 EMACS配置
(defun my-c-mode-auto-pair()
(interactive)
(make-local-variable'skeleton-pair-alist)
(setq skeleton-pair-alist'(
(?\" _ "\"" >)
(?\' _ "\'" >)
(?\( _ ")" >)
(?\[ _ "]" >)
(?{ \n > _ \n ?} >)))
(setq skeleton-pair t)
(local-set-key(kbd"(")'skeleton-pair-insert-maybe)
(local-set-key(kbd"{")'skeleton-pair-insert-maybe)
(local-set-key(kbd"[")'skeleton-pair-insert-maybe)
(local-set-key(kbd"\"")'skeleton-pair-insert-maybe)
(local-set-key(kbd"\'")'skeleton-pair-insert-maybe)
)
(add-hook'c++-mode-hook'my-c-mode-auto-pair)
(add-hook'c-mode-hook'my-c-mode-auto-pair)
(column-number-mode t)
(global-linum-mode t)
(setq make-backup-files nil)
(setq auto-save-mode nil)
(show-paren-mode t)
(setq show-paren-style'parenthesis)
(setq inhibit-splash-screen t)
(defun my-compile()
(interactive)
(save-some-buffers t)
(let((file(file-name-nondirectory buffer-file-name)))
(compile (format "g++ %s -g -o %s" file (file-name-sans-extension file))))
(switch-to-buffer-other-window"*compilation*")
)
(global-set-key(kbd"RET")'newline-and-indent)
(global-set-key[f4]'other-window)
(global-set-key[f5]'my-compile)
(global-set-key[f6]'gdb)
(custom-set-variables
;; custom-set-variables was added by Custom.
;; If you edit it by hand, you could mess it up, so be careful.
;; Your init file should contain only one such instance.
;; If there is more than one, they won't work right.
'(column-number-mode t)
'(cua-mode t nil (cua-base))
'(show-paren-mode t))
(custom-set-faces
;; custom-set-faces was added by Custom.
;; If you edit it by hand, you could mess it up, so be careful.
;; Your init file should contain only one such instance.
;; If there is more than one, they won't work right.
) (add-to-list'load-path"~/OI/.emacs-23.1/site-lisp")
(require'color-theme)
(color-theme-initialize)
(color-theme-deep-blue)
(setq-default cursor-type 'bar)
(setq c-default-style
'((c++ . "awk")))
legend_noa 的 EMACS配置的更多相关文章
- emacs配置eslint 语法检查.找不到node解决
使用emacs配置eslint 当调用语法检查时报错 Suspicious state from syntax checker javascript-eslint: Checker javascrip ...
- emacs配置详解及C/C++IDE全功能配置演示(附配置文件)
我的emacs插件下载地址: http://pan.baidu.com/share/link?shareid=4196458904&uk=3708780105 说明: 1.为什么使用emacs ...
- 一些有用的 Emacs 配置(窗口快速切换、一键透明效果、任意位置删除整行等)
本篇文章记录的是一些有用的 Emacs 配置,有些是自己原创,有些是借鉴别人(能记起来出处的我放了链接). 规定:C 代表 Ctrl,M 代表 Alt. 1.设置一次跳跃 n 行的快捷键 按 C-M- ...
- emacs 配置
个人的Emacs配置,环境是archlinux,参考了不少网上资料,因为太多,就不一一列举了,在这里感谢那些作者的辛苦经验劳动. (custom-set-variables ;; custom-set ...
- 绝世emacs配置for Ubuntu
反正过不了几天就要退役了,把emacs配置放出来造福(祸害)大众? 浓浓的OIER风格,除了方便打代码就没别的用处(F8并不这样认为?),只可惜windows下的弄丢了,只有Ubuntu下的. F1不 ...
- 存个emacs配置
emacs配置 (global-set-key [f9] 'compile-file) (global-set-key [f10] 'gud-gdb) (global-set-key (kbd &qu ...
- emacs 配置.emacs
emacs 配置.emacs (require 'package) (package-initialize) (add-to-list'package-archives '("melpa&q ...
- purcell的emacs配置中的自动补全功能开启
标记一下,原文参看purcell的emacs配置中的自动补全功能开启 修改init-auto-complete.el文件 ;;(setq-default ac-expand-on-auto-compl ...
- 中国大陆无法访问Steve Purcell的emacs配置解决办法
因为大陆网络问题,没办法访问Steve Purcell的emacs配置中的melpa.org,所以我们更改目录即可. 1.删除自己的配置. $ rm ~/.emacs $ rm -rf ~/.emac ...
随机推荐
- python 在内网windows环境下pip三方包
我没用过Linux环境. 一般情况下,内网安装三方包,只需要在pypi找到对应python版本(2.7,3.6,...),系统位数(32位,64位)的whl包,cmd命令行cd进入相关目录,pip i ...
- BatchPreparedStatementSetter,用法
spring批量更新数据 ---- BatchPreparedStatementSetter (2007-04-15 15:41:29) 转载▼ 标签: spring batchpreparedsta ...
- admin 自定义字段颜色 并加以简单判断
在model中class Books(models.Model): nid = models.AutoField(primary_key=True, ) title = models.CharFiel ...
- Problem E: 平面上的点和线——Point类、Line类 (V)
Description 在数学上,平面直角坐标系上的点用X轴和Y轴上的两个坐标值唯一确定,两点确定一条线段.现在我们封装一个“Point类”和“Line类”来实现平面上的点的操作. 根据“append ...
- golang中的mutex锁
mutex锁中一种互斥锁,如果有多个goroutine需要对同一变量进行修改则需要对该变量施加mutex锁以实现安全读写.
- django学习系列——python和php对比
python 和 php 我都是使用过,这里不想做一个非常理性的分析,只是根据自己的经验谈一下感想. 在web开发方面,无疑 php 更甚一筹. 从某种角度来说,php 就是专门为 web 定制的语言 ...
- 北大poj- 1012
Joseph Time Limit: 1000MS Memory Limit: 10000K Total Submissions: 56348 Accepted: 21526 Descript ...
- jdbc工具类的封装,以及表单验证数据提交后台
在之前已经写过了jdbc的工具类,不过最近学习了新的方法,所以在这里重新写一遍,为后面的javaEE做铺垫: 首先我们要了解javaEE项目中,文件构成,新建一个javaEE项目,在项目中,有一个we ...
- nginx 配置 HTTPS 及http 强制跳转https.
#user nobody; worker_processes 1; #error_log logs/error.log; #error_log logs/error.log notice; #erro ...
- python+flask+session写供前端使用的后台接口,实现登录保存session时报错。
RuntimeError: The session is unavailable because no secret key was set. Set the secret_key on the a ...