From f0e838be729d727b2fc74ddbe28014af1804405b Mon Sep 17 00:00:00 2001 From: AeonLucid Date: Fri, 25 Sep 2020 18:52:15 +0200 Subject: [PATCH] Add OSX build for the server and publish single files --- .github/workflows/deploy.yml | 21 +++++++++++++++++++-- .github/workflows/main.yml | 2 +- 2 files changed, 20 insertions(+), 3 deletions(-) diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml index ad8369b..e9a690c 100644 --- a/.github/workflows/deploy.yml +++ b/.github/workflows/deploy.yml @@ -35,7 +35,7 @@ jobs: 7z a -r $GITHUB_WORKSPACE/build/win-x64-client.zip * cd $GITHUB_WORKSPACE - name: Publish Impostor.Server (win-x64) - run: dotnet publish -c release -o ./build/win-x64 -f netcoreapp3.1 -r win-x64 --self-contained --no-restore ./src/Impostor.Server/Impostor.Server.csproj + run: dotnet publish -c release -o ./build/win-x64 -f netcoreapp3.1 -r win-x64 --self-contained --no-restore ./src/Impostor.Server/Impostor.Server.csproj /p:PublishSingleFile=true - name: Zip Impostor.Server (win-x64) shell: bash run: | @@ -43,13 +43,21 @@ jobs: 7z a -r ../win-x64.zip * cd $GITHUB_WORKSPACE - name: Publish Impostor.Server (linux-x64) - run: dotnet publish -c release -o ./build/linux-x64 -f netcoreapp3.1 -r linux-x64 --self-contained --no-restore ./src/Impostor.Server/Impostor.Server.csproj + run: dotnet publish -c release -o ./build/linux-x64 -f netcoreapp3.1 -r linux-x64 --self-contained --no-restore ./src/Impostor.Server/Impostor.Server.csproj /p:PublishSingleFile=true - name: Zip Impostor.Server (linux-x64) shell: bash run: | cd ./build/linux-x64 7z a -r ../linux-x64.zip * cd $GITHUB_WORKSPACE + - name: Publish Impostor.Server (osx-x64) + run: dotnet publish -c release -o ./build/osx-x64 -f netcoreapp3.1 -r osx-x64 --self-contained --no-restore ./src/Impostor.Server/Impostor.Server.csproj /p:PublishSingleFile=true + - name: Zip Impostor.Server (osx-x64) + shell: bash + run: | + cd ./build/osx-x64 + 7z a -r ../osx-x64.zip * + cd $GITHUB_WORKSPACE - name: Create Release id: create_release uses: actions/create-release@v1 @@ -90,4 +98,13 @@ jobs: upload_url: ${{ steps.create_release.outputs.upload_url }} asset_path: ./build/linux-x64.zip asset_name: Impostor-Server-linux-x64.zip + asset_content_type: application/zip + - name: Upload Release Asset (osx-x64) Server + uses: actions/upload-release-asset@v1 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + upload_url: ${{ steps.create_release.outputs.upload_url }} + asset_path: ./build/osx-x64.zip + asset_name: Impostor-Server-osx-x64.zip asset_content_type: application/zip \ No newline at end of file diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 36b89dc..d51ecae 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -32,7 +32,7 @@ jobs: - name: Build Impostor.Client run: msbuild ./src/Impostor.Client/Impostor.Client.csproj /p:Configuration=Release - name: Build Impostor.Server - run: dotnet build --no-restore -c Release -f netcoreapp3.1 ./src/Impostor.Server/Impostor.Server.csproj -p:PublishTrimmed=false + run: dotnet build --no-restore -c Release -f netcoreapp3.1 ./src/Impostor.Server/Impostor.Server.csproj /p:PublishTrimmed=false - name: Test run: dotnet test --no-restore -v normal -f netcoreapp3.1 ./src deploy: -- 2.39.5