-
Notifications
You must be signed in to change notification settings - Fork 2
68 lines (59 loc) · 1.93 KB
/
main.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
64
65
66
67
68
name: main
on:
workflow_dispatch:
inputs:
skip-tests:
description: Skip tests
required: false
default: false
type: boolean
skip-build-app:
description: Skip build-app
required: false
default: false
type: boolean
push:
branches: [main]
pull_request: {}
defaults:
run:
shell: bash --noprofile --norc -x -euo pipefail {0}
jobs:
tests-filter:
name: 'Filter Tests'
uses: ./.github/workflows/filter-on-pr-label-or-input.yml
secrets: inherit
with:
action: 'tests'
skip-non-pr: ${{ inputs.skip-tests }}
build-app-filter:
name: 'Filter Build App'
uses: ./.github/workflows/filter-on-pr-label-or-input.yml
secrets: inherit
with:
action: 'build-app'
skip-non-pr: ${{ inputs.skip-build-app }}
paths-filter:
name: 'Paths Filter'
uses: ./.github/workflows/paths-filter.yml
tests:
name: 'Tests'
needs: [paths-filter, tests-filter]
if: ${{ !inputs.skip-tests && github.event.pull_request.draft != true && needs.paths-filter.outputs.should-test != 'false' && needs.tests-filter.outputs.should-run == 'true' }}
uses: grigorye/ReusableWorkflows/.github/workflows/tests-generic.yml@v24
secrets: inherit
with:
runs-on: 'macos-12'
unit-tests-scheme: 'TMBuddyTests'
snapshot-tests-scheme: 'TMBuddySnapshots'
ui-snapshot-tests-scheme: 'TMBuddyUITestSnapshots'
build-app:
name: 'App'
needs: [paths-filter, build-app-filter]
if: ${{ !inputs.skip-build-app && github.event.pull_request.draft != true && needs.paths-filter.outputs.should-build != 'false' && needs.build-app-filter.outputs.should-run == 'true' }}
uses: grigorye/ReusableWorkflows/.github/workflows/build-app-generic.yml@v24
with:
macos-app-scheme: 'TMBuddy'
build-configs: '["app-store", "developer-id"]'
runs-on: '["macos-12", "build"]'
secrets: inherit