Skip to content

Commit

Permalink
Update setup.sh to always find latest binary release
Browse files Browse the repository at this point in the history
  • Loading branch information
tomtaylor committed Aug 30, 2021
1 parent b5738e9 commit 4f336af
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions setup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@
set -eo pipefail

MOUNT_DIR="/mnt/wof"
WOF_SYNC_OS_POSTCODES_VERSION="0.1.0"

sudo mkdir -p "$MOUNT_DIR"
sudo mount -t tmpfs -o size=90%,nr_inodes=0 wof "$MOUNT_DIR"
Expand All @@ -20,7 +19,9 @@ cd whosonfirst-data-postalcode-gb
git config gc.auto 0
cd ..

curl -L "https://github.com/whosonfirst/wof-sync-os-postcodes/releases/download/v${WOF_SYNC_OS_POSTCODES_VERSION}/wof-sync-os-postcodes_${WOF_SYNC_OS_POSTCODES_VERSION}_linux_x86_64" -o wof-sync-os-postcodes
# Grab the latest release
DOWNLOAD_URL=$(curl -sL wofcurl -sL "https://api.github.com/repos/whosonfirst/wof-sync-os-postcodes/releases/latest" | jq -r '.assets[].browser_download_url' | grep linux_x86_64)
curl -sL "${DOWNLOAD_URL}" -o wof-sync-os-postcodes
chmod +x wof-sync-os-postcodes

git clone https://github.com/whosonfirst/go-whosonfirst-pip-v2
Expand Down

0 comments on commit 4f336af

Please sign in to comment.