Corrected erroneous losses to .emacs
This commit is contained in:
@@ -1,4 +1,4 @@
|
|||||||
;; GETTING STARTED
|
;; Emacs init file, by and for ntnsndr
|
||||||
|
|
||||||
;; INITIALIZE MELPA
|
;; INITIALIZE MELPA
|
||||||
;; Keep this on top
|
;; Keep this on top
|
||||||
@@ -35,14 +35,14 @@
|
|||||||
(global-visual-line-mode t)
|
(global-visual-line-mode t)
|
||||||
;; load word-count tools, use "wc" command to get instant count
|
;; load word-count tools, use "wc" command to get instant count
|
||||||
(load "wc-mode")
|
(load "wc-mode")
|
||||||
;; source: http://is.gd/ag5KOC
|
;; 4-space tabs as default
|
||||||
(setq backup-directory-alist '(("." . "~/.emacs.d/backup"))
|
(setq-default indent-tabs-mode nil)
|
||||||
backup-by-copying t ; Don't delink hardlinks
|
(setq-default tab-width 4)
|
||||||
version-control t ; Use version numbers on backups
|
|
||||||
delete-old-versions t ; Automatically delete excess backups
|
;; MARKDOWN MODE
|
||||||
kept-new-versions 20 ; how many of the newest versions to keep
|
(autoload 'markdown-mode "markdown-mode" "Major mode for editing Markdown files" t)
|
||||||
kept-old-versions 5 ; and how many of the old
|
(add-to-list 'auto-mode-alist '("\\.markdown\\'" . markdown-mode))
|
||||||
)
|
(add-to-list 'auto-mode-alist '("\\.md\\'" . markdown-mode))
|
||||||
|
|
||||||
;; HORIZONTAL WINDOWS
|
;; HORIZONTAL WINDOWS
|
||||||
;; open horizontal windows as default for multiple files
|
;; open horizontal windows as default for multiple files
|
||||||
@@ -54,8 +54,37 @@
|
|||||||
(add-hook 'emacs-startup-hook '2-windows-vertical-to-horizontal)
|
(add-hook 'emacs-startup-hook '2-windows-vertical-to-horizontal)
|
||||||
|
|
||||||
;; MARGINS
|
;; MARGINS
|
||||||
(setq-default left-margin-width 1)
|
(setq-default left-margin-width 2)
|
||||||
(setq-default right-margin-width 1)
|
(setq-default right-margin-width 2)
|
||||||
|
;; set window margins
|
||||||
|
;; (a bit buggy on multiple-window startup, but resolves)
|
||||||
|
;;(add-hook 'window-configuration-change-hook
|
||||||
|
;; (lambda ()
|
||||||
|
;; (set-window-margins (car
|
||||||
|
;; (get-buffer-window-list
|
||||||
|
;; (current-buffer) nil t)) 2 2)))
|
||||||
|
|
||||||
|
|
||||||
|
;; SPELLING
|
||||||
|
|
||||||
|
(add-hook 'text-mode-hook 'flyspell-mode)
|
||||||
|
(add-hook 'prog-mode-hook 'flyspell-prog-mode)
|
||||||
|
;; Turn on Flyspell
|
||||||
|
(dolist (hook '(text-mode-hook))
|
||||||
|
(add-hook hook (lambda ()
|
||||||
|
(flyspell-mode 1)
|
||||||
|
(set-variable 'flyspell-issue-message-flag nil)
|
||||||
|
(flyspell-buffer))))
|
||||||
|
|
||||||
|
;; BACKUP CONTROL
|
||||||
|
;; source: http://is.gd/ag5KOC
|
||||||
|
(setq backup-directory-alist '(("." . "~/.emacs.d/backup"))
|
||||||
|
backup-by-copying t ; Don't delink hardlinks
|
||||||
|
version-control t ; Use version numbers on backups
|
||||||
|
delete-old-versions t ; Automatically delete excess backups
|
||||||
|
kept-new-versions 20 ; how many of the newest versions to keep
|
||||||
|
kept-old-versions 5 ; and how many of the old
|
||||||
|
)
|
||||||
|
|
||||||
;; FUNCTIONS
|
;; FUNCTIONS
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user