Skip to content

Commit

Permalink
fix build
Browse files Browse the repository at this point in the history
  • Loading branch information
Filip Staffa committed Jan 19, 2024
1 parent c492723 commit 4d5c1d8
Showing 1 changed file with 5 additions and 7 deletions.
12 changes: 5 additions & 7 deletions .github/workflows/dotnetcore.yml
Original file line number Diff line number Diff line change
@@ -1,18 +1,16 @@
name: .NET Core
on:
push:
inputs:
version:
description: "Package Version"
required: true
default: "3.1.0.3-alpha"
workflow_dispatch:
inputs:
version:
description: "Package Version"
required: true
default: "3.1.0.3-alpha"

env:
DEFAULT_VERSION: "3.1.0.3-alpha"

jobs:
build:
runs-on: ubuntu-latest
Expand All @@ -39,7 +37,7 @@ jobs:
- name: Test
run: dotnet test src/PostalCodes.UnitTests/PostalCodes.UnitTests.csproj
- name: Create nuget package
run: dotnet pack . -p:PackageVersion=${{ github.event.inputs.version }} -o out --no-build
run: dotnet pack . -p:PackageVersion=${{ github.event.inputs.version || env.DEFAULT_VERSION }} -o out --no-build
- name: Install dotnet-validate
run: dotnet tool install --global dotnet-validate --version 0.0.1-preview.304

Expand All @@ -48,4 +46,4 @@ jobs:

- name: Publish
run: |
dotnet nuget push src/PostalCodes/PostalCodes.${{ github.event.inputs.version }}.nupkg -k ${{ secrets.NUGET_API_KEY }} -s https://api.nuget.org/v3/index.json
dotnet nuget push src/PostalCodes/PostalCodes.${{ github.event.inputs.version || env.DEFAULT_VERSION }}.nupkg -k ${{ secrets.NUGET_API_KEY }} -s https://api.nuget.org/v3/index.json

0 comments on commit 4d5c1d8

Please sign in to comment.