Cosmos-Server/build.sh

18 lines
552 B
Bash
Raw Normal View History

2023-05-03 10:26:40 +00:00
#!/bin/bash
2023-03-25 20:15:00 +00:00
rm -rf build
go build -o build/cosmos src/*.go
if [ $? -ne 0 ]; then
exit 1
fi
2023-03-31 19:19:38 +00:00
cp -r static build/
cp -r GeoLite2-Country.mmdb build/
2023-05-01 10:00:45 +00:00
cp -r Logo.png build/
2023-04-27 18:29:26 +00:00
mkdir build/images
cp client/src/assets/images/icons/cosmos_gray.png build/cosmos_gray.png
cp client/src/assets/images/icons/cosmos_gray.png cosmos_gray.png
2023-03-31 19:19:38 +00:00
echo '{' > build/meta.json
cat package.json | grep -E '"version"' >> build/meta.json
echo ' "buildDate": "'`date`'",' >> build/meta.json
echo ' "built from": "'`hostname`'"' >> build/meta.json
echo '}' >> build/meta.json