summary refs log tree commit diff
path: root/config/init-writing.el
blob: ee7fb19470255c16c458be206910263c2d904846 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
;;; init-writing.el --- Configure things related to writing -*- lexical-binding: t -*-
;; Author: Franck Cuny <franck@fcuny.net>

;;; Commentary:

;; Configure things related to writing

;;; Code:

(use-package flyspell
  :defer
  :hook ((text-mode       . flyspell-mode)
	 (org-mode        . flyspell-mode)
	 (git-commit-mode . flyspell-mode)
	 (prog-mode       . flyspell-prog-mode))
  :diminish flyspell-mode
  :custom
  (ispell-program-name "aspell")
  (ispell-silently-savep t)
  (ispell-local-dictionary "en_US")
  (ispell-extra-args '("--camel-case")))

(use-package markdown-mode
  :ensure t
  :mode (("\\`README\\.md\\'" . gfm-mode)
         ("\\.md\\'"          . markdown-mode)
         ("\\.markdown\\'"    . markdown-mode))
  :custom
  (markdown-command "pandoc -f markdown_github+smart")
  (markdown-command-needs-filename t)
  (markdown-enable-math t)
  (markdown-open-command "marked")
  :init
  (setq markdown-command "multimarkdown"))

(provide 'init-writing)

;;; init-writing.el ends here