Skip to content

Instantly share code, notes, and snippets.

View emilsundberg's full-sized avatar

Emil Sundberg emilsundberg

View GitHub Profile
@emilsundberg
emilsundberg / test
Created August 26, 2014 14:23
test
# -*- mode: ruby -*-
# vi: set ft=ruby :
# Vagrantfile to install 4-node Openstack Icehouse with puppet master
# Author: Philip Cheong
VAGRANTFILE_API_VERSION = "2"
# Explicitly define all puppet module version for openstack that we want
$install_puppet_modules = <<SCRIPT
/usr/local/bin/puppet module install puppetlabs-openstack --version 4.1.0 --ignore-dependencies --modulepath '/etc/puppetlabs/puppet/modules'
@emilsundberg
emilsundberg / premailer_on_ubuntu.md
Last active October 13, 2016 17:10
Install Premailer and requirements on Ubuntu
  • sudo apt-get install ruby1.9.1-dev
  • sudo gem install nokogiri
  • sudo gem install premailer
  • sudo gem install getopt
@emilsundberg
emilsundberg / gist:536f960f1842f1e7a933
Created June 2, 2014 19:55
Chargify Translation JavaScript
$(document).ready(function(){
function get_value(value)
{
var v = new String(value.match(/[0-9.,]+/));
return Number(v.replace(/[^0-9\.]+/g,""));
}
function remove_numerics(value)
{
<?php
/**
* An helper file for Laravel 4, to provide autocomplete information to your IDE
* Generated with https://github.com/barryvdh/laravel-ide-helper
*
* @author Barry vd. Heuvel <barryvdh@gmail.com>
*/
namespace {
die('Only to be used as an helper for your IDE');
}
<!DOCTYPE html>
<meta charset=UTF-8>
<title>Reverse Vertical Order</title>
<body>
<div>
<div class=bottom>Bottom</div>
<div class=top>Top</div>
</div>
<!DOCTYPE html>
<meta charset=UTF-8>
<title>Reverse Vertical Order</title>
<body>
<div>
<div class=bottom>Bottom</div>
<div class=top>Top</div>
</div>
<!DOCTYPE html>
<meta charset=UTF-8>
<title>Reverse Vertical Order</title>
<body>
<div>
<div class=bottom>Bottom</div>
<div class=top>Top</div>
</div>
<!DOCTYPE html>
<meta charset=UTF-8>
<title>Reverse Vertical Order</title>
<body>
<div>
<div class=bottom>Bottom</div>
<div class=top>Top</div>
</div>