Commit 24ba060
committed
fix(ci): replace hashFiles() job-level if guards with a detect gate job
rust-ci-reusable.yml and elixir-ci-reusable.yml gated their jobs with
`if: ${{ hashFiles('<manifest>') != '' }}` at the JOB level. hashFiles()
needs a checked-out workspace, which does not exist when a job-level `if:`
is evaluated, so GitHub rejects it at the workflow-startup phase — a
startup_failure that has been red on every push (confirmed: the only two
workflows still failing after the YAML/secrets fixes, and the construct
the rust reusable's own header comment flags as a known failure mode).
Replace with the supported pattern: a tiny `detect` job that checks out,
tests for the manifest (Cargo.toml / mix.exs in inputs.working_directory),
and exposes `has_cargo` / `has_mix` as an output the real jobs gate on via
`needs.detect.outputs.*`. Behaviour is preserved (skip the bundle when the
manifest is absent) without the invalid job-level hashFiles().
Consumers pin these reusables by SHA, so existing callers are unaffected
until they bump their pin.1 parent 2880fcb commit 24ba060
2 files changed
Lines changed: 71 additions & 7 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
98 | 98 | | |
99 | 99 | | |
100 | 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 | + | |
| 129 | + | |
| 130 | + | |
| 131 | + | |
101 | 132 | | |
102 | 133 | | |
103 | 134 | | |
104 | | - | |
105 | | - | |
| 135 | + | |
| 136 | + | |
106 | 137 | | |
107 | 138 | | |
108 | 139 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
103 | 103 | | |
104 | 104 | | |
105 | 105 | | |
| 106 | + | |
| 107 | + | |
| 108 | + | |
| 109 | + | |
| 110 | + | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
| 114 | + | |
| 115 | + | |
| 116 | + | |
| 117 | + | |
| 118 | + | |
| 119 | + | |
| 120 | + | |
| 121 | + | |
| 122 | + | |
| 123 | + | |
| 124 | + | |
| 125 | + | |
| 126 | + | |
| 127 | + | |
| 128 | + | |
| 129 | + | |
| 130 | + | |
| 131 | + | |
| 132 | + | |
| 133 | + | |
| 134 | + | |
| 135 | + | |
106 | 136 | | |
107 | 137 | | |
108 | 138 | | |
109 | | - | |
| 139 | + | |
| 140 | + | |
110 | 141 | | |
111 | 142 | | |
112 | 143 | | |
| |||
145 | 176 | | |
146 | 177 | | |
147 | 178 | | |
148 | | - | |
149 | | - | |
| 179 | + | |
| 180 | + | |
150 | 181 | | |
151 | 182 | | |
152 | 183 | | |
| |||
184 | 215 | | |
185 | 216 | | |
186 | 217 | | |
187 | | - | |
| 218 | + | |
| 219 | + | |
188 | 220 | | |
189 | 221 | | |
190 | 222 | | |
| |||
212 | 244 | | |
213 | 245 | | |
214 | 246 | | |
215 | | - | |
| 247 | + | |
| 248 | + | |
216 | 249 | | |
217 | 250 | | |
218 | 251 | | |
| |||
0 commit comments