#!/bin/sh
rm -rf asciinema
mkdir asciinema
GOPATH=`pwd`/asciinema
export GOPATH
( mkdir -p $GOPATH/src/github.com/asciinema
  cd $GOPATH/src/github.com/asciinema
  git clone https://github.com/asciinema/asciinema.git
)
(
  cd $GOPATH/src/github.com/asciinema
  go get -v -d ./...
)
tar cvf - --exclude .git asciinema | xz -9 >asciinema-`date '+%Y%m%d'`.tar.xz
