ctrl+shift+p filters: :st2 :st3 :win :osx :linux
Browse

Pug

by davidrios ST2/ST3

A comprehensive textmate / sublime text bundle for the Pug (formerly Jade) template language.

Details

Installs

  • Total 54K
  • Win 24K
  • OS X 20K
  • Linux 10K
Jun 24 Jun 23 Jun 22 Jun 21 Jun 20 Jun 19 Jun 18 Jun 17 Jun 16 Jun 15 Jun 14 Jun 13 Jun 12 Jun 11 Jun 10 Jun 9 Jun 8 Jun 7 Jun 6 Jun 5 Jun 4 Jun 3 Jun 2 Jun 1 May 31 May 30 May 29 May 28 May 27 May 26 May 25 May 24 May 23 May 22 May 21 May 20 May 19 May 18 May 17 May 16 May 15 May 14 May 13 May 12 May 11 May 10
Windows 21 24 33 35 30 30 40 20 22 29 29 21 39 27 31 27 35 14 35 32 46 22 28 30 29 37 36 45 30 18 32 38 53 37 61 28 29 45 43 43 51 48 41 30 51 44
OS X 19 18 14 27 30 35 29 9 9 29 27 22 27 31 15 13 29 6 35 35 35 7 17 32 24 32 28 23 13 14 29 24 33 30 36 14 13 39 36 36 33 36 13 17 28 49
Linux 13 13 21 14 18 16 25 13 7 9 13 10 14 15 10 10 13 12 18 13 21 16 8 22 11 14 12 17 10 6 10 9 9 15 16 11 13 11 13 16 18 20 7 12 19 16

Readme

Source
raw.​githubusercontent.​com

Pug.tmbundle

This was made specifically for Sublime Text 2, but was tested and works with Textmate 2 and Sublime Text 3

A TextMate Bundle for the Pug templating language. Implemented in JSON-tmLanguage, a compiled tmLanguage version is included. All language features that I know of (including some undocumented ones and quircks of the Pug parser) and some indent increase/decrease patterns are implemented.

A test.pug file is included for testing, it is a valid file, so you can compile it with pug to check its output.

A test_errors.pug file is also included for testing some syntax/semantic errors that are highlighted.

A highlighter using Python instead of JavaScript is also included for use with PyPug, you can either manually select Pug (Python) from the syntaxes list or give your file the extension .py.pug to select automatically (only on Sublime Text). Also included is a test.py.pug file that can be compiled with pypug to test it.

Installation

Using Package Control in SUblime Text 2/3

Package control is a package manager for Sublime Text extensions (think of it like “apt-get” for Sublime Text). If you haven't already, install Package Control into your instance of Sublime Text and restart. Choose Package Controll: Install Package (press Ctrl/Cmd + p and then type pi), search for package named Pug and install. Restart if you cannot select “Pug” from syntax highlighter menu.

TextMate 2

mkdir -p ~/Library/Application\ Support/TextMate/Managed/Bundles
cd ~/Library/Application\ Support/TextMate/Managed/Bundles
git clone https://github.com/davidrios/pug-tmbundle.git Pug.tmbundle

Sublime Text manual installation

mkdir -p ~/Library/Application\ Support/Sublime\ Text\ 2/Packages
cd ~/Library/Application\ Support/Sublime\ Text\ 2/Packages
git clone https://github.com/davidrios/pug-tmbundle.git Pug

Replace '2' with '3' in case of Sublime Text 3.

Patches for additions are always welcome.