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

Mongoose Coffee​Script

by PranavSathy ST3

Better CoffeeScript with Mongoose Snippets & Syntax Highlighting

Details

Installs

  • Total 3K
  • Win 1K
  • Mac 872
  • Linux 710
Dec 22 Dec 21 Dec 20 Dec 19 Dec 18 Dec 17 Dec 16 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
Windows 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Mac 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Linux 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0

Readme

Source
raw.​githubusercontent.​com

Jump to Section

Overview

This package is for Sublime Text 3. There is no support for older versions of Sublime, please feel free to fork and add that support.

** Most of this README is taken directly from Better Coffeescript by aponxi **

Please refer to the original repository @ https://github.com/aponxi/sublime-better-coffeescript to see more elaborate / platform specific instructions, and simply replace the URL of the git repository, and rename “Better CoffeeScript” to “Mongoose CoffeeScript”

Description

Originally cloned from Better Coffeescript by [aponxi] : https://github.com/aponxi/sublime-better-coffeescript . After developing in CoffeeScript for awhile, and utilizing Express.js and Mongoose ODM, I realized that a majority of my RESTful API was several calls to Models and querying and fetching data. I loved Better CoffeeScript, but I realized that it would be even better (for me) if it had syntax highlighting where I utilized my models. So… I decided to pull it and make it seperate.

I hope it comes of use, and if you find any bugs or general enhancements, please report it in the issues page.

Installation

via Package Control

This is the recommended installation method.

If you have Sublime Package Control, you know what to do. If not, well: it's a package manager for Sublime Text 3. Installation guide can be found here. After installing the package manager:

  • Open the Command Pallete (ctrl+shift+P or cmd+shift+P).
  • Type “Install Package” and hit return.
  • Type “Mongoose CoffeeScript” and hit return.

via Source Control

If you plan to contribute, then you should install via this method. Otherwise it is recommended that you install the package via Package Control above

Sublime stores packages in the following locations:

Nix: ~/.config/sublime-text-3/packages
Mac: ~/Library/Application\ Support/Sublime\ Text\ 3/Packages
Win: %APPDATA%\Sublime Text 3\Packages

Open a Terminal/Console and run the following commands, replacing PACKAGE_PATH with the path corresponding to your OS above.

cd PACKAGE_PATH
git clone https://github.com/PranavSathy/sublime-mongoose-coffeescript.git "Mongoose CoffeeScript"

Snippets

  • Use TAB to run a snippet after typing the trigger.
  • Use TAB and shift+TAB to cycle forward/backward through fields.
  • Use ESC to exit snippet mode.

Snippet Triggers

Mongoose

aggregate:  agg
count: cnt
create: crt
discriminator: disc
distinct: dist
ensureIndexes: enin
findById: fbi
findByIdAndRemove: fbir
findByIdAndUpdate: fbiu
findOne: fo
findOneAndRemove: mfor
findOneandUpdate: fou
geoNear: gn
geoSearch: gs
mapReduce: mr

Latest Changelog

v0.1.0 May 16th, 2015

  • Cloned from sublime-better-coffeescript
  • Added mongoose specific Snippets
  • Syntax highlighting for RegEx Model.{mongooseFunc}

Credits

  • As mentioned before, thanks to all the individual contributors of the sublime-better-coffeescript project for making my day that much better, and to [aponxi] himself for the same reason as well.