You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Add `version-iteration` (false/major/minor/patch) and
`if-no-iterations` (error/pass) inputs to give explicit control over
which intermediate versions are generated during multi-version jumps.
The old `iterate-v0-minors` input is deprecated and mutually exclusive
with `version-iteration`. When neither input is set, the action
preserves the historical v0.x minor iteration behaviour but emits a
deprecation warning asking users to set `version-iteration` explicitly.
The implicit default will change in a future release.
Input resolution order:
1. `version-iteration` set → use it directly; error if
`iterate-v0-minors` is also set (mutually exclusive).
2. `iterate-v0-minors` set → map to the new mode with a deprecation
warning; `if-no-iterations` defaults to "pass" for v0.x.
3. Neither set → backward-compatible default (v0.x minor iteration,
`if-no-iterations` defaults to "pass"); deprecation warning
emitted.
`if-no-iterations` defaults to "error" under explicit
`version-iteration` modes and "pass" under the deprecated and implicit
paths, so existing workflows see no behaviour change. The
empty-versions path now distinguishes error (exit 1,
`migration_ran=false`) from pass (exit 0, `migration_ran=true`), fixing
the downstream labelling/auto-merge flow.
Signed-off-by: Leandro Lucarella <luca-frequenz@llucax.com>
intermediate minors, other bumps target only the new version) and
132
+
emits a deprecation warning — set `version-iteration` explicitly to
133
+
silence the warning. Boundary-only modes can legitimately produce no
134
+
versions when the Dependabot update does not cross that boundary. In
135
+
that case, `if-no-iterations` controls whether the action fails
136
+
(`"error"`) or passes as a no-op migration (`"pass"`). When
137
+
`if-no-iterations` is empty (the default), it uses `"error"` — except
138
+
under the implicit v0.x default and the deprecated
139
+
`iterate-v0-minors` fallback, where it uses `"pass"` for backward
140
+
compatibility.
141
+
120
142
***Exit code** — return **0** if the migration succeeded. Return a
121
143
**non-zero** exit code if manual intervention is needed. A non-zero
122
144
exit causes the action to add the `intervention-pending` label, fail
@@ -233,7 +255,9 @@ jobs:
233
255
| `auto-merge-on-changes` | no | `"false"` | Auto-approve and auto-merge even when the migration produced commits (requires `token`) |
234
256
| `sign-commits` | no | `"false"` | When `"true"`, create migration commits via API so commits have verified signatures (when supported, for example when using a GitHub App for `token`) |
235
257
| `report-title` | no | `""` | Heading used for PR comments and job summaries; when empty, uses the calling workflow title |
236
-
| `iterate-v0-minors` | no | `"true"` | Iterate through intermediate v0.x minor versions |
258
+
| `version-iteration` | no | `""` | Controls generated migration versions: `"false"`runs only the target version; `"major"`, `"minor"`, and `"patch"` iterate semver boundaries. When empty, the action preserves backward-compatible behaviour (v0.x minor iteration) and emits a deprecation warning — set this explicitly to silence the warning. |
259
+
| `if-no-iterations` | no | `""` | What to do when `version-iteration` produces no versions: `"error"`fails the action; `"pass"` treats it as a clean no-op migration. Defaults to `"error"` — except under the implicit v0.x default and the deprecated `iterate-v0-minors` fallback, where it defaults to `"pass"`. |
260
+
| `iterate-v0-minors` | no | `""` | Deprecated; use `version-iteration` instead. When set to "true", v0.x bumps iterate intermediate minor versions; when "false", only the target version is run. When empty (default), the implicit v0.x minor iteration applies instead. Mutually exclusive with `version-iteration`. |
237
261
| `python-version` | no | `"3.14"` | Python version for running the script |
238
262
| `expected-actor` | no | `dependabot[bot]` | GitHub actor whose PRs trigger migration and auto-approval (gates metadata fetch, migration decision, and patch-only auto-approve) |
239
263
| `migrated-label` | no | `migrated` | Label name for migrated state |
@@ -253,9 +277,9 @@ jobs:
253
277
254
278
| Output | Description |
255
279
|---|---|
256
-
| `migration_ran` | Whether the migration script(s) executed |
280
+
| `migration_ran` | Whether migration has been handled: `"true"`when script(s) executed, no versions needed migrating, the PR was already migrated, or the update is patch-only without `version-iteration`; `"false"` otherwise. |
257
281
| `overall_exit` | Consolidated exit code: `"0"`if all scripts succeeded, `"1"` if any required intervention |
258
-
| `needs_migration` | `"true"` for minor/major bumps, `"false"` for patch-only |
282
+
| `needs_migration` | `"true"` for minor/major bumps (always) and patch bumps (when `version-iteration` is set), `"false"` for patch-only without `version-iteration` |
259
283
| `commit_made` | Whether the migration produced a commit |
0 commit comments