Skip to content
Permalink
cfb897a1c0
Switch branches/tags
Go to file
 
 
Cannot retrieve contributors at this time
executable file 18 lines (15 sloc) 376 Bytes
#!/bin/bash
BRANCH=${BRANCH:-$(git branch --show-current)}
TARGET_DOMAIN="$BRANCH--surmblog.netlify.app"
if [ "$BRANCH" = "master" ]; then
TARGET_DOMAIN="surma.dev"
fi
export TARGET_DOMAIN
export BRANCH
PUBLIC_URL=${PUBLIC_URL:-"https://${TARGET_DOMAIN}"}
npx eleventy
(
cd .tmp
npm i
npx parcel build --dist-dir ../_site index.html --public-url "${PUBLIC_URL}"
)