emacs常用有效配置(持续更新中)

版权声明:本文为博主原创文章,未经博主允许不得转载。 https://blog.csdn.net/guanjintao/article/details/82593655

自动补全括号:

(electric-pair-mode t)

包管理:

(require 'package)
(let* ((no-ssl (and (memq system-type '(windows-nt ms-dos))
                    (not (gnutls-available-p))))
       (proto (if no-ssl "http" "https")))
  ;; Comment/uncomment these two lines to enable/disable MELPA and MELPA Stable as desired
  (add-to-list 'package-archives (cons "melpa" (concat proto "://melpa.org/packages/")) t)
  ;;(add-to-list 'package-archives (cons "melpa-stable" (concat proto "://stable.melpa.org/packages/")) t)
  (when (< emacs-major-version 24)
    ;; For important compatibility libraries like cl-lib
    (add-to-list 'package-archives '("gnu" . (concat proto "://elpa.gnu.org/packages/")))))
(package-initialize)

如果要使用 稳定的软件包而不是默认的“前沿”存储库,请使用以下代码"melpa"

(add-to-list 'package-archives
             '("melpa-stable" . "https://stable.melpa.org/packages/") t)
(global-linum-mode t) ;侧边显示行号
(column-number-mode t) ;状态栏显示行列信息
(show-paren-mode t) ;括号匹配高亮
(global-hl-line-mode 1) ;当前行高亮
(tool-bar-mode 0);;不显示工具栏
(menu-bar-mode 0);;不显示菜单栏
(scroll-bar-mode 0);;不显示滚动条

(display-time-mode 1) ;; 显示时间  
(setq display-time-24hr-format t) ;;时间格式 
(setq display-time-day-and-date t) ;;显示时间、星期、日期


(setq inhibit-startup-message t);;关闭启动画面 

欢迎志趣相投的朋友一起学习交流! 
本人qq:906570770 
技术资料分享群:272811256

猜你喜欢

转载自blog.csdn.net/guanjintao/article/details/82593655
今日推荐