add org-rst settings
This commit is contained in:
@@ -1532,6 +1532,32 @@ contextual information."
|
||||
(format "<pre class=\"src src-%s\"%s>%s</pre>"
|
||||
lang label code))))))))
|
||||
|
||||
(use-package ox-rst
|
||||
:defer t
|
||||
;; autoloads
|
||||
;; :commands (org-rst-export-to-rst
|
||||
;; org-rst-export-as-rst
|
||||
;; org-rst-convert-region-to-rst
|
||||
;; org-rst-publish-to-rst)
|
||||
:config
|
||||
(setq org-rst-code-block 'code-block)
|
||||
|
||||
(defun my-org-rst-metadata-format-function (info)
|
||||
"Custom format function for `org-rst-matadata'."
|
||||
(let ((author (and (plist-get info :with-author)
|
||||
(let ((auth (plist-get info :author)))
|
||||
(and auth (org-export-data auth info)))))
|
||||
(date (and (plist-get info :with-date)
|
||||
(org-export-data (org-export-get-date info) info))))
|
||||
(concat
|
||||
".. article-info::\n"
|
||||
(when author (format "\t:Author: %s\n" author))
|
||||
(when date (format "\t:Date: %s\n" date)))))
|
||||
(setq org-rst-metadata 'my-org-rst-metadata-format-function)
|
||||
;; (setq org-rst-metadata ".. article-info::\n\t:Author: %a\n\t:Date: %d")
|
||||
|
||||
(setq org-rst-link-use-ref-role t))
|
||||
|
||||
;; Allows you to edit entries directly from org-brain-visualize
|
||||
(use-package polymode
|
||||
:defer t
|
||||
|
||||
Reference in New Issue
Block a user