summaryrefslogtreecommitdiff
path: root/build.sh
blob: ae7e0425e129a19f9bce5145dfe74f6ac145e09c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
#!/bin/sh
name=pengui

rm -rf build
mkdir -p build

cd build
env GOOS=js GOARCH=wasm go build -o $name.wasm ..
cp $(go env GOROOT)/misc/wasm/wasm_exec.js .
cp ../index.html .

[ "$1" = "serve" ] && gopherjs serve