forked from m2e-code-quality/m2e-code-quality
-
Notifications
You must be signed in to change notification settings - Fork 0
128 lines (107 loc) · 3.34 KB
/
Copy pathbuild.yml
File metadata and controls
128 lines (107 loc) · 3.34 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
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
name: GitHub CI
on:
push:
branches:
- develop
- '**'
# don't execute push builds for dependabot - these are done with pull requests
- '!dependabot/**'
# gh-pages is something entirely different
- '!gh-pages'
# builds from branch master should not be done. Releases are done with builds from tags
- '!master'
tags:
- '**'
pull_request:
branches:
- develop
- '**'
- '!gh-pages'
jobs:
# verify build on one node before multiple builds on different os are started
fail-fast-build:
name: fail-fast verify (ubuntu-latest, 2022-09)
runs-on: ubuntu-latest
timeout-minutes: 60
steps:
- name: Checkout
uses: actions/checkout@v3
- uses: ./.github/actions/setup
- uses: ./.github/actions/verify
with:
targetPlatform: 2022-09
verify:
needs: fail-fast-build
name: verify (${{ matrix.os }}, ${{ matrix.targetPlatform }})
timeout-minutes: 60
strategy:
matrix:
os: [ ubuntu-latest, windows-latest, macOS-latest ]
targetPlatform: [ 2022-09 ]
exclude:
# exclude the fail-fast-build, which already ran
- os: ubuntu-latest
targetPlatform: 2022-09
fail-fast: true
runs-on: ${{ matrix.os }}
steps:
- name: Checkout
uses: actions/checkout@v3
- uses: ./.github/actions/setup
- uses: ./.github/actions/verify
with:
targetPlatform: ${{ matrix.targetPlatform }}
publish-snapshot-update-site:
needs: verify
if: ${{ github.event_name == 'push' && github.repository == 'm2e-code-quality/m2e-code-quality' && github.ref == 'refs/heads/develop' }}
runs-on: ubuntu-latest
timeout-minutes: 60
steps:
- name: Checkout
uses: actions/checkout@v3
- uses: ./.github/actions/setup
with:
withRuby: 'true'
- uses: ./.github/actions/verify
with:
targetPlatform: 2022-09
keystorePassword: ${{ secrets.KEYSTORE_PASSWORD }}
skipTests: 'true'
- name: Publish update site
shell: bash
run: tools/publish-update-site.sh
env:
SITE_DEPLOY_PRIVATE_KEY: ${{ secrets.SITE_DEPLOY_PRIVATE_KEY }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
release:
needs: verify
if: ${{ github.event_name == 'push' && github.repository == 'm2e-code-quality/m2e-code-quality' && startsWith(github.ref, 'refs/tags/') }}
runs-on: ubuntu-latest
timeout-minutes: 60
steps:
- name: Checkout
uses: actions/checkout@v3
- uses: ./.github/actions/setup
with:
withRuby: 'true'
- name: Prepare release
shell: bash
run: tools/prepare_release.sh
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- uses: ./.github/actions/verify
with:
targetPlatform: 2022-09
keystorePassword: ${{ secrets.KEYSTORE_PASSWORD }}
skipTests: 'true'
- name: Publish update site
shell: bash
run: tools/publish-update-site.sh
env:
SITE_DEPLOY_PRIVATE_KEY: ${{ secrets.SITE_DEPLOY_PRIVATE_KEY }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Publish release
shell: bash
run: tools/release.sh
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}