summaryrefslogtreecommitdiff
path: root/emacs/custom/my-text.el
diff options
context:
space:
mode:
authorFranck Cuny <franck@fcuny.net>2022-03-23 09:45:02 -0700
committerFranck Cuny <franck@fcuny.net>2022-03-23 09:45:02 -0700
commite4828b646bb8697e40f51fed911332a057e3c03a (patch)
treee0458a145cbb4c728d5ff68f6c6b91a065c12c3d /emacs/custom/my-text.el
parentrename fcuny-edit to my-edit (diff)
downloademacs.d-e4828b646bb8697e40f51fed911332a057e3c03a.tar.gz
rename fcuny-text to my-text
Diffstat (limited to 'emacs/custom/my-text.el')
-rw-r--r--emacs/custom/my-text.el39
1 files changed, 39 insertions, 0 deletions
diff --git a/emacs/custom/my-text.el b/emacs/custom/my-text.el
new file mode 100644
index 0000000..6dfb124
--- /dev/null
+++ b/emacs/custom/my-text.el
@@ -0,0 +1,39 @@
+;;; my-text.el --- configures
+;;; Commentary:
+;;; Code:
+
+(require 'use-package)
+
+(use-package flyspell
+ :ensure t
+ :if (executable-find "aspell")
+ :hook ((text-mode . flyspell-mode)
+ (prog-mode . flyspell-prog-mode))
+ :custom
+ (ispell-dictionary "en_US")
+ (ispell-program-name "aspell")
+ (ispell-extra-args '("--camel-case"))
+ :config
+ (use-package flyspell-correct-ivy
+ :after flyspell
+ :ensure t
+ :bind (:map flyspell-mode-map
+ ("C-M-:" . flyspell-correct-at-point))
+ :custom
+ (flyspell-correct-interface #'flyspell-correct-ivy)))
+
+(use-package markdown-mode
+ :ensure t
+ :after (flyspell)
+ :commands (markdown-mode gfm-mode)
+ :mode (("README\\.md\\'" . gfm-mode)
+ ("\\.md\\'" . gfm-mode)
+ ("\\.markdown\\'" . gfm-mode))
+ :custom
+ (markdown-fontify-code-blocks-natively t)
+ :config
+ (when (executable-find "pandoc")
+ (setq markdown-command "pandoc -f markdown -t html")))
+
+(provide 'my-text)
+;;; my-text.el ends here