File tree 2 files changed +59
-7
lines changed
2 files changed +59
-7
lines changed Original file line number Diff line number Diff line change @@ -10,16 +10,19 @@ jobs:
10
10
11
11
runs-on : windows-2022
12
12
13
- steps :
14
- - uses : actions/checkout@v1 # https://github.com/actions/checkout
15
- # - name: Setup .NET Core
16
- # uses: actions/setup-dotnet@v1 # https://github.com/actions/setup-dotnet
17
- # with:
18
- # dotnet-version: 3.1.100
13
+ - name : Check out repository
14
+ uses : actions/checkout@v3
15
+
16
+ - name : Set up .NET
17
+ uses : actions/setup-dotnet@v3
18
+ with :
19
+ dotnet-version : ' 8.0.x'
20
+
19
21
- name : Build with dotnet
20
22
run : |
21
23
dotnet build examples/sipexamples/sipexamples.sln --configuration Release
22
24
dotnet build examples/webrtcexamples/webrtcexamples.sln --configuration Release
23
- dotnet build examples/icecmdline/icecmdline .sln --configuration Release
25
+ dotnet build examples/webrtccmdline/webrtccmdline .sln --configuration Release
24
26
dotnet build examples/sipcmdline/sipcmdline.sln --configuration Release
25
27
dotnet build examples/stunserver/stunserver.sln --configuration Release
28
+ dotnet build examples/softphone/sipsorcery.softphone.sln --configuration Release
Original file line number Diff line number Diff line change
1
+ name : Build and Publish
2
+
3
+ on :
4
+ push :
5
+ branches :
6
+ - master
7
+ tags :
8
+ - ' v*' # Triggers on tag pushes starting with 'v'
9
+
10
+ jobs :
11
+ build-and-publish :
12
+ strategy :
13
+ matrix :
14
+ framework : ['net8.0']
15
+ runs-on : ubuntu-latest
16
+ steps :
17
+ # Checkout the repository
18
+ - uses : actions/checkout@v2
19
+
20
+ # Set up .NET SDK
21
+ - uses : actions/setup-dotnet@v2
22
+ with :
23
+ dotnet-version : ' 8.0.x'
24
+
25
+ # Restore dependencies
26
+ - name : Restore dependencies
27
+ run : dotnet restore src/SIPSorcery.csproj
28
+
29
+ # Build the project
30
+ - name : Build
31
+ run : dotnet build src/SIPSorcery.csproj -c Release --no-restore
32
+
33
+ # Run unit tests
34
+ - name : Unit tests
35
+ run : dotnet test test/unit/SIPSorcery.UnitTests.csproj --framework ${{ matrix.framework }} -c Release
36
+
37
+ # Pack the NuGet package
38
+ - name : Pack NuGet package
39
+ run : dotnet pack src/SIPSorcery.csproj -c Release -o ./artifacts
40
+
41
+ # Publish to NuGet
42
+ # - name: Publish NuGet package
43
+ # if: startsWith(github.ref, 'refs/tags/v') # Only run on tag pushes
44
+ # env:
45
+ # NUGET_API_KEY: ${{ secrets.NUGET_API_KEY }} # Set this in your repo settings
46
+ # run: |
47
+ # dotnet nuget push ./artifacts/*.nupkg \
48
+ # --source https://api.nuget.org/v3/index.json \
49
+ # --api-key $NUGET_API_KEY
You can’t perform that action at this time.
0 commit comments