git clone <repo>
clone the repository specified by ; this is similar to "checkout" in some other version control systems such as Subversion and CVS
Add colors to your ~/.gitconfig file:
#.bashrc | |
alias ber='bundle exec rspec' | |
alias be='bundle exec' | |
export TERM=xterm-256color |
def coin_change(amount, denominations, partial_acc = [], acc = []) | |
denominations.each { |e| | |
acc.push(partial_acc.sort) if amount == 0 | |
if amount - e >= 0 | |
immutable_partial_acc = partial_acc.dup.push(e) | |
coin_change(amount - e, denominations, immutable_partial_acc, acc) | |
end | |
} | |
return acc.uniq | |
end |
[ | |
{ title:'Virtual Panel: Code-to-Test Ratios, TDD and BDD', | |
date: '20/12/2012', | |
ref: 'http://www.infoq.com/articles/virtual-panel-tdd-bdd', | |
description: 'Interview about TDD and BDD to J. B. Rainsberg, Dan North, Gojko Adzic, Ron Jeffries and Steve Freeman', | |
tags: ['article', 'agile', 'testing', 'bdd', 'tdd', 'infoq']}, | |
{ title:"Ten Oddities And Secrets About JavaScript", | |
date: "21/12/2012", | |
ref: "http://coding.smashingmagazine.com/2011/05/30/10-oddities-and-secrets-about-javascript", |
//do to http://www.daft.ie/lettings/ and run: | |
function selectOption(selector, optionsToSelect){ | |
var items = document.querySelectorAll(selector + ' > option'); | |
for (var item of items) { | |
for(var i = 0; i < optionsToSelect.length; i++){ | |
if(item.text.match(optionsToSelect[i]) ){ | |
item.selected = true; | |
console.log(item.text); | |
} |
1. install virtualbox from oracle repo: https://www.virtualbox.org/wiki/Linux_Downloads (disable source repo) | |
2. install linux-headers-generic package | |
3. instal p7zip-full package | |
4. download image from http://www.modern.ie/en-us/virtualization-tools | |
5. 7z e <zipfile> | |
6. import image from virtualbox |
sudo apt-get install xvfb | |
sudo apt-get install firefox | |
xvfb-run cucumber |
autoload -U compinit promptinit | |
compinit | |
promptinit | |
# This will set the default prompt to the walters theme | |
prompt walters | |
autoload -U compinit | |
compinit |
sudo lxc-create -t ubuntu -n wordpress | |
sudo lxc-start -n wordpress | |
#detailed instructions | |
http://ubuntuserverguide.com/2012/05/how-to-install-latest-wordpress-in-ubuntu-server-12-04-lts.html | |
#LAMP | |
sudo apt-get install lamp-server^ | |
sudo apt-get install php5 php5-gd php5-mysql php5-curl php5-cli php5-cgi php5-dev |
#!/bin/sh | |
RUTA_DUMPS="/var/lib/vz/dump/" | |
MAXIMO_COPIAS=5 | |
for VZ_ID in `vzlist -1` ; do | |
VZ_HOSTNAME=`vzlist -o hostname -H ${VZ_ID}` | |
VZ_IP=`vzlist -o ip -H ${VZ_ID}` | |
VZ_DUMP="/var/lib/vz/dump/${VZ_HOSTNAME}_"`date '+%d%m%y%H%M%S'`".tgz" |