-- ---------------------------------------------------------------------------- | |
-- statsd interface for nginx | |
-- (c) 2014 Anton Tolchanov | |
-- https://gist.github.com/knyar/8905045 | |
-- | |
-- Usage: | |
-- 1. install nginx with ngx_lua; | |
-- 2. put this file as statsd.lua somewhere (/var/lib/nginx/lua/ will do); | |
-- 3. initialize stats in init_by_lua: | |
-- http { |
// ==UserScript== | |
// @name 9gag.tv on chromecast | |
// @namespace http://tiago.dalligna.co.uk/ | |
// @version 0.1 | |
// @description watch 9gag.tv in chromecast | |
// @match http://9gag.tv/v/* | |
// @require https://ajax.googleapis.com/ajax/libs/jquery/1.10.2/jquery.min.js | |
// @copyright 2013 Tiago | |
// ==/UserScript== |
This setup aims to create a clean development environment, by keeping development tools and libraries in a virtual machine, separate from the host computer. Separation has several advantages: you can back up the virtual machine, move it to a different host, keep multiple environments around (e.g. for wokring on projects with wildly different dependencies, or upgrading the development toolchain without risking downtime), and base the development environment on a different OS (hello Linux!). Last but not least, it keeps the host machine clean.
The downside is that you're running code inside a VM. You need to log in (we'll use SSH), make sure the code is available and in sync (we'll set up NFS). There's also some I/O overhead, and you need to decide on how much memory, CPU and disk space you allocate to the VM. You can change your mind later, but it's a bit of a hassle to resize virtual disks and partitions.
We assume you're running MacOS and have VMware Fusion already installed
<?php | |
/** | |
* Simple excel writer class with no external dependencies, drop it in and have fun | |
* @author Matt Nowack | |
* @link https://gist.github.com/ihumanable/929039/edit | |
* @license Unlicensed | |
* @version 1.0 | |
*/ | |
class Excel { |