Skip to content

Instantly share code, notes, and snippets.

@processone
processone / strophe.websocket.js
Created December 13, 2010 16:04
Websocket support in strophe.js
/** Class: Strophe.WebSocket
* XMPP Connection manager.
*
* Thie class is the main part of Strophe. It manages a BOSH connection
* to an XMPP server and dispatches events to the user callbacks as
* data arrives. It supports SASL PLAIN, SASL DIGEST-MD5, and legacy
* authentication.
*
* After creating a Strophe.Connection object, the user will typically
* call connect() with a user supplied callback to handle connection level
@zwily
zwily / inputPlugin.js
Last active October 12, 2015 15:48
inputPlugin for LimeChat
// Save this file as: ~/Library/Application Support/LimeChat/inputPlugin.js
// And download this version of LimeChat that supports inputPlugin.js:
// http://cl.ly/0h3B3t3a3H3L
//
// That build of LimeChat includes this commit:
// https://github.com/zwily/limechat/commit/db1cdee2a4b90c3bc2e4956794d92f42a7264193
//
// Shortens URLs that look like graphite using goo.gl. This could
// also be more generic, and just shortens any long URL (that will
// probably end up in a line being split by limechat to get around
## Puts a big annoying arrow in your window when you're not scrolled down, like a dummy
#
scrollAlert = $("<div style='position: fixed; z-index: 10000; bottom: -10px; left: 10px; font-size: 10em; opacity: 0.5'>⬇</div>")
count = $("<div style='position: fixed; z-index: 10000; bottom: -50px; left: 50px; color: #fff'></div>")
lineCount = 0
showing = false
body = $ document.body
win = $ window
@zwily
zwily / straitjacket.md
Last active December 14, 2015 12:39
Straitjacket quickstart.

Getting Started with the StraitJacket AMI

Create a security group:

ec2-create-group straitjacket -d "straitjacket testing"
GROUP	sg-dc1cf8b7	straitjacket	straitjacket testing