Config: add jinx spell check, org-download, and keybinding updates
This commit is contained in:
@@ -12,6 +12,20 @@
|
||||
(lambda ()
|
||||
(require 'org-checklist nil t)))
|
||||
|
||||
;; org-download
|
||||
(use-package org-download
|
||||
:config
|
||||
(when *is-mac*
|
||||
(setq org-download-image-dir "./images")
|
||||
(unless (file-exists-p "./images")
|
||||
(make-directory "./images" t))
|
||||
(setq org-download-link-format "[[file:%s]]\n")
|
||||
(setq org-download-timestamp "%Y%m%d_%H%M%S_")
|
||||
(setq org-download-dragndrop t)
|
||||
(setq org-image-actual-width nil)
|
||||
(setq org-download-image-html-width 600)
|
||||
(add-hook 'org-mode-hook 'org-display-inline-images)))
|
||||
|
||||
;; org-journal
|
||||
(use-package org-journal
|
||||
:config
|
||||
@@ -97,7 +111,15 @@
|
||||
(add-hook 'org-mode-hook
|
||||
(lambda ()
|
||||
(require 'org-tempo)
|
||||
(org-indent-mode)))
|
||||
(org-indent-mode)
|
||||
(setq-local electric-pair-inhibit-predicate
|
||||
(lambda (char)
|
||||
(or (eq char ?<)
|
||||
(electric-pair-default-inhibit char))))))
|
||||
|
||||
(with-eval-after-load 'org
|
||||
(require 'org-download)
|
||||
(setq org-return-follows-link t))
|
||||
|
||||
;; 预加载,防止windows的org-mode加载卡顿
|
||||
(if *is-windows*
|
||||
@@ -209,6 +231,11 @@
|
||||
(org-table-map-tables 'org-table-align t)))
|
||||
|
||||
;; hugo
|
||||
|
||||
;; 安装ox-hugo
|
||||
(use-package ox-hugo)
|
||||
|
||||
|
||||
(with-eval-after-load 'org-capture
|
||||
(defun org-hugo-new-subtree-post-capture-template ()
|
||||
"Returns `org-capture' template string for new Hugo post.
|
||||
|
||||
Reference in New Issue
Block a user