Skip to content

Commit ec852a9

Browse files
committed
Set up CI with Azure Pipelines
[skip ci]
1 parent 424090f commit ec852a9

File tree

1 file changed

+45
-0
lines changed

1 file changed

+45
-0
lines changed

azure-pipelines.yml

Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
# Starter pipeline
2+
# Start with a minimal pipeline that you can customize to build and deploy your code.
3+
# Add steps that build, run tests, deploy, and more:
4+
# https://aka.ms/yaml
5+
6+
trigger:
7+
- master
8+
9+
pool:
10+
vmImage: ubuntu-latest
11+
12+
- task: Bash@3
13+
displayName: 'Generate code'
14+
inputs:
15+
targetType: 'inline'
16+
script: 'dotnet run CodeGen'
17+
failOnStderr: true
18+
- task: PowerShell@2
19+
displayName: 'Build, test, pack'
20+
inputs:
21+
filePath: 'Build/build.ps1'
22+
arguments: '-IncludeWindowsRuntimeComponent -IncludeNanoFramework'
23+
failOnStderr: true
24+
showWarnings: true
25+
pwsh: true
26+
- task: PowerShell@2
27+
inputs:
28+
targetType: 'inline'
29+
failOnStderr: true
30+
showWarnings: true
31+
pwsh: true
32+
script: |
33+
$ProgressPreference = 'SilentlyContinue'
34+
Invoke-WebRequest -Uri https://keybase.io/codecovsecurity/pgp_keys.asc -OutFile codecov.asc
35+
gpg.exe --import codecov.asc
36+
37+
Invoke-WebRequest -Uri https://uploader.codecov.io/latest/windows/codecov.exe -Outfile codecov.exe
38+
Invoke-WebRequest -Uri https://uploader.codecov.io/latest/windows/codecov.exe.SHA256SUM -Outfile codecov.exe.SHA256SUM
39+
Invoke-WebRequest -Uri https://uploader.codecov.io/latest/windows/codecov.exe.SHA256SUM.sig -Outfile codecov.exe.SHA256SUM.sig
40+
41+
gpg.exe --verify codecov.exe.SHA256SUM.sig codecov.exe.SHA256SUM
42+
If ($(Compare-Object -ReferenceObject $(($(certUtil -hashfile codecov.exe SHA256)[1], "codecov.exe") -join " ") -DifferenceObject $(Get-Content codecov.exe.SHA256SUM)).length -eq 0) { echo "SHASUM verified" } Else {exit 1}
43+
44+
.\codecov.exe "Artifacts/Coverage" -t $env:codecov_upload_token
45+

0 commit comments

Comments
 (0)