Skip to content

Target .NET 10 runtime (#12) #17

Target .NET 10 runtime (#12)

Target .NET 10 runtime (#12) #17

Workflow file for this run

name: release
on:
push:
tags: [ 'v*.*.*' ]
permissions:
id-token: write
contents: write
env:
DOTNET_NOLOGO: 1
DOTNET_CLI_TELEMETRY_OPTOUT: 1
DOTNET_GENERATE_ASPNET_CERTIFICATE: 0
ContinuousIntegrationBuild: true
RestoreLockedMode: true
Configuration: Release
RepositoryBranch: '${{ github.ref_name }}'
RepositoryCommit: '${{ github.sha }}'
jobs:
release:
runs-on: ubuntu-24.04
environment:
name: production
url: https://www.nuget.org/packages/NetOfficeFw.VbaCompression
steps:
- name: checkout
uses: actions/checkout@v5
- name: setup dotnet
uses: actions/setup-dotnet@v5
with:
dotnet-version: 10
- name: restore
run: dotnet restore
- name: build
run: dotnet build --no-restore
- name: test
run: dotnet test --no-build --no-restore
- name: pack
run: dotnet pack --no-build --no-restore -o dist
- name: publish artifact
uses: actions/upload-artifact@v4
with:
name: VbaCompression_packages
path: |
${{ github.workspace }}/dist
${{ github.workspace }}/src/Kavod.Vba.Compression/README.md
- name: authenticate nuget.org
uses: NuGet/login@v1
id: nuget
with:
user: ${{ secrets.NUGET_PUSH_USER }}
- name: publish
working-directory: '${{ github.workspace}}/dist'
run: |
dotnet nuget push "*.nupkg" --api-key "$NUGET_API_KEY" --source https://api.nuget.org/v3/index.json
env:
NUGET_API_KEY: ${{ steps.nuget.outputs.NUGET_API_KEY }}
- name: release
uses: softprops/action-gh-release@v2
if: always() && startsWith(github.ref, 'refs/tags/')
with:
name: 'VbaCompression ${{ github.ref_name }}'
body_path: ${{ github.workspace }}/src/Kavod.Vba.Compression/README.md