Skip to content

Instantly share code, notes, and snippets.

@bjornvaktaren
Last active April 26, 2019 12:15
Show Gist options
  • Save bjornvaktaren/63a0dedb5f00565e8a0b8153330b4ba8 to your computer and use it in GitHub Desktop.
Save bjornvaktaren/63a0dedb5f00565e8a0b8153330b4ba8 to your computer and use it in GitHub Desktop.
emacs init file
(setq inhibit-startup-message t) ;; Do not display startup message
(tool-bar-mode -1) ;; Hide toolbar
;; Store backups in ~/.emacs.d/backups
(setq
backup-by-copying t
backup-directory-alist '(("." . "~/.emacs.d/backups"))
delete-old-versions t
kept-new-versions 6
kept-old-versions 2
version-control t)
;; C/C++ customization
(require 'cc-mode)
(setq c-default-style "k&r" ;; Style
c-basic-offset 3 ;; Indentation
)
;; ansi colors in shell mode
(require 'ansi-color)
(add-hook 'shell-mode-hook 'ansi-color-for-comint-mode-on)
;; lua mode
(setq auto-mode-alist (cons '("\.lua$" . lua-mode) auto-mode-alist))
(autoload 'lua-mode "lua-mode" "Lua editing mode." t)
;; auctex
(load "auctex.el" nil t t)
(load "preview-latex.el" nil t t)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment