Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save keeb-zz/6004992 to your computer and use it in GitHub Desktop.
Save keeb-zz/6004992 to your computer and use it in GitHub Desktop.
git pull request cloning and docker build+tests
git config --global --add remote.origin.fetch "+refs/pull/*/head:refs/remotes/origin/pr/*"
export GOPATH=/home/keeb/development/go1.1
export PATH=$GOPATH/bin:$PATH
p=`pwd`
if [ -z "$1" ]; then branch="master"; else branch=$1; fi
rm -rf $GOPATH/src/github.com
mkdir -p $GOPATH/src/github.com/dotcloud
cd $GOPATH/src/github.com/dotcloud
git clone https://github.com/dotcloud/docker -b $branch
cd docker
go get -v github.com/dotcloud/docker/...
go install -v github.com/dotcloud/docker/...
su -c "PATH=$GOPATH/bin:$PATH go test -v"
@keeb-zz
Copy link
Author

keeb-zz commented Jul 16, 2013

This script works only for dotcloud pull requests.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment