Recommended build system for latex? [closed]

2019-01-12 17:53发布

I'm trying to figure out the best build system for latex.

Currently, I use latex-makefile, editing in vim, and viewing changes in Okular or gv. The major problem is that it sometimes gets hides errors on me, and I have to run latex manually. The major advantages are that it does all the iteration I need, and offers both pdf and ps simply.

If you have experience with

  • latex-mk
  • vim-latex
  • kile
  • lyx
  • miktex
  • latex-makefile
  • the ultimate latex makefile
  • rubber
  • any others I havent come across

Would you recommend them, and why/why not?

15条回答
Deceive 欺骗
2楼-- · 2019-01-12 18:04

I've just tried out latexmk. If you do

latexmk -pvc file.tex 

Then it will auto preview (DVI by default).

  • Handles dependencies
  • DVI, ps or pdf
  • Iterates fine.
  • Very configurable, see man latexmk

Downsides:

  • It doesnt condense errors, which isnt hugely useful (workaround: use rubber-info separately)
  • Bug in the man file: "Sometimes a viewer (gv) tries to read an updated .ps or .pdf file after its creation is started but before the file is complete. Work around: manually refresh (or reopen) display.". It would be better if it built it via a temporary .pdf file to avoid this.
  • Not hugely user friendly.
查看更多
smile是对你的礼貌
3楼-- · 2019-01-12 18:04

I'm using MikTeX in combination with TeXnicCenter. It works fine for my purposes. I've never ever had the system hiding errors or warnings. Custom build scripts are easy to create and configure.

查看更多
太酷不给撩
4楼-- · 2019-01-12 18:07

I posted a detailed answer using Scons on tex.stackexchange.

Basically, you put this in a file called SConstruct:

# make sure scons finds tex executables:
import os
env = Environment(ENV=os.environ)
# target and source:
pdf_output = env.PDF(target='main.pdf', source='main.tex')
# make sure that the pdf is reloaded properly (e.g., in Skim)
env.Precious(pdf_output)

You can build the pdf simply by running

scons

Amazingly, scons will detect the changes in the files \included in the main.tex file and also the bibliography file!

查看更多
我只想做你的唯一
5楼-- · 2019-01-12 18:07

Have a look at TeXMaker. :-)

features (from wiki):

  • In-line spell check.
  • A unicode editor to write LaTeX source files (syntax highlighting, undo-redo, search-replace, spell checker...)
  • LaTeX tags and mathematical symbols can be entered with a mouse
  • Document and section templates
  • LaTeX-related programs can be launched
  • BibTeX database management
  • An outline or "structure view"
  • Logfiles during LaTeX compilation and the ability to "step through" source errors that are discovered by the compiler
  • An integrated LaTeX to HTML conversion tool

features (from me):

  • useful wizards for inserting tables, citation, referencing
  • bidirectional support
  • useful keyboard shortcuts
  • Auto Complete words (specially is useful with referencing)
  • define your own instructions
查看更多
我欲成王,谁敢阻挡
6楼-- · 2019-01-12 18:08

AUCTEX & preview-latex with Emacs another option.

You can also have emacs open up the resultant dvi, or pdf file, and if you turn auto-revert-mode on for that buffer, the changes will be rendered everytime you recompile the document.

查看更多
forever°为你锁心
7楼-- · 2019-01-12 18:12

I haven't used it myself, but I've heard of Rubber as a good alternative.

From their website:

Rubber is a program whose purpose is to handle all tasks related to the compilation of LaTeX documents. This includes compiling the document itself, of course, enough times so that all references are defined, and running BibTeX to manage bibliographic references. Automatic execution of dvips to produce PostScript documents is also included, as well as usage of pdfLaTeX to produce PDF documents.

查看更多
登录 后发表回答