-
-
Notifications
You must be signed in to change notification settings - Fork 128
63 lines (54 loc) · 1.3 KB
/
on_push.yml
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
name: "Push"
on:
push:
branches: [main]
pull_request: {}
jobs:
build:
name: Build 🛠️
uses: ./.github/workflows/run_build.yml
package:
name: Package 📦
uses: ./.github/workflows/run_package.yml
needs:
- build
checks:
name: Checks 📋
uses: ./.github/workflows/run_checks.yml
tests:
name: Tests 🧪
uses: ./.github/workflows/run_tests.yml
needs:
- build
docs:
name: Docs 📕
uses: ./.github/workflows/run_docs.yml
success:
name: Pipeline Passed ✅
if: ${{ !cancelled() }}
runs-on: ubuntu-latest
needs:
- build
- package
- checks
- tests
- docs
steps:
- shell: pwsh
run: |
$checks = @{
"Checks" = "${{ needs.checks.result }}"
"Build" = "${{ needs.build.result }}"
"Tests" = "${{ needs.tests.result }}"
"Package" = "${{ needs.package.result }}"
"Docs" = "${{ needs.docs.result }}"
}
$exit = 0
$checks.GetEnumerator() | % {
$status = ($_.Value -eq "success") -or ($_.Value -eq "skipped")
Write-Host "[ $($status ? " OK " : "FAIL") ] $($_.Name)"
if (-not $status) {
$exit = 1
}
}
exit $exit