diff --git a/config.el b/config.el index 1afdeb1..2fc4ba0 100644 --- a/config.el +++ b/config.el @@ -369,6 +369,22 @@ Bound to cmd+v in org-mode and markdown-mode." ;; Optional: enable booktabs style (horizontal rules in tables) ;; (setq org-latex-tables-booktabs t) +;; macOS: open exported PDF with system 'open' (async → no beachball) +;; Without this, org-open-file may call open synchronously or fail silently. +(when (eq system-type 'darwin) + (setq org-file-apps + '((auto-mode . emacs) + (directory . emacs) + ("\\.mm\\'" . default) + ("\\.x?html?\\'" . default) + ("\\.pdf\\'" . "open %s")))) + +;; Ensure latexmk doesn't hang on errors (nonstopmode + force-continue) +;; Doom latex module usually sets this, but belt+suspenders for macOS. +(after! org + (setq org-latex-pdf-process + '("latexmk -f -pdf -%latex -interaction=nonstopmode -output-directory=%o %f"))) + ;;; ============================================================ ;;; ORG MODE — CUSTOM BEHAVIOR