gosora/run-linux-nowebsockets

40 lines
811 B
Plaintext

echo "Deleting artifacts from previous builds"
rm -f template_*.go
rm -f gen_*.go
rm -f tmpl_client/template_*.go
rm -f ./Gosora
echo "Generating the dynamic code"
go generate
echo "Building the router generator"
cd ./router_gen
go build -ldflags="-s -w" -o RouterGen
mv ./RouterGen ..
cd ..
echo "Running the router generator"
./RouterGen
echo "Building the query generator"
cd ./cmd/query_gen
go build -ldflags="-s -w" -o QueryGen
mv ./QueryGen ../..
cd ../..
echo "Running the query generator"
./QueryGen
echo "Generating the JSON handlers"
easyjson -pkg common
echo "Building Gosora"
go build -ldflags="-s -w" -o Gosora -tags no_ws
echo "Building the templates"
./Gosora -build-templates
echo "Building Gosora... Again"
go build -ldflags="-s -w" -o Gosora -tags no_ws
echo "Running Gosora"
./Gosora