@@ -26,53 +26,109 @@ jobs:
2626 - name : Test
2727 run : dotnet test -c Release --no-build --verbosity normal
2828
29- publish :
29+ build-artifacts :
3030 needs : build-test
31+ runs-on : ubuntu-latest
32+
33+ steps :
34+ - uses : actions/checkout@v4
35+ with :
36+ fetch-depth : 0
37+ - name : Setup .NET
38+ uses : actions/setup-dotnet@v4
39+ with :
40+ dotnet-version : 9.0.x
41+ - name : Build (Release, Utilities -> SDK -> Contracts)
42+ run : dotnet build OpenAI.Utilities/Betalgo.OpenAI.Utilities.csproj -c Release
43+ - name : Upload release bins
44+ uses : actions/upload-artifact@v4
45+ with :
46+ name : release-bins
47+ path : |
48+ OpenAI.Utilities/bin/Release/
49+ OpenAI.SDK/bin/Release/
50+ Betalgo.Ranul.OpenAI.Contracts/bin/Release/
3151
52+ publish-sdk :
53+ needs : build-artifacts
3254 permissions :
3355 contents : write
3456 packages : write
35-
3657 runs-on : ubuntu-latest
37-
3858 steps :
3959 - uses : actions/checkout@v4
4060 with :
4161 fetch-depth : 0
62+ - name : Download artifacts
63+ uses : actions/download-artifact@v4
64+ with :
65+ name : release-bins
4266 - name : Setup .NET
4367 uses : actions/setup-dotnet@v4
4468 with :
4569 dotnet-version : 9.0.x
46-
47- - name : Restore (publish)
48- run : dotnet restore OpenAI.SDK/Betalgo.Ranul.OpenAI.csproj
49-
50- - name : Build (publish, Release)
51- run : dotnet build OpenAI.SDK/Betalgo.Ranul.OpenAI.csproj -c Release --no-restore
52-
5370 - name : Publish OpenAI
54715572 with :
5673 project-file : OpenAI.SDK/Betalgo.Ranul.OpenAI.csproj
5774 nuget-api-key : ${{ secrets.NUGET_KEY }}
5875 clean : false
76+ no-restore : true
5977 tag-commit : true
6078 tag-format : Betalgo.Ranul.OpenAI-v*
6179
80+ publish-contracts :
81+ needs : build-artifacts
82+ permissions :
83+ contents : write
84+ packages : write
85+ runs-on : ubuntu-latest
86+ steps :
87+ - uses : actions/checkout@v4
88+ with :
89+ fetch-depth : 0
90+ - name : Download artifacts
91+ uses : actions/download-artifact@v4
92+ with :
93+ name : release-bins
94+ - name : Setup .NET
95+ uses : actions/setup-dotnet@v4
96+ with :
97+ dotnet-version : 9.0.x
6298 - name : Publish Contracts
639964100 with :
65101 project-file : Betalgo.Ranul.OpenAI.Contracts/Betalgo.Ranul.OpenAI.Contracts.csproj
66102 nuget-api-key : ${{ secrets.NUGET_KEY }}
67103 clean : false
104+ no-restore : true
68105 tag-commit : true
69106 tag-format : Betalgo.Ranul.OpenAI.Contracts-v*
70107
108+ publish-utilities :
109+ needs : build-artifacts
110+ permissions :
111+ contents : write
112+ packages : write
113+ runs-on : ubuntu-latest
114+ steps :
115+ - uses : actions/checkout@v4
116+ with :
117+ fetch-depth : 0
118+ - name : Download artifacts
119+ uses : actions/download-artifact@v4
120+ with :
121+ name : release-bins
122+ - name : Setup .NET
123+ uses : actions/setup-dotnet@v4
124+ with :
125+ dotnet-version : 9.0.x
71126 - name : Publish OpenAI Utilities
7212773128 with :
74129 project-file : OpenAI.Utilities/Betalgo.OpenAI.Utilities.csproj
75130 nuget-api-key : ${{ secrets.NUGET_KEY_UTILITIES }}
76131 clean : false
132+ no-restore : true
77133 tag-commit : true
78134 tag-format : Betalgo.OpenAI.Utilities-v*
0 commit comments