Skip to content

Commit a6519d6

Browse files
committed
Replace Azure DevOps pipelines with GitHub Actions
Add CI workflow (build + test on PRs and master pushes) and a publish workflow that pushes to NuGet on GitHub releases. Remove the old Azure DevOps pipeline YAMLs and Cake build scripts which referenced obsolete VM images (ubuntu-16.04, vs2017-win2016). The publish workflow requires a NUGET_API_KEY repository secret. https://claude.ai/code/session_01GqyDyB2zrpxr1ZVw8vFVg3
1 parent 8413a85 commit a6519d6

17 files changed

Lines changed: 60 additions & 593 deletions

.github/workflows/ci.yml

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
name: CI
2+
3+
on:
4+
push:
5+
branches: [master]
6+
pull_request:
7+
branches: [master]
8+
9+
jobs:
10+
build-and-test:
11+
runs-on: ubuntu-latest
12+
13+
steps:
14+
- uses: actions/checkout@v4
15+
16+
- name: Setup .NET
17+
uses: actions/setup-dotnet@v4
18+
with:
19+
dotnet-version: '8.0.x'
20+
21+
- name: Restore dependencies
22+
run: dotnet restore
23+
24+
- name: Build
25+
run: dotnet build --configuration Release --no-restore
26+
27+
- name: Test
28+
run: dotnet test --configuration Release --no-build --verbosity normal

.github/workflows/publish.yml

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
name: Publish to NuGet
2+
3+
on:
4+
release:
5+
types: [published]
6+
7+
jobs:
8+
publish:
9+
runs-on: ubuntu-latest
10+
11+
steps:
12+
- uses: actions/checkout@v4
13+
14+
- name: Setup .NET
15+
uses: actions/setup-dotnet@v4
16+
with:
17+
dotnet-version: '8.0.x'
18+
19+
- name: Restore dependencies
20+
run: dotnet restore
21+
22+
- name: Build
23+
run: dotnet build --configuration Release --no-restore
24+
25+
- name: Test
26+
run: dotnet test --configuration Release --no-build --verbosity normal
27+
28+
- name: Pack
29+
run: dotnet pack src/IpData/IpData.csproj --configuration Release --no-build --output ./nupkg
30+
31+
- name: Publish to NuGet
32+
run: dotnet nuget push ./nupkg/*.nupkg --api-key ${{ secrets.NUGET_API_KEY }} --source https://api.nuget.org/v3/index.json --skip-duplicate

build/azure-devops/gated.yaml

Lines changed: 0 additions & 14 deletions
This file was deleted.

build/azure-devops/outer-loop.yaml

Lines changed: 0 additions & 28 deletions
This file was deleted.

build/cake/Tasks/build.cake

Lines changed: 0 additions & 10 deletions
This file was deleted.

build/cake/Tasks/clean.cake

Lines changed: 0 additions & 23 deletions
This file was deleted.

build/cake/Tasks/create-nuget-package.cake

Lines changed: 0 additions & 16 deletions
This file was deleted.

build/cake/Tasks/default.cake

Lines changed: 0 additions & 22 deletions
This file was deleted.

build/cake/Tasks/publish-nuget-package.cake

Lines changed: 0 additions & 15 deletions
This file was deleted.

build/cake/Tasks/restore-nuget-packages.cake

Lines changed: 0 additions & 5 deletions
This file was deleted.

0 commit comments

Comments
 (0)