Skip to content

Instantly share code, notes, and snippets.

View rtorr's full-sized avatar

Richard Torruellas rtorr

View GitHub Profile
sudo apt-get update && apt-get install git-core curl build-essential openssl libssl-dev
git clone https://github.com/joyent/node.git
cd node
# 'git tag' shows all available versions: select the latest stable.
git checkout enter-a-version
# Configure seems not to find libssl by default so we give it an explicit pointer.
# Optionally: you can isolate node by adding --prefix=/opt/node
### Keybase proof
I hereby claim:
* I am rtorr on github.
* I am rtorr (https://keybase.io/rtorr) on keybase.
* I have a public key whose fingerprint is CEB1 F420 0388 0950 82E8 4353 B029 B0FB F60B 7F8A
To claim this, I am signing this object:
@rtorr
rtorr / HenrikJoreteg.KeyTreeStore.js
Created June 25, 2014 15:04
Browser standalone ampersand-state
(function(root, factory) {
if (typeof exports !== 'undefined') {
factory(root, exports);
} else {
root.HJ_KeyTreeStore = factory(root, {});
}
}(this, function(root, HJ_KeyTreeStore) {
HJ_KeyTreeStore = function() {
this.storage = {};
};
@rtorr
rtorr / index.js
Created June 30, 2014 19:57
requirebin sketch
var State = require('ampersand-state');
// Create a constructor to represent the state we want to store
var Person = State.extend({
props: {
name: 'string',
isDancing: 'boolean'
}
});
@rtorr
rtorr / index.js
Created June 30, 2014 20:02
requirebin sketch
var State = require('ampersand-state');
// Create a constructor to represent the state we want to store
var Person = State.extend({
props: {
name: 'string',
isDancing: 'boolean'
}
});
@rtorr
rtorr / index.js
Created July 1, 2014 15:29
requirebin sketch
var State = require('ampersand-state');
// Create a constructor to represent the state we want to store
var Person = State.extend({
props: {
name: 'string',
isDancing: 'boolean'
}
});
@rtorr
rtorr / index.js
Created August 10, 2014 19:10
requirebin sketch
var AmpersandState = require('ampersand-state');
var Person = AmpersandState.extend({
props: {
firstName: 'string',
lastName: 'string'
},
session: {
signedIn: ['boolean', true, false],
@rtorr
rtorr / index.js
Created August 10, 2014 19:10
requirebin sketch
var AmpersandState = require('ampersand-state');
var Person = AmpersandState.extend({
props: {
firstName: 'string',
lastName: 'string'
},
session: {
signedIn: ['boolean', true, false],
@rtorr
rtorr / index.js
Created August 10, 2014 19:12
requirebin sketch
var AmpersandState = require('ampersand-state');
var Person = AmpersandState.extend({
props: {
age: {
type: 'number',
test: function(value){
return value % 2 !== 0;
}