Skip to content

Commit f994234

Browse files
authored
ci: dotnet pack release build (#344)
Signed-off-by: Joseph Sawyer <[email protected]>
1 parent 1b5a0a9 commit f994234

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

.github/workflows/ci.yml

+4-4
Original file line numberDiff line numberDiff line change
@@ -39,10 +39,10 @@ jobs:
3939
run: dotnet restore
4040

4141
- name: Build
42-
run: dotnet build --no-restore
42+
run: dotnet build -c Release --no-restore
4343

4444
- name: Test
45-
run: dotnet test --no-build --logger GitHubActions
45+
run: dotnet test -c Release --no-build --logger GitHubActions
4646

4747
packaging:
4848
needs: build
@@ -75,11 +75,11 @@ jobs:
7575

7676
- name: Pack NuGet packages (CI versions)
7777
if: startsWith(github.ref, 'refs/heads/')
78-
run: dotnet pack --no-restore --version-suffix "ci.$(date -u +%Y%m%dT%H%M%S)+sha.${GITHUB_SHA:0:9}"
78+
run: dotnet pack -c Release --no-restore --version-suffix "ci.$(date -u +%Y%m%dT%H%M%S)+sha.${GITHUB_SHA:0:9}"
7979

8080
- name: Pack NuGet packages (PR versions)
8181
if: startsWith(github.ref, 'refs/pull/')
82-
run: dotnet pack --no-restore --version-suffix "pr.$(date -u +%Y%m%dT%H%M%S)+sha.${GITHUB_SHA:0:9}"
82+
run: dotnet pack -c Release --no-restore --version-suffix "pr.$(date -u +%Y%m%dT%H%M%S)+sha.${GITHUB_SHA:0:9}"
8383

8484
- name: Publish NuGet packages (base)
8585
if: github.event.pull_request.head.repo.fork == false

.github/workflows/release.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ jobs:
4444
run: dotnet restore
4545

4646
- name: Pack
47-
run: dotnet pack --no-restore
47+
run: dotnet pack -c Release --no-restore
4848

4949
- name: Publish to Nuget
5050
run: dotnet nuget push "src/**/*.nupkg" --api-key "${{ secrets.NUGET_TOKEN }}" --source https://api.nuget.org/v3/index.json

0 commit comments

Comments
 (0)