Skip to content

Instantly share code, notes, and snippets.

Vagrant.configure("2") do |config|
#provider blocks
config.vm.provider :virtualbox do |config, override|
override.vm.box = "opscode-ubuntu-12.04"
override.vm.box_url = "https://opscode-vm.s3.amazonaws.com/vagrant/opscode_ubuntu-12.04_provisionerless.box"
config.vm.network :private_network, ip: "192.168.56.10"
config.customize ["modifyvm", :id, "--memory", 512]
end
Vagrant.configure("2") do |config|
#provider blocks
config.vm.provider :virtualbox do |config, override|
override.vm.box = "opscode-ubuntu-12.04"
override.vm.box_url = "https://opscode-vm.s3.amazonaws.com/vagrant/opscode_ubuntu-12.04_provisionerless.box"
config.vm.network :private_network, ip: "192.168.56.11"
config.customize ["modifyvm", :id, "--memory", 1024]
end
@mattyod
mattyod / get ip
Created December 22, 2014 09:18
ip
ifconfig | grep 'inet' | cut -d: -f2 | awk '{ print $2}'
@mattyod
mattyod / .jshintrc
Created March 12, 2015 10:15
A jshintrc file for Node app
{
"predef": [
],
"node": true,
"bitwise" : true,
"curly" : true,
"eqeqeq" : true,
"forin" : true,
var demethodise = function (fn) {
var curry = [].slice.call(arguments, 1);
return function () {
var args = curry.concat([].slice.call(arguments, 1));
return fn.apply(arguments[0], args);
};
};
'use strict';
var http = require('http'),
fs = require('fs');
var filePath = './feeds/feed.json';
http.createServer(function (req, res) {
var readStream;
@mattyod
mattyod / GoldilocksAndTheThreeBears.js
Created September 20, 2012 11:11
Last night my wife dreamt that I left her because she wouldn't let me read my JavaScript to her. Tonight she gets this...
(function() {
var Bear = function(porridge, chair, bed) {
this.porridge = porridge;
this.chair = chair;
this.bed = bed;
return this;
};
@mattyod
mattyod / default.jade
Created March 22, 2013 14:42
Quick and dirty Jade template example for drmarkpowell
doctype html
head
link(rel='stylesheet', href='css/screen.css')
html
body
article
header
h1 My Schema
span.container {
each property, name in properties
@mattyod
mattyod / arguments
Created April 17, 2013 20:55
f'kin with arguments
function args() {
if (!arguments['0']['2']) {
arguments['0']['2'] = arguments['0']['1'];
}
return arguments;
}
function wrap() {
@mattyod
mattyod / functionalFolly
Created May 19, 2013 21:54
Functional folly
var x, // Give me a value for it to be twoo
method = function (callback) {
callback();
};
var twoo = function () {
console.log('twoo');
};
var fawlse = function () {