Delete AppVeyor build file #12
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: Compile Program | |
on: | |
release: | |
types: | |
- created | |
push: | |
pull_request: | |
jobs: | |
lint-and-compile: | |
strategy: | |
matrix: | |
configuration: [Debug, Release] | |
runs-on: ubuntu-22.04 | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
- name: Setup .NET | |
uses: actions/[email protected] | |
with: | |
dotnet-version: "6.0.x" | |
- name: Restore NuGet Packages | |
run: dotnet restore ${{ github.event.repository.name }}.sln | |
- name: Patch csproj version | |
uses: justalemon/[email protected] | |
with: | |
version: 2.8.0.${{ github.run_number }} | |
use-tag: true | |
csproj-files: "**/**.csproj" | |
- name: Compile | |
working-directory: ${{ env.GITHUB_WORKSPACE }} | |
run: dotnet build ${{ github.event.repository.name }}.sln -c ${{ matrix.configuration }} | |
- name: Upload Artifact | |
uses: actions/upload-artifact@v3 | |
with: | |
name: ${{ github.event.repository.name }}.${{ matrix.configuration }} | |
path: bin/${{ matrix.configuration }} | |
deploy: | |
runs-on: ubuntu-22.04 | |
if: ${{ github.event_name == 'release' }} | |
needs: | |
- lint-and-compile | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
- name: Setup .NET | |
uses: actions/[email protected] | |
with: | |
dotnet-version: "6.0.x" | |
- name: Download the Artifact | |
uses: actions/download-artifact@v3 | |
with: | |
name: ${{ github.event.repository.name }}.Release | |
path: bin/Release | |
- name: List Everything | |
run: ls -R | |
working-directory: bin/Release | |
- name: Repackage Files | |
run: 7z a ${{ github.event.repository.name }}.zip ${{ github.workspace }}/bin/Release/* | |
- name: Create Release | |
uses: ncipollo/[email protected] | |
with: | |
allowUpdates: true | |
artifactErrorsFailBuild: true | |
artifacts: ${{ github.event.repository.name }}.zip | |
omitBodyDuringUpdate: true | |
omitDraftDuringUpdate: true | |
omitNameDuringUpdate: true | |
omitPrereleaseDuringUpdate: true |