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 42K
  • Win 18K
  • OS X 16K
  • Linux 7K
Dec 15 Dec 14 Dec 13 Dec 12 Dec 11 Dec 10 Dec 9 Dec 8 Dec 7 Dec 6 Dec 5 Dec 4 Dec 3 Dec 2 Dec 1 Nov 30 Nov 29 Nov 28 Nov 27 Nov 26 Nov 25 Nov 24 Nov 23 Nov 22 Nov 21 Nov 20 Nov 19 Nov 18 Nov 17 Nov 16 Nov 15 Nov 14 Nov 13 Nov 12 Nov 11 Nov 10 Nov 9 Nov 8 Nov 7 Nov 6 Nov 5 Nov 4 Nov 3 Nov 2 Nov 1 Oct 31
Windows 0 53 47 44 51 27 25 39 31 47 37 59 30 27 48 42 39 46 52 21 31 42 38 46 37 39 27 35 52 54 55 55 57 28 21 44 42 67 44 44 36 28 57 43 47 53
OS X 0 33 43 34 40 17 22 32 34 36 49 38 18 16 21 36 49 47 39 17 16 20 30 43 41 40 17 23 31 26 48 36 50 20 16 41 38 35 52 33 26 20 37 48 40 36
Linux 0 16 27 23 19 12 6 9 16 16 18 15 11 16 15 16 18 13 12 10 17 21 10 24 14 16 14 12 13 17 21 19 23 10 11 10 30 17 17 19 10 11 16 17 15 17

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.