Update path to csproj #17
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: release | |
on: | |
push: | |
tags: | |
- 'v*' # This triggers the action on new version tags | |
jobs: | |
build-and-test: | |
uses: ./.github/workflows/build.yml | |
release: | |
runs-on: ubuntu-latest | |
needs: build-and-test | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v4.2.0 | |
- name: Set up .NET | |
uses: actions/setup-dotnet@v4 | |
with: | |
dotnet-version: '9.0.x' | |
- name: Restore dependencies | |
run: dotnet restore | |
- name: Set version | |
run: echo "VERSION=${GITHUB_REF_NAME#v}" >> $GITHUB_ENV | |
- name: Pack .NET tool | |
run: dotnet pack ./src/Dotty.CLI/Dotty.CLI.csproj --configuration Release -p:Version=${{ env.VERSION }} --output ./out --no-restore | |
- name: Publish to NuGet | |
run: dotnet nuget push ./out/*.nupkg --api-key ${{ secrets.NUGET_API_KEY }} --source https://api.nuget.org/v3/index.json |