├── Jade.sublime-build └── README.md /Jade.sublime-build: -------------------------------------------------------------------------------- 1 | { 2 | "cmd": ["jade", "$file", "--pretty"], 3 | "selector": "source.jade", 4 | "osx": {"path": "/usr/local/bin:$PATH"}, 5 | "windows": {"shell": "true"} 6 | } -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | Jade Build for Sublime Text 2 | =========================== 3 | 4 | 5 | Description 6 | ----------- 7 | 8 | Build system for Jade, compiles .jade files into .html files. 9 | 10 | 11 | Prerequisites 12 | ------------- 13 | 14 | Requires **Node.js** & **Jade** libraries. Step by step: 15 | 16 | 1. Install **Node.js** 17 | 18 | Download and install Node.js. You can find it here: 19 | [http://nodejs.org](http://nodejs.org/) . 20 | 21 | Reboot after install it. 22 | 23 | 24 | 2. Install **Jade** 25 | 26 | Open your console and execute the following command: 27 | 28 | * Windows: `npm install jade --global` 29 | 30 | * OS X: `sudo npm install jade --global` 31 | 32 | 33 | Installation 34 | ------------ 35 | 36 | **OPTION 1 - with Package Control (recommended)** 37 | 38 | The easiest way to install this package is through Package Control. 39 | 40 | 1. Install [Package Control](https://sublime.wbond.net/installation), follow instructions on the website. 41 | 42 | 2. Open command panel: `Ctrl+Shift+P` (Linux/Windows) or `Cmd+Shift+P` (OS X) and select **Package Control: Install Package**. 43 | 44 | 3. When packages list appears, type `Jade` and you'll find **Jade Build**, select to install it. 45 | 46 | 47 | **OPTION 2 - with Git** 48 | 49 | Clone the repository in your Sublime Text "Packages" directory: 50 | 51 | ```shell 52 | git clone git://github.com/mutian/Sublime-Jade-Build.git "Jade Build" 53 | ``` 54 | 55 | You can find your "Packages" inside the following directories: 56 | 57 | * OS X: 58 | `~/Library/Application Support/Sublime Text 2/Packages/` 59 | 60 | * Windows: 61 | `%APPDATA%/Sublime Text 2/Packages/` 62 | 63 | * Linux: 64 | `~/.Sublime Text 2/Packages/` 65 | 66 | 67 | **OPTION 3 - without Git** 68 | 69 | Download the latest source zip from [Github](https://github.com/mutian/Sublime-Jade-Build) and extract it into a new folder named `Jade Build` in your Sublime Text "Packages" folder. 70 | 71 | 72 | Usage 73 | ----- 74 | 75 | After installing, you will find a new options in `Tools > Build system` of your Sublime menu: **Jade**. 76 | 77 | Remember, always you can launch the selected build with `Control+B` (Linux/Windows) or `Command+B` (OS X). 78 | 79 | 80 | 81 | Recommendations 82 | --------------- 83 | 84 | * Recommend to use with plugin [Jade](https://github.com/davidrios/jade-tmbundle). 85 | 86 | * Also, I recommend the plugin [SublimeOnSaveBuild](https://github.com/alexnj/SublimeOnSaveBuild), just save your Jade files and transform them into HTML! 87 | 88 | * If you want to change the default folder of your generated HTML files into another one, you can edit the build. 89 | 90 | **Example:** Save your HTML files into a parent `html` folder: 91 | `"cmd": ["jade", "$file", "--out", "../html", "--pretty"],` 92 | 93 | 94 | Author 95 | ------ 96 | 97 | Created by **Mutian** ([http://mutian.wang](http://mutian.wang/)). 98 | 99 | For more info, you can send email to me: mutian(a)me.com! 100 | 101 | 102 | Acknowledgements 103 | ---------------- 104 | 105 | Thanks to the **[RIA Team](http://wbria.com/)** of [Weibo.com](http://weibo.com/) . 106 | --------------------------------------------------------------------------------