11
11
# This seperates the release process from the test process, so we can still release if we need to and tests are failing
12
12
name : Bump Version
13
13
on :
14
+ push :
15
+ branches :
16
+ - main
17
+ pull_request :
14
18
workflow_dispatch :
15
19
inputs :
16
20
type :
27
31
bump :
28
32
runs-on : ubuntu-latest
29
33
permissions : write-all
34
+ if : github.event_name == 'workflow_dispatch'
30
35
outputs :
31
36
version : ${{ steps.bump.outputs.version }}
32
37
steps :
@@ -52,10 +57,14 @@ jobs:
52
57
matrix :
53
58
target : [aarch64, ppc64]
54
59
needs : [bump]
60
+ if : ${{ always() }}
55
61
steps :
56
62
- uses : actions/checkout@v4
63
+ if : ${{ needs.bump.result == 'success' }}
57
64
with :
58
65
ref : version-${{ needs.bump.outputs.version }}
66
+ - uses : actions/checkout@v4
67
+ if : ${{ needs.bump.result == 'skipped' }}
59
68
60
69
with :
61
70
target : ${{ matrix.target }}
@@ -72,10 +81,14 @@ jobs:
72
81
name : build linux
73
82
runs-on : ubuntu-latest
74
83
needs : [bump]
84
+ if : ${{ always() }}
75
85
steps :
76
86
- uses : actions/checkout@v4
87
+ if : ${{ needs.bump.result == 'success' }}
77
88
with :
78
89
ref : version-${{ needs.bump.outputs.version }}
90
+ - uses : actions/checkout@v4
91
+ if : ${{ needs.bump.result == 'skipped' }}
79
92
- name : Setup QEMU
80
93
uses : docker/setup-qemu-action@v3
81
94
@@ -93,10 +106,14 @@ jobs:
93
106
name : build windows
94
107
runs-on : windows-latest
95
108
needs : [bump]
109
+ if : ${{ always() }}
96
110
steps :
97
111
- uses : actions/checkout@v4
112
+ if : ${{ needs.bump.result == 'success' }}
98
113
with :
99
114
ref : version-${{ needs.bump.outputs.version }}
115
+ - uses : actions/checkout@v4
116
+ if : ${{ needs.bump.result == 'skipped' }}
100
117
101
118
with :
102
119
command : build
@@ -111,10 +128,14 @@ jobs:
111
128
name : build macos
112
129
runs-on : macos-latest
113
130
needs : [bump]
131
+ if : ${{ always() }}
114
132
steps :
115
133
- uses : actions/checkout@v4
134
+ if : ${{ needs.bump.result == 'success' }}
116
135
with :
117
136
ref : version-${{ needs.bump.outputs.version }}
137
+ - uses : actions/checkout@v4
138
+ if : ${{ needs.bump.result == 'skipped' }}
118
139
119
140
with :
120
141
command : build
@@ -130,7 +151,7 @@ jobs:
130
151
name : Release
131
152
runs-on : ubuntu-latest
132
153
if : startsWith(github.ref, 'refs/tags/') || (github.event_name == 'workflow_dispatch')
133
- needs : [macos, windows, linux, linux-cross]
154
+ needs : [macos, windows, linux, linux-cross, bump ]
134
155
steps :
135
156
- uses : actions/download-artifact@v4
136
157
with :
0 commit comments