v1.0.78 #9
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: Package and Publish to NuGet | |
on: | |
release: | |
types: [created] | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
permissions: | |
contents: write | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Setup .NET | |
uses: actions/setup-dotnet@v4 | |
with: | |
dotnet-version: 8.0.x | |
- name: Restore dependencies | |
run: dotnet restore | |
- name: Publish | |
run: dotnet publish --no-restore /p:PublicRelease=true | |
- name: Pack | |
run: dotnet pack --no-build /p:PublicRelease=true | |
- name: Push Packages | |
run: dotnet nuget push "**/*.nupkg" --source https://api.nuget.org/v3/index.json --api-key ${{ secrets.NUGET_API_KEY }} --skip-duplicate | |
- name: Create MacOS arm64 Package | |
run: dotnet publish -r osx-arm64 --self-contained true -p:PublishSingleFile=true -p:PublicRelease=true OpenF1.Console/OpenF1.Console.csproj -o osx-arm64-output | |
- name: Upload MacOS arm64 to Release | |
uses: svenstaro/upload-release-action@v2 | |
with: | |
repo_token: ${{ secrets.GITHUB_TOKEN }} | |
file: osx-arm64-output/openf1-console | |
asset_name: openf1-console-macos-arm64 | |
tag: ${{ github.ref }} |