Skip to content

Commit 0b98707

Browse files
Pack and push to GitHub Package Registry (GPR)
1 parent b05ba80 commit 0b98707

File tree

1 file changed

+15
-0
lines changed

1 file changed

+15
-0
lines changed

.github/workflows/dotnetcore.yml

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,9 @@ jobs:
2121
uses: actions/setup-dotnet@v4
2222
with:
2323
dotnet-version: ${{ matrix.dotnet-version }}
24+
source-url: https://nuget.pkg.github.com/mscraftsman/index.json
25+
env:
26+
NUGET_AUTH_TOKEN: ${{secrets.GITHUB_TOKEN}}
2427
- name: Build
2528
run: |
2629
dotnet build ./GenerativeAI.sln -c Release
@@ -30,3 +33,15 @@ jobs:
3033
# - name: Test Mscc.GenerativeAI.Google
3134
# run: |
3235
# dotnet test ./tests/Mscc.GenerativeAI.Google/Test.Mscc.GenerativeAI.Google.csproj -c Release --logger "console;verbosity=detailed"
36+
- name: Pack for .NET
37+
run: |
38+
dotnet pack -c Release ./src/Mscc.GenerativeAI/Mscc.GenerativeAI.csproj -o output/
39+
- name: Pack for ASP.NET Core
40+
run: |
41+
dotnet pack -c Release ./src/Mscc.GenerativeAI.Web/Mscc.GenerativeAI.Web.csproj -o output/
42+
- name: Pack for .NET using Google Cloud Client Library
43+
run: |
44+
dotnet pack -c Release ./src/Mscc.GenerativeAI.Google/Mscc.GenerativeAI.Google.csproj -o output/
45+
- name: Push to GitHub Package Registry (GPR)
46+
run: |
47+
dotnet nuget push output/*.nupkg --skip-duplicate

0 commit comments

Comments
 (0)