Skip to content

Bump actions/download-artifact from 2 to 4.1.7 in /.github/workflows #88

Bump actions/download-artifact from 2 to 4.1.7 in /.github/workflows

Bump actions/download-artifact from 2 to 4.1.7 in /.github/workflows #88

Workflow file for this run

name: Build
on:
push:
branches: [ master ]
pull_request:
branches: [ master ]
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Setup .NET Core 3.1
uses: actions/setup-dotnet@v1
with:
dotnet-version: 3.1.x
- name: Setup .NET 7.0
uses: actions/setup-dotnet@v1
with:
dotnet-version: 7.0.x
- name: Current directory
run: pwd ; ls
- name: Install dependencies
run: dotnet restore src/TreeBasedCli
- name: Test
run: dotnet test --verbosity normal src/TreeBasedCli.Tests/TreeBasedCli.Tests.csproj
- name: Build
run: dotnet build --configuration Release --no-restore src/TreeBasedCli
pack:
runs-on: ubuntu-latest
needs: build
if: github.event_name == 'push'
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Setup .NET 7.0
uses: actions/setup-dotnet@v1
with:
dotnet-version: 7.0.x
- name: Pack
run: dotnet pack --output ./artifacts --configuration Release src/TreeBasedCli
- uses: actions/upload-artifact@v2
with:
name: artifacts
path: ./artifacts
publish:
runs-on: ubuntu-latest
needs: pack
if: github.event_name == 'push'
steps:
- name: Setup .NET 7.0
uses: actions/setup-dotnet@v1
with:
dotnet-version: 7.0.x
- uses: actions/[email protected]
with:
name: artifacts
path: ./artifacts
- name: Publish packages
run: dotnet nuget push ./artifacts/**/*.nupkg --source nuget.org --api-key ${{secrets.NUGET_API_KEY}} --skip-duplicate