-
Notifications
You must be signed in to change notification settings - Fork 0
43 lines (34 loc) · 1.11 KB
/
Copy pathci.yml
File metadata and controls
43 lines (34 loc) · 1.11 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
name: CI
on:
push:
branches: [main]
pull_request:
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-dotnet@v4
with:
dotnet-version: 10.0.x
- name: Build 03-dotnet-chat
run: dotnet build 03-dotnet-chat -c Release
- name: Build 04-compose app
run: dotnet build 04-compose/app -c Release
- name: Build 05-blazor-chat
run: dotnet build 05-blazor-chat -c Release
- name: Check shell scripts
run: |
bash -n 01-quickstart/quickstart.sh
bash -n 02-openai-api/curl-examples.sh
- name: Check PowerShell script
shell: pwsh
run: |
$tokens = $null
$errors = $null
[System.Management.Automation.Language.Parser]::ParseFile("01-quickstart/quickstart.ps1", [ref]$tokens, [ref]$errors) | Out-Null
if ($errors.Count -gt 0) { $errors; exit 1 }
- name: Validate compose files
run: |
docker compose -f 04-compose/compose.yaml config
docker compose -f 05-blazor-chat/compose.yaml config