Skip to content

Instantly share code, notes, and snippets.

@tylerflint
tylerflint / gist:1783619
Created February 9, 2012 21:56
WordPress pagoda config file sample
<?php
/**
* The base configurations of the WordPress.
*
* This file has the following configurations: MySQL settings, Table Prefix,
* Secret Keys, WordPress Language, and ABSPATH. You can find more information
* by visiting {@link http://codex.wordpress.org/Editing_wp-config.php Editing
* wp-config.php} Codex page. You can get the MySQL settings from your web host.
*
* This file is used by the wp-config.php creation script during the
@tylerflint
tylerflint / gist:1783606
Created February 9, 2012 21:55
WordPress local config file sample
<?php
/**
* The base configurations of the WordPress.
*
* This file has the following configurations: MySQL settings, Table Prefix,
* Secret Keys, WordPress Language, and ABSPATH. You can find more information
* by visiting {@link http://codex.wordpress.org/Editing_wp-config.php Editing
* wp-config.php} Codex page. You can get the MySQL settings from your web host.
*
* This file is used by the wp-config.php creation script during the
@tylerflint
tylerflint / gist:1783579
Created February 9, 2012 21:50
WordPress config file sample
<?php
/**
* The base configurations of the WordPress.
*
* This file has the following configurations: MySQL settings, Table Prefix,
* Secret Keys, WordPress Language, and ABSPATH. You can find more information
* by visiting {@link http://codex.wordpress.org/Editing_wp-config.php Editing
* wp-config.php} Codex page. You can get the MySQL settings from your web host.
*
* This file is used by the wp-config.php creation script during the
@tylerflint
tylerflint / gist:1713581
Created January 31, 2012 22:50
boxfile with deploy hooks
web1:
after_build:
- "bash < <(curl -s https://raw.github.com/gist/1712751/3cf30e1163b829d1fb38f26d10c0febf3df0a8d2/gistfile1.sh)"
@tylerflint
tylerflint / gist:1712751
Created January 31, 2012 20:36
test deploy 1
echo "hello Braxton sir"
echo
echo "... did Joseph have a heart attack after that burger?"
echo
echo "bye then"
@tylerflint
tylerflint / gist:1691087
Created January 27, 2012 21:45
Middleware API change
Old Way => New Way
/customersubject/registerobserver => /customer/create
/customersubject/unregisterobserver => /customer/delete
/customersubject/setstate => /customer
/itemsubject/registerobserver => /item/create
/itemsubject/unregisterobserver => /item/delete
/itemsubject/setstate => /item
@tylerflint
tylerflint / gist:1690697
Created January 27, 2012 20:17
hacky git extend script
# wrapper to extend/tailor git functionality
git(){
bin=`which git`
if [ $# -lt 1 ] # number of input parameters less than 1
then
$bin
echo
echo "Delorum custom commands:"
echo " c Commit with a simple message"
echo " cn Commit NEW code"
@tylerflint
tylerflint / gist:1650612
Created January 21, 2012 01:19
catalog sorting
unique_id key value
4e1e2de29a86652fda00074f sort_4dfa34a89a8665545200000a 1
4e1e2de29a86652fda00074f sort_4dfa37059a86655455000011 5
4e1e2de19a86652fda00073b sort_4dfa34a89a8665545200000a 2
4e1e2de19a86652fda00073b sort_4dfa4a8e9a866569d700000c 3
To
@tylerflint
tylerflint / gist:1650007
Created January 20, 2012 22:34
node.js 0.6.* cluster raw implementation
var cluster = require("cluster");
var numCPUs = require('os').cpus().length;
var children = [];
var murderedChildren = [];
if (cluster.isMaster) {
log.warn("Master: " + process.pid);
for (var i = 0; i < numCPUs; i++) {
var spawn = cluster.fork();
@tylerflint
tylerflint / gist:1599324
Created January 12, 2012 08:02
Installing RVM

1. install rvm

Install curl as a dependency of the rvm installer:

aptitude install curl

Installing rvm as a multi-user install. This is so that everybody can use the gemsets, however we can also run the rails app as a non root user:

sudo bash < <(curl -sk https://raw.github.com/wayneeseguin/rvm/master/binscripts/rvm-installer )