Skip to content

Instantly share code, notes, and snippets.

View weissjeffm's full-sized avatar

Jeff Weiss weissjeffm

View GitHub Profile
@weissjeffm
weissjeffm / ci-cloud-install.sh
Created October 31, 2012 19:33 — forked from gstoeckel/ci-cloud-install.sh
Script to provision a VM and install product
#!/bin/bash -x
mkdir -p logs
rm -rf githash buildhash logs/*
wget http://hudson.rhq.lab.eng.bos.redhat.com:8080/hudson/view/katello/job/katello-build/lastSuccessfulBuild/artifact/githash
wget http://hudson.rhq.lab.eng.bos.redhat.com:8080/hudson/view/katello/job/katello-build/lastSuccessfulBuild/artifact/buildhash
#start deltacloud instance
rm -f deltacloud-provision.rb
wget https://raw.github.com/gist/3796321/deltacloud-provision.rb
@weissjeffm
weissjeffm / gist:1316582
Created October 26, 2011 14:51
playing cards
(fn [s]
(let [suit (first s) rank (last s)
st (case suit
\D :diamond
\C :club
\S :spade)
rk (try
(- (Integer/parseInt rank) 2)
(catch NumberFormatException e
(case rank