Chore/update deps and runtime #214
Workflow file for this run
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: "Build and Pack" | |
on: | |
push: | |
branches: [ master ] | |
tags: [ v* ] | |
pull_request: | |
branches: [ master ] | |
workflow_dispatch: | |
jobs: | |
build: | |
runs-on: windows-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 | |
with: | |
fetch-depth: 0 | |
- name: Install .NET Core | |
uses: actions/setup-dotnet@3e891b0cb619bf60e2c25674b222b8940e2c1c25 # v4.1.0 | |
with: | |
dotnet-version: 8.0.x | |
- name: Restore Windows | |
run: dotnet restore --runtime=win-x64 | |
- name: Build & Test Windows | |
run: | | |
dotnet build IdlImpTool --no-restore --runtime=win-x64 | |
dotnet test IdlImporterTests | |
- name: Restore Linux | |
run: dotnet restore --runtime=linux-x64 | |
- name: Build Linux | |
run: dotnet build IdlImpTool --no-restore --runtime=linux-x64 | |
- name: Pack IdlImporter (also builds any runtime) | |
run: dotnet pack IDLImporter --include-symbols --no-restore -o . | |
- name: Pack IdlImpTool Everything (also builds any runtime) | |
run: dotnet pack IdlImpTool --include-symbols --no-restore -o . | |
- name: Publish Artifacts | |
uses: actions/upload-artifact@b4b15b8c7c6ac21ea08fcf65892d2ee8f75cf882 # v4.4.3 | |
with: | |
name: NugetPackages | |
path: | | |
./*.nupkg | |
./*.snupkg | |
publish-nuget: | |
name: "Publish NuGet package" | |
runs-on: ubuntu-latest | |
needs: build | |
if: github.event_name == 'push' | |
steps: | |
- name: Download Artifacts | |
uses: actions/download-artifact@fa0a91b85d4f404e444e00e005971372dc801d16 # v4.1.8 | |
with: | |
path: artifacts | |
- name: Publish to Nuget | |
run: dotnet nuget push artifacts/**/*.*nupkg -s https://api.nuget.org/v3/index.json -k ${{secrets.SILLSDEV_PUBLISH_NUGET_ORG}} --skip-duplicate |