-
Notifications
You must be signed in to change notification settings - Fork 39
Expand file tree
/
Copy pathbuild.sh
More file actions
35 lines (28 loc) · 848 Bytes
/
build.sh
File metadata and controls
35 lines (28 loc) · 848 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
#!/bin/bash
# Remove old files
rm -f GrayjayDesktop-linux-x64.zip
rm -f GrayjayDesktop-win-x64.zip
# Build front-end
cd Grayjay.Desktop.Web
npm install
rm -rf dist
npm run build
cd ..
runtimes=("win-x64" "linux-x64")
# Loop over each runtime
for runtime in "${runtimes[@]}"
do
echo "Building for $runtime"
# Publish CEF
cd Grayjay.Desktop.CEF
rm -rf bin
dotnet publish -r $runtime -c Release
cd ../Users/koen/projects/Grayjay.Desktop/deploy_linux.sh
# Copy wwwroot
mkdir -p Grayjay.Desktop.CEF/bin/Release/net8.0/$runtime/publish/wwwroot
cp -r Grayjay.Desktop.Web/dist Grayjay.Desktop.CEF/bin/Release/net8.0/$runtime/publish/wwwroot/web
# Create zip
cd Grayjay.Desktop.CEF/bin/Release/net8.0/$runtime/publish
zip -r ../../../../../../GrayjayDesktop-$runtime.zip *
cd ../../../../../..
done