Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .github/workflows/go-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,10 @@ on:
description: 'Space-separated list of GitHub login substrings to exclude from the changelog (bot authors). Logins ending in [bot] are always excluded. Extends the default list inside the gptchangelog composite action.'
type: string
default: ''
prerelease_backmerge_sync_enabled:
description: 'Merge main into a prerelease branch (develop/release-candidate) before calculating its next version. Defaults to false (opt-in) — set to true to enable this pre-version-calculation sync, which can skip/block a release on those branches when the merge cannot complete directly. The post-release backmerge on main after a stable release is unaffected by this input either way.'
type: boolean
default: false

# ----------------- Build (build.yml) -----------------
enable_dockerhub:
Expand Down Expand Up @@ -256,6 +260,7 @@ jobs:
enable_major_tag: ${{ inputs.enable_major_tag }}
stable_releases_only: ${{ inputs.stable_releases_only }}
changelog_bot_ignore_list: ${{ inputs.changelog_bot_ignore_list }}
prerelease_backmerge_sync_enabled: ${{ inputs.prerelease_backmerge_sync_enabled }}
shared_paths: ${{ inputs.shared_paths }}
filter_paths: ${{ !inputs.release_single_app && inputs.filter_paths || '' }}
secrets: inherit
Expand Down
7 changes: 6 additions & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -99,6 +99,11 @@ on:
required: false
type: string
default: 'develop,release-candidate'
prerelease_backmerge_sync_enabled:
description: 'Merge backmerge_source into a prerelease branch (see prerelease_branches) before calculating its next version. Independent of backmerge_enabled, which also gates the separate post-release backmerge on backmerge_source itself. Defaults to false (opt-in) — set to true to enable this pre-version-calculation sync, which can skip/block a release on prerelease branches when the merge cannot complete directly. The post-release backmerge on backmerge_source is unaffected by this input either way.'
required: false
type: boolean
default: false

permissions:
contents: read
Expand Down Expand Up @@ -256,7 +261,7 @@ jobs:

- name: Sync ${{ inputs.backmerge_source }} → ${{ github.ref_name }} before calculating version
id: pre_sync
if: inputs.backmerge_enabled && steps.classify.outputs.is_prerelease == 'true'
if: inputs.backmerge_enabled && inputs.prerelease_backmerge_sync_enabled && steps.classify.outputs.is_prerelease == 'true'
uses: LerianStudio/github-actions-shared-workflows/src/config/backmerge-sync@v1
with:
github-token: ${{ steps.app-token.outputs.token }}
Expand Down
2 changes: 2 additions & 0 deletions docs/release-workflow.md
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,8 @@ jobs:
| `backmerge_target` | string | `develop` | Branch that receives the backmerge |
| `backmerge_mode` | string | `direct-with-pr-fallback` | Backmerge strategy: `direct`, `pr`, or `direct-with-pr-fallback` |
| `dry_run` | boolean | `false` | Run semantic-release in dry-run mode (no tags/releases) and preview the backmerge instead of applying it |
| `prerelease_branches` | string | `develop,release-candidate` | Comma-separated list of branches treated as prerelease lines (beta/rc) |
| `prerelease_backmerge_sync_enabled` | boolean | `false` | Merge `backmerge_source` into a prerelease branch before calculating its next version. Independent of `backmerge_enabled`, which also gates the separate post-release backmerge on `backmerge_source` itself. Opt-in — set to `true` to enable this pre-version-calculation sync, which can skip/block a release on prerelease branches when the merge cannot complete directly |

## Secrets

Expand Down
Loading