-
-
Notifications
You must be signed in to change notification settings - Fork 0
67 lines (53 loc) · 1.89 KB
/
ci.yml
File metadata and controls
67 lines (53 loc) · 1.89 KB
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
name: CI
on:
push:
branches: [main]
paths:
- 'src/**'
- 'samples/**'
- '.github/workflows/ci.yml'
pull_request:
branches: [main]
paths:
- 'src/**'
- 'samples/**'
- '.github/workflows/ci.yml'
jobs:
build:
runs-on: windows-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup .NET
uses: actions/setup-dotnet@v4
with:
dotnet-version: 8.0.x
- name: Create artifacts directory
run: New-Item -ItemType Directory -Force -Path artifacts/packages
- name: Build SDK
run: dotnet build src/CodingWithCalvin.VsixSdk/CodingWithCalvin.VsixSdk.csproj -c Release
- name: Build Templates
run: dotnet pack src/CodingWithCalvin.VsixSdk.Templates/CodingWithCalvin.VsixSdk.Templates.csproj -c Release
- name: Build Sample Extension
run: dotnet build samples/SampleExtension/SampleExtension.csproj -c Release
- name: Test Template - Install
run: dotnet new install artifacts/packages/CodingWithCalvin.VsixSdk.Templates.1.0.0.nupkg
- name: Test Template - Create Project
run: |
mkdir test-template
cd test-template
dotnet new vsix -n TestExtension --publisher "CI Test"
- name: Test Template - Build Project
run: dotnet build test-template/TestExtension/TestExtension.csproj -c Release
- name: Test Template - Uninstall
run: dotnet new uninstall CodingWithCalvin.VsixSdk.Templates
- name: Upload SDK Package
uses: actions/upload-artifact@v4
with:
name: sdk-package
path: artifacts/packages/CodingWithCalvin.VsixSdk.*.nupkg
- name: Upload Templates Package
uses: actions/upload-artifact@v4
with:
name: templates-package
path: artifacts/packages/CodingWithCalvin.VsixSdk.Templates.*.nupkg