1

I am a newbie to Emacs and have just installed GNU Emacs from emacsformacos.com on OSX "El Capitan" but couldn't figure out how to correctly link Mactex 2015 to Emacs.

  • When trying to Latex a tex file I got the following message bash-3.2$ latex \nonstopmode\input test.tex bash: latex: command not found bash-3.2$
  • I have create an .emacs file with the following entry only (setenv "PATH" "/usr/local/bin:/Library/TeX/texbin/:$PATH" t)

It seems latex have successfully created a dvi file. I am not sure how correct is what I did ?

  • How can I do a pdflatex ?
  • Is there a way to configure a shortcut to Latex > Pdf > Preview the results directly.

Thanks in advance for your help.

closed as unclear what you're asking by Romain Picot, Svend Tveskæg, user13907, Mensch, Przemysław Scherwentke Jun 13 '16 at 20:00

Please clarify your specific problem or add additional details to highlight exactly what you need. As it's currently written, it’s hard to tell exactly what you're asking. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.

  • Welcome to this forum, do you have an example of your code? – Arne Timperman Nov 8 '15 at 19:37
  • What version of Emacs/AUCTeX do you have? The relevant variable here is TeX-PDF-mode, but it's default value is t (i.e., use PDF) in recent versions. Also, you may need to (add-to-list 'exec-path "/Library/TeX/texbin"). – Sean Allred Nov 8 '15 at 19:58
  • @Arne I have a very minimal code like \documentclass[12pt]{article} \begin{document} \title{Main Title} \author{{\bf Author}} \maketitle \section{Introduction} Equation can be written as [ s^s+x^2=5, ] \end{document} – fai391 Nov 9 '15 at 4:33
  • @SeanAllred Thanks. Emacs version is GNU Emacs 24.5.1 (x86_64-apple-darwin13.4.0, NS apple-appkit-1265.21) of 2015-04-10 on builder10-9.porkrind.org and Mactex 2015 tug.org/mactex/mactex-download.html – fai391 Nov 9 '15 at 4:37
  • @SeanAllred Here is the result of C-c C-f bash-3.2$ latex \\nonstopmode\\input test.tex This is pdfTeX, Version 3.14159265-2.6-1.40.16 (TeX Live 2015) (preloaded format=latex) restricted \write18 enabled. entering extended mode LaTeX2e <2015/01/01> Babel <3.9l> and hyphenation patterns for 79 languages loaded. (./test.tex (/usr/local/texlive/2015/texmf-dist/tex/latex/base/article.cls Document Class: article 2014/09/29 v1.4h Standard LaTeX document class (/usr/local/texlive/2015/texmf-dist/tex/latex/base/size12.clo)) (./test.aux) [1] (./test.aux) ) Output written on test.dvi – fai391 Nov 9 '15 at 4:42

Browse other questions tagged or ask your own question.