Only install auctex if xelatex is found.
This commit is contained in:
parent
ca12f55334
commit
29b6f5502f
38
init.el
38
init.el
|
@ -1,5 +1,5 @@
|
|||
;;; init.el --- tastytea's Emacs init file.
|
||||
;;; Time-stamp: <2019-04-02 15:16:18 CEST>
|
||||
;;; Time-stamp: <2019-04-03 14:21:51 CEST>
|
||||
|
||||
;;; Commentary:
|
||||
;;; I am using this file with Emacs 26, but most of it will probably work with
|
||||
|
@ -676,24 +676,24 @@
|
|||
(find-file . auto-insert))
|
||||
|
||||
;;;;;;;;;;;;;;;;;;;; LaTeX ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||
(use-package tex-site
|
||||
:if (executable-find "xelatex")
|
||||
:ensure auctex
|
||||
:custom
|
||||
(TeX-parse-self t) ; Enable parse on load.
|
||||
(TeX-auto-save t) ; Enable parse on save
|
||||
(TeX-PDF-mode t) ; PDF mode (rather than DVI-mode)
|
||||
(TeX-engine 'xelatex)
|
||||
;; To use pdf-tools with auctex.
|
||||
;; https://emacs.stackexchange.com/a/21764/21935
|
||||
(TeX-view-program-selection '((output-pdf "PDF Tools")))
|
||||
(TeX-view-program-list '(("PDF Tools" TeX-pdf-tools-sync-view)))
|
||||
:mode
|
||||
("\\.tex\\'" . LaTeX-mode)
|
||||
:config
|
||||
;; To have the buffer refresh after compilation.
|
||||
(add-hook 'TeX-after-compilation-finished-functions
|
||||
#'TeX-revert-document-buffer))
|
||||
(if (executable-find "xelatex")
|
||||
(use-package tex-site
|
||||
:ensure auctex
|
||||
:custom
|
||||
(TeX-parse-self t) ; Enable parse on load.
|
||||
(TeX-auto-save t) ; Enable parse on save
|
||||
(TeX-PDF-mode t) ; PDF mode (rather than DVI-mode)
|
||||
(TeX-engine 'xelatex)
|
||||
;; To use pdf-tools with auctex.
|
||||
;; https://emacs.stackexchange.com/a/21764/21935
|
||||
(TeX-view-program-selection '((output-pdf "PDF Tools")))
|
||||
(TeX-view-program-list '(("PDF Tools" TeX-pdf-tools-sync-view)))
|
||||
:mode
|
||||
("\\.tex\\'" . LaTeX-mode)
|
||||
:config
|
||||
;; To have the buffer refresh after compilation.
|
||||
(add-hook 'TeX-after-compilation-finished-functions
|
||||
#'TeX-revert-document-buffer)))
|
||||
|
||||
;; Auto complete for LaTeX.
|
||||
(use-package company-auctex
|
||||
|
|
Loading…
Reference in New Issue
Block a user