2023-06-14 01:51:19 +09:00
|
|
|
# $ErrorActionPreference = 'SilentlyContinue'
|
|
|
|
|
|
2023-06-21 17:14:10 +09:00
|
|
|
$CurBranch = git branch --show-current
|
|
|
|
|
|
|
|
|
|
Remove-Item maingate.zip -Force -Recurse -ErrorAction SilentlyContinue
|
2023-06-14 01:51:19 +09:00
|
|
|
|
|
|
|
|
cd ..
|
|
|
|
|
cd maingate-console
|
|
|
|
|
|
2023-06-21 17:14:10 +09:00
|
|
|
|
|
|
|
|
git switch $CurBranch
|
|
|
|
|
git pull
|
|
|
|
|
npm install
|
2023-06-14 01:51:19 +09:00
|
|
|
npm run build
|
|
|
|
|
|
|
|
|
|
Remove-Item console -Force -Recurse -ErrorAction SilentlyContinue
|
|
|
|
|
Copy-Item build console -Recurse
|
|
|
|
|
|
|
|
|
|
Compress-Archive -Path console -DestinationPath ..\maingate\maingate.zip -Force
|
|
|
|
|
Remove-Item console -Force -Recurse
|
|
|
|
|
|
|
|
|
|
cd ..
|
|
|
|
|
cd maingate
|
|
|
|
|
|
|
|
|
|
$Env:GOOS="linux"
|
|
|
|
|
$Env:GOARCH="amd64"
|
|
|
|
|
go build -ldflags="-s -w" .
|
|
|
|
|
|
|
|
|
|
Compress-Archive -Path maingate -Update -DestinationPath maingate.zip
|
|
|
|
|
Compress-Archive -Path *-firebase-*.json -Update -DestinationPath maingate.zip
|