Skip to content

Instantly share code, notes, and snippets.

@kngwyu
Last active June 19, 2019 16:12
Show Gist options
  • Save kngwyu/ba9bd27fcb198344d99c1ac8ee3c8dd6 to your computer and use it in GitHub Desktop.
Save kngwyu/ba9bd27fcb198344d99c1ac8ee3c8dd6 to your computer and use it in GitHub Desktop.
;;; init.el --- init file if Emacs
;;; Commentary:
;;; Code:
(package-initialize)
(setq package-archives
'(("gnu" . "http://elpa.gnu.org/packages/")
("melpa" . "http://melpa.org/packages/")
("org" . "http://orgmode.org/elpa/")))
;;; set path other than elpa
(add-to-list 'load-path "~/.emacs.d/site-lisp")
(setq-default bidi-display-reordering nil)
(setq inhibit-splash-screen t)
(setq history-delete-duplicates t)
(setq set-mark-command-repeat-pop t)
(when (require 'uniquify nil 'noerror)
(setq uniquify-buffer-name-style 'post-forward-angle-brackets)
(setq uniquify-ignore-buffers-re "[^*]+"))
(when (require 'save-place nil 'noerror)
(setq-default save-place t)
(setq save-place-file (concat user-emacs-directory "places")))
(show-paren-mode 1)
(setq-default indent-tabs-mode nil)
(global-hl-line-mode 1)
(savehist-mode 1)
(global-set-key (kbd "C-h") 'delete-backward-char)
(global-auto-revert-mode 1)
(line-number-mode 1)
(column-number-mode 1)
(setq gc-cons-threshold (* 10 gc-cons-threshold))
(defalias 'yes-or-no-p 'y-or-n-p)
(global-set-key (kbd "<hiragana-katakana>") 'toggle-input-method)
(global-set-key (kbd "C-x g") 'magit-status)
(global-set-key (kbd "C-x o") 'switch-window)
(setq make-backup-files nil)
(electric-pair-mode t)
;;; Aspell
(setq-default ispell-program-name "aspell")
(eval-after-load "ispell"
'(add-to-list 'ispell-skip-region-alist '("[^\000-\377]+")))
(provide 'init)
;;; init.el ends here
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment