LaTeX with SublimeText and Skim

 Date: February 27, 2014

SublimeText with LaTeX Tools plugin

Recently I started writing my Master Thesis. I decided I will do it in LaTeX.

I work most of the time on MacBook. The most popular LaTeX distribution for Mac is MacTeX (for Windows: MiKTeX or TeXlive). Once I had this installed I needed editor. First I was using TeXworks, but it is not very decent environment. Nice thing about it is the built-in PDF viewer. Every time I rebuild the document it refresh generated pdf. However, it's hard to manage documents with more than one .tex file. My Master Thesis consists multiple files and I end up editing files in SublimeText and building pdf with TeXworks. Not cool!

Today, one friend of mine showed me application, which detects .pdf updates automatically: Skim. I have also found LaTeXTools plugin for SublimeText. It allows to build .tex document with CMD+B (Mac) or CTRL+B (Windows/Linux). Moreover, Skim can be integrated with SublimeText in such a way that it checks for updates every time, you perform build in SublimeText.

LaTeX + SublimeText + Skim setup

  1. Install LaTeX distribution (for Mac OS X: MacTeX, for Windows: MiKTeX or TeXlive).
  2. Install SublimeText
  3. Install LaTeXTools plugin. With SublimeText Package Control installed: click CMD+SHIFT+P (on Mac) or CTRL+SHIFT+P (Win/Linux). More details can be found here.
    • Mac users: You may need to install 'latexmk': sudo tlmgr install latexmk (more info can be found in LaTeXTools README).
  4. Install Skim (for Windows users: check Sumatra PDF).
  5. In Skim: go to Preferences->Sync and set 'preset' to SublimeText.

Skim preferences

After that you just need to build LaTeX document in SublimeText with CMD+B (Mac) or CTRL+B (Win/Linux). Open the generated .pdf in Skim, then every time you rebuild it in SublimeText - it will be refreshed automatically.

If you have multiple documents add %!TEX root = <master file name> at the beginning of every file.

It is much more convenient than using SublimeText and TeXworks for rebuilding pdf. Additionally, TeXworks' PDF viewer is not very decent.

For LaTeX editing, I have found also TeXstudio. It looks good, but I didn't test it so far.

 Tags:  tools

⏪ Garmin Programming Competition 2014

Sumatra PDF ⏩