Skip to content

Commit

Permalink
FIx working directory in workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
FrediKats committed Dec 24, 2023
1 parent 5fadfb1 commit 5264e9b
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 8 deletions.
10 changes: 6 additions & 4 deletions .github/workflows/build-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,10 +17,6 @@ jobs:
build:
runs-on: ubuntu-latest

defaults:
run:
working-directory: ${{ env.working-directory }}

steps:
- run: git config --global core.autocrlf input
- uses: actions/checkout@v3
Expand All @@ -31,10 +27,16 @@ jobs:
dotnet-version: ${{ env.dotnet-version }}

- name: Restore dependencies
run:
working-directory: ${{ env.working-directory }}
run: dotnet restore

- name: Build
run:
working-directory: ${{ env.working-directory }}
run: dotnet build -c Release --no-restore --verbosity normal

- name: Test
run:
working-directory: ${{ env.working-directory }}
run: dotnet test -c Release --no-build --verbosity normal
14 changes: 10 additions & 4 deletions .github/workflows/nuget-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,6 @@ jobs:
build:
runs-on: ubuntu-latest

defaults:
run:
working-directory: ${{ env.working-directory }}

steps:
- run: git config --global core.autocrlf input
- uses: actions/checkout@v3
Expand All @@ -27,16 +23,26 @@ jobs:
dotnet-version: ${{ env.dotnet-version }}

- name: Restore dependencies
run:
working-directory: ${{ env.working-directory }}
run: dotnet restore

- name: Build
run:
working-directory: ${{ env.working-directory }}
run: dotnet build -c Release /p:ContinuousIntegrationBuild=true --no-restore --verbosity normal

- name: Test
run:
working-directory: ${{ env.working-directory }}
run: dotnet test -c Release --no-build --verbosity normal

- name: Publish to Nuget
run:
working-directory: ${{ env.working-directory }}
run: dotnet nuget push ${{ env.release-directory }}/*.nupkg --api-key ${{ secrets.NUGET_API_KEY }} --source https://api.nuget.org/v3/index.json --skip-duplicate

- name: Publish to Nuget symbols
run:
working-directory: ${{ env.working-directory }}
run: dotnet nuget push ${{ env.release-directory }}/*.snupkg --api-key ${{ secrets.NUGET_API_KEY }} --source https://api.nuget.org/v3/index.json --skip-duplicate

0 comments on commit 5264e9b

Please sign in to comment.