#!/bin/sh
rm -rf pdfcpu
mkdir pdfcpu
cd pdfcpu
export GOPATH=`pwd`
#go get -v -d github.com/pdfcpu/pdfcpu/cmd/...
git clone --depth 1 https://github.com/pdfcpu/pdfcpu $GOPATH/src/github.com/pdfcpu/pdfcpu
( cd $GOPATH/src/github.com/pdfcpu/pdfcpu && go get -v -d )
cd ..
chmod -R a+rw pdfcpu
tar cf - --exclude .git --exclude .hg --exclude .svn pdfcpu | xz -9 >pdfcpu-`date '+%Y%m%d'`.tar.xz
rm -rf pdfcpu
