perf(docs): disable gc for doom-docs-org-mode
This commit is contained in:
parent
a71e757c8d
commit
725de1ca35
1 changed files with 41 additions and 42 deletions
|
@ -374,6 +374,8 @@ This primes `org-mode' for reading."
|
|||
Keeps track of its own IDs in `doom-docs-dir' and toggles `doom-docs-mode' when
|
||||
`read-only-mode' is activated."
|
||||
:after-hook (visual-line-mode -1)
|
||||
(let ((gc-cons-threshold most-positive-fixnum)
|
||||
(gc-cons-percentage 1.0))
|
||||
(require 'org-id)
|
||||
(require 'ob)
|
||||
(setq-local org-id-link-to-org-use-id t
|
||||
|
@ -412,10 +414,7 @@ Keeps track of its own IDs in `doom-docs-dir' and toggles `doom-docs-mode' when
|
|||
(unless (local-variable-p 'org-startup-folded)
|
||||
(let ((org-startup-folded 'content))
|
||||
(org-set-startup-visibility))))
|
||||
(add-hook 'read-only-mode-hook #'doom-docs--toggle-read-only-h nil 'local)
|
||||
(org-with-limited-levels
|
||||
(end-of-line)
|
||||
(null (re-search-forward org-outline-regexp-bol nil t))))
|
||||
(add-hook 'read-only-mode-hook #'doom-docs--toggle-read-only-h nil 'local)))
|
||||
|
||||
;;;###autoload
|
||||
(defun doom-docs-read-only-h ()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue