fix(file-templates): update doom doc templates

To reflect the new mode: line added in 7e400ab, and add an ID property.
Also corrects heading level in __doom-readme file template.

Ref: 7e400abdc0
This commit is contained in:
Henrik Lissner 2022-08-03 14:07:03 +02:00
parent 08dac1400f
commit d6ffd2bfaa
No known key found for this signature in database
GPG key ID: B60957CA074D39A3
4 changed files with 31 additions and 4 deletions

View file

@ -352,6 +352,21 @@ This primes `org-mode' for reading."
("doom-suggest-faq" . "id:aa28b732-0512-49ed-a47b-f20586c0f051")
("github" . "https://github.com/%s")))
;;;###autoload
(defun doom-docs-generate-id (&optional force?)
"Generate an ID for a `doom-docs-org-mode' buffer."
(let ((org-id-link-to-org-use-id t)
(org-id-method 'uuid)
(org-id-track-globally t)
(org-id-locations-file (doom-path doom-cache-dir "doom-docs-org-ids"))
(org-id-locations doom-docs--id-locations)
(org-id-files doom-docs--id-files))
(doom/reload-docs)
(let ((id (org-id-new)))
(org-id-add-location
id (buffer-file-name (buffer-base-buffer)))
id)))
;;;###autoload
(define-derived-mode doom-docs-org-mode org-mode "Doom Docs"
"A derivative of `org-mode' for Doom's documentation files.