-
-
Notifications
You must be signed in to change notification settings - Fork 3
74 lines (60 loc) · 2.98 KB
/
publish.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
name: Publish
on:
release:
types: [published]
jobs:
build:
name: Build
runs-on: ubuntu-latest
permissions:
actions: read
contents: read
security-events: write
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Setup .NET 6.0
uses: actions/setup-dotnet@v4
with:
dotnet-version: 6.x
- name: Setup .NET 7.0
uses: actions/setup-dotnet@v4
with:
dotnet-version: 7.x
- name: Setup .NET 8.0
uses: actions/setup-dotnet@v4
with:
dotnet-version: 8.x
- name: Setup .NET 9.0
uses: actions/setup-dotnet@v4
with:
dotnet-version: 9.x
dotnet-quality: preview
- name: Restore dependencies
run: dotnet restore
- name: Pack ExceptionHandling
run: |
dotnet build ./src/LightResults.Extensions.ExceptionHandling/LightResults.Extensions.ExceptionHandling.csproj --configuration Release --no-restore
dotnet pack ./src/LightResults.Extensions.ExceptionHandling/LightResults.Extensions.ExceptionHandling.csproj --configuration Release --no-build --output .
- name: Pack EntityFrameworkCore
run: |
dotnet build ./src/LightResults.Extensions.EntityFrameworkCore/LightResults.Extensions.EntityFrameworkCore.csproj --configuration Release --no-restore
dotnet pack ./src/LightResults.Extensions.EntityFrameworkCore/LightResults.Extensions.EntityFrameworkCore.csproj --configuration Release --no-build --output .
- name: Pack Json
run: |
dotnet build ./src/LightResults.Extensions.Json/LightResults.Extensions.Json.csproj --configuration Release --no-restore
dotnet pack ./src/LightResults.Extensions.Json/LightResults.Extensions.Json.csproj --configuration Release --no-build --output .
- name: Pack Operations
run: |
dotnet build ./src/LightResults.Extensions.Operations/LightResults.Extensions.Operations.csproj --configuration Release --no-restore
dotnet pack ./src/LightResults.Extensions.Operations/LightResults.Extensions.Operations.csproj --configuration Release --no-build --output .
- name: Pack ValueObjects
run: |
dotnet build ./src/LightResults.Extensions.ValueObjects/LightResults.Extensions.ValueObjects.csproj --configuration Release --no-restore
dotnet pack ./src/LightResults.Extensions.ValueObjects/LightResults.Extensions.ValueObjects.csproj --configuration Release --no-build --output .
- name: Pack GeneratedIdentifier
run: |
dotnet build ./src/LightResults.Extensions.GeneratedIdentifier/LightResults.Extensions.GeneratedIdentifier.csproj --configuration Release --no-restore
dotnet pack ./src/LightResults.Extensions.GeneratedIdentifier/LightResults.Extensions.GeneratedIdentifier.csproj --configuration Release --no-build --output .
- name: Push to NuGet
run: dotnet nuget push "*.nupkg" --api-key ${{secrets.NUGET_API_KEY}} --source https://api.nuget.org/v3/index.json --skip-duplicate