update build.sh

Former-commit-id: 97a6b53ace70ca68880ebc2dc5b5fafd8e8f12a8 [formerly 27d7c953391bafe9bb1139413953419bf87f73a9] [formerly 60a6c7bf2606edfbb2968885db90186926365a5e [formerly 81b1e8d430]]
Former-commit-id: 5c76a0d95d78292c1ef046320f1d889b0caf349e [formerly fe536d54d494d38c38c79465af5acefc91ddbdb0]
Former-commit-id: 8901073c535bc9f1537402fd565324e638a757f3
pull/726/head
Henrique Dias 2017-07-28 11:21:55 +01:00
parent 25c20aaeb2
commit e3c1e11b88
1 changed files with 9 additions and 0 deletions

View File

@ -1,6 +1,15 @@
#!/bin/bash
# Install rice tool if not present
if ! [ -x "$(command -v rice)" ]; then
go get github.com/GeertJohan/go.rice/rice
fi
# Clean the dist folder and build the assets
rm -rf assets/dist
npm run build
# Embed the assets using rice
rice embed-go
cd ./caddy/hugo
rice embed-go