"Queuecaster" feature enhancement #244
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: .NET | |
on: | |
push: | |
branches: [ main ] | |
pull_request: | |
branches: [ main ] | |
release: | |
types: [published] | |
workflow_dispatch: | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Setup .NET | |
uses: actions/setup-dotnet@v1 | |
with: | |
dotnet-version: 6.0.x | |
- name: Restore dependencies | |
run: dotnet restore SharpCaster.sln | |
- name: tag | |
id: tag | |
run: | | |
version="$(gh release view -q .name --json name)" | |
echo 'VERSION='$version >> $GITHUB_ENV | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
- name: Build | |
run: dotnet build --no-restore --configuration Release /p:Version=$VERSION SharpCaster.sln | |
- name: Package | |
run: dotnet pack --configuration Release /p:Version=$VERSION Sharpcaster/Sharpcaster.csproj | |
- name: Push | |
if: github.event_name == 'release' && github.event.action == 'published' | |
run: dotnet nuget push "**/*.nupkg" -k $NUGET_AUTH_TOKEN -s nuget.org | |
env: | |
NUGET_AUTH_TOKEN: ${{ secrets.NUGET }} |