2014-01-21 20:21:56 -05:00
|
|
|
#!/usr/bin/env bash
|
2014-01-16 00:16:23 -05:00
|
|
|
set -e
|
2013-08-26 18:51:22 -04:00
|
|
|
|
2014-01-16 00:16:23 -05:00
|
|
|
cd "$(dirname "$BASH_SOURCE")/.."
|
2013-12-19 12:01:55 -05:00
|
|
|
|
2014-01-16 00:16:23 -05:00
|
|
|
# Downloads dependencies into vendor/ directory
|
|
|
|
mkdir -p vendor
|
|
|
|
cd vendor
|
|
|
|
|
|
|
|
clone() {
|
|
|
|
vcs=$1
|
|
|
|
pkg=$2
|
|
|
|
rev=$3
|
|
|
|
|
|
|
|
pkg_url=https://$pkg
|
|
|
|
target_dir=src/$pkg
|
|
|
|
|
|
|
|
echo -n "$pkg @ $rev: "
|
|
|
|
|
|
|
|
if [ -d $target_dir ]; then
|
|
|
|
echo -n 'rm old, '
|
|
|
|
rm -fr $target_dir
|
|
|
|
fi
|
|
|
|
|
|
|
|
echo -n 'clone, '
|
|
|
|
case $vcs in
|
|
|
|
git)
|
|
|
|
git clone --quiet --no-checkout $pkg_url $target_dir
|
|
|
|
( cd $target_dir && git reset --quiet --hard $rev )
|
|
|
|
;;
|
|
|
|
hg)
|
|
|
|
hg clone --quiet --updaterev $rev $pkg_url $target_dir
|
|
|
|
;;
|
|
|
|
esac
|
|
|
|
|
|
|
|
echo -n 'rm VCS, '
|
|
|
|
( cd $target_dir && rm -rf .{git,hg} )
|
|
|
|
|
|
|
|
echo done
|
2013-12-19 12:01:55 -05:00
|
|
|
}
|
|
|
|
|
2014-05-20 17:18:52 -04:00
|
|
|
clone git github.com/kr/pty 67e2db24c8
|
2013-08-26 18:51:22 -04:00
|
|
|
|
2014-05-20 17:18:52 -04:00
|
|
|
clone git github.com/gorilla/context b06ed15e1c
|
2013-08-26 18:51:22 -04:00
|
|
|
|
2014-05-20 17:18:52 -04:00
|
|
|
clone git github.com/gorilla/mux 136d54f81f
|
2013-08-26 18:51:22 -04:00
|
|
|
|
2014-05-17 03:51:02 -04:00
|
|
|
clone git github.com/syndtr/gocapability 3c85049eae
|
2013-10-30 23:24:47 -04:00
|
|
|
|
2014-01-16 00:16:23 -05:00
|
|
|
clone hg code.google.com/p/go.net 84a4013f96e0
|
2013-12-19 12:01:55 -05:00
|
|
|
|
2014-01-16 00:16:23 -05:00
|
|
|
clone hg code.google.com/p/gosqlite 74691fb6f837
|
2014-02-13 17:11:39 -05:00
|
|
|
|
|
|
|
# get Go tip's archive/tar, for xattr support
|
|
|
|
# TODO after Go 1.3 drops, bump our minimum supported version and drop this vendored dep
|
2014-05-15 11:18:56 -04:00
|
|
|
clone hg code.google.com/p/go 3458ba248590
|
2014-02-13 17:11:39 -05:00
|
|
|
mv src/code.google.com/p/go/src/pkg/archive/tar tmp-tar
|
|
|
|
rm -rf src/code.google.com/p/go
|
|
|
|
mkdir -p src/code.google.com/p/go/src/pkg/archive
|
|
|
|
mv tmp-tar src/code.google.com/p/go/src/pkg/archive/tar
|
2014-02-21 04:34:06 -05:00
|
|
|
|
2014-05-03 22:34:21 -04:00
|
|
|
clone git github.com/godbus/dbus v1
|
|
|
|
clone git github.com/coreos/go-systemd v1
|