| ⌘T | go to file |
| ⌘⌃P | go to project |
| ⌘R | go to methods |
| ⌃G | go to line |
| ⌘KB | toggle side bar |
| ⌘⇧P | command prompt |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import org.json.*; | |
| import java.net.*; | |
| import java.util.Iterator; | |
| PImage bg; | |
| JSONObject data; | |
| double west = -3.414001; | |
| double east = -3.017120; |
Loosely ordered with the commands I use most towards the top. Sublime also offer full documentation.
| Ctrl+X | delete line |
| Ctrl+↩ | insert line after |
| Ctrl+⇧+↩ | insert line before |
| Ctrl+⇧+↑ | move line (or selection) up |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/sh | |
| #################################### | |
| # Output file for HTML5 video # | |
| # Requirements: # | |
| # - handbrakecli # | |
| # - ffmpeg # | |
| # - ffmpeg2theora # | |
| # # | |
| # usage: # |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env node | |
| var util = require('util'), | |
| http = require('http'), | |
| events = require('events'), | |
| oauth = require('oauth').OAuth, | |
| fs = require("fs"), | |
| crypto = require("crypto"), | |
| ws = require('websocket-server'); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /** | |
| # ms.js | |
| No more painful `setTimeout(60 * 4 * 3 * 2 * 1 * Infinity * NaN * '☃')`. | |
| ms('2d') // 172800000 | |
| ms('1.5h') // 5400000 | |
| ms('1h') // 3600000 | |
| ms('1m') // 60000 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // DNode Session | |
| // ============= | |
| var connect = require('connect') | |
| module.exports = function(opt) { | |
| var key = opt.key || 'connect.sid' | |
| , store = opt.store | |
| , interval = opt.interval || 120000 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // Authentication middleware | |
| // ------------------------- | |
| // Shim for DNode's current version of socket.io, | |
| // which cannot pass `null` references, and turning | |
| // the mongoose model to a pure JSON object | |
| function shim(err, doc, fn) { | |
| if (!err) err = 0 | |
| if (doc) doc = JSON.parse(JSON.stringify(doc)) |