Bugfixes (#508) #97
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: OpenPerpetuum Server Compile | |
on: | |
push: | |
branches: [ "Development" ] | |
pull_request: | |
branches: [ "Development" ] | |
workflow_dispatch: | |
inputs: | |
debug_enabled: | |
type: boolean | |
description: 'Run the build with tmate debugging enabled (https://github.com/marketplace/actions/debugging-with-tmate)' | |
required: false | |
default: false | |
jobs: | |
build: | |
strategy: | |
matrix: | |
configuration: [Debug, Release] | |
runs-on: windows-2019 # For a list of available runner types, refer to | |
# https://help.github.com/en/actions/reference/workflow-syntax-for-github-actions#jobsjob_idruns-on | |
env: | |
Solution_Name: Perpetuum.sln # Replace with your solution name, i.e. MyWpfApp.sln. | |
Configuration: ${{ matrix.configuration }} | |
Workspace: ${{ github.workspace }} | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
# Add MSBuild to the PATH: https://github.com/microsoft/setup-msbuild | |
- name: Setup MSBuild.exe | |
uses: microsoft/setup-msbuild@v2 | |
# Restore the application to populate the obj folder with RuntimeIdentifiers | |
- name: Restore&Build the application for (${{ matrix.configuration }}) | |
run: | | |
nuget restore | |
msbuild ${{ env.Solution_Name }} -p:Configuration=${{ env.Configuration }} | |
# Enable tmate debugging of manually-triggered workflows if the input option was provided | |
# this allows us to debug the file paths | |
- name: Setup tmate session | |
uses: mxschmitt/action-tmate@v3 | |
if: ${{ github.event_name == 'workflow_dispatch' && inputs.debug_enabled && always()}} | |
- name: Upload a Build Artifact for (${{ matrix.configuration }}) | |
uses: actions/upload-artifact@v4 | |
with: | |
name: Perpetuum-Server-${{ github.sha }}.${{ matrix.configuration }} | |
path: ${{ env.Workspace }}/bin/x64/${{ env.Configuration }}/Perpetuum.Server | |
if: ${{ github.event_name == 'push'}} |