added shell escape toggle for LaTeX to Doom Emacs
This commit is contained in:
+11
@@ -2104,6 +2104,17 @@ This function could also become useful if we ever want to extend the compile com
|
||||
(lambda ()
|
||||
(add-hook 'after-save-hook #'custom-tex-compile nil t)))
|
||||
#+end_src
|
||||
**** Add shell-escape Toggle Command
|
||||
#+begin_src emacs-lisp :tangle ~/.config/doom/config.el
|
||||
(defun TeX-command-toggle-shell-escape ()
|
||||
(interactive)
|
||||
(setq TeX-command-extra-options
|
||||
(cond ((string-match-p "\\_<--shell-escape\\_>" TeX-command-extra-options )
|
||||
(replace-regexp-in-string "\\_<--shell-escape\\_>" "" TeX-command-extra-options))
|
||||
((string-empty-p TeX-command-extra-options)"--shell-escape")
|
||||
(t(format "--shell-escape %s" TeX-command-extra-options))))
|
||||
(message "TeX-command-extra-options : `%s'" TeX-command-extra-options))
|
||||
#+end_src
|
||||
|
||||
*** Org Mode
|
||||
**** Dependencies
|
||||
|
||||
Reference in New Issue
Block a user