Skip to content

Release script improvements#8641

Open
pbrezina wants to merge 9 commits intoSSSD:masterfrom
pbrezina:rn
Open

Release script improvements#8641
pbrezina wants to merge 9 commits intoSSSD:masterfrom
pbrezina:rn

Conversation

@pbrezina
Copy link
Copy Markdown
Member

@pbrezina pbrezina commented Apr 24, 2026

Few commits to simplify the release process - automate even more things.

Copy link
Copy Markdown

@gemini-code-assist gemini-code-assist Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request updates the release script to use the specific version tag instead of HEAD when generating release notes. A review comment identifies that while the pull request description mentions a new dependency on jq, the corresponding prerequisite check is missing from the script, which could lead to runtime failures.

Comment thread scripts/release.sh Outdated
@pbrezina pbrezina changed the title rn scripts: use version instead of HEAD as the target commit Apr 24, 2026
@pbrezina pbrezina changed the title scripts: use version instead of HEAD as the target commit Release script improvements Apr 29, 2026
@pbrezina
Copy link
Copy Markdown
Member Author

/gemini The contents of this PR has changed dramatically. Re-review.

Copy link
Copy Markdown

@gemini-code-assist gemini-code-assist Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request enhances the release automation scripts by introducing automatic stable branch creation and backport label generation when releasing from the master branch. It also refines the version calculation logic and ensures release notes are generated against specific version tags rather than the HEAD. Review feedback highlighted a bug in the version calculation for major releases (X.0.0) and suggested making the label creation step idempotent to prevent script failures on re-runs.

Comment thread scripts/release.sh Outdated
Comment thread scripts/release.sh Outdated
While HEAD is identical to VERSION (version tag == HEAD), we want to use
the tag identifier to show it in the release notes in the git shortlog
command.
@pbrezina
Copy link
Copy Markdown
Member Author

/gemini review again, I fixed your comments

Copy link
Copy Markdown

@gemini-code-assist gemini-code-assist Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request automates several steps in the release process, including the calculation of previous versions, determination of stable branch names, and the creation of backport labels. It also updates the release notes template with instructions for contributors on using suggestions and squashing commits. Review feedback identifies a potential bug in label existence checking due to substring matching and suggests refactoring a dense conditional to improve code readability.

Comment thread scripts/release.sh Outdated
Comment thread scripts/release.sh
@pbrezina
Copy link
Copy Markdown
Member Author

/gemini review again, I fixed your comments

Copy link
Copy Markdown

@gemini-code-assist gemini-code-assist Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request automates several steps in the release process, including the determination of the previous version tag, the creation of stable branches, and the generation of backport labels. It also adds instructional tips to the release notes template. Feedback was provided to improve the version detection logic for minor releases, add validation for the detected previous version, and ensure all tags are fetched to prevent issues in environments with shallow checkouts.

Comment thread scripts/release.sh
Comment thread scripts/release.sh
Comment thread scripts/release.sh Outdated
Instead of requiring the previous version as a parameter, derive it
from the release version: X.Y.0 → X.(Y-1).0, X.Y.Z → X.Y.(Z-1).
When releasing from master, automatically create the sssd-X-Y stable
branch from the release tag and a backport-to-sssd-X-Y GitHub label.
Add a workflow_dispatch choice parameter (auto/no) to control whether
a stable branch and backport label are created. Default "auto" creates
them only when releasing from master.
Use the git_remote variable instead of hardcoded "origin" to be
consistent with the push commands.
If this step fails, we ensure that no changes were pushed so far.
@pbrezina
Copy link
Copy Markdown
Member Author

/gemini review again, I fixed your comments

Copy link
Copy Markdown

@gemini-code-assist gemini-code-assist Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request automates several release tasks, such as calculating the previous version, creating stable branches, and setting up backport labels. It also updates documentation to encourage the use of GitHub suggestions. Feedback indicates that the logic for determining the previous version is fragile and should instead rely on querying existing tags. Furthermore, the script should ensure tags are fetched before attempting to identify the previous version to avoid using stale data.

Comment thread scripts/release.sh
Comment thread scripts/release.sh
@alexey-tikhonov alexey-tikhonov self-requested a review April 30, 2026 12:39
@alexey-tikhonov alexey-tikhonov self-assigned this Apr 30, 2026
@alexey-tikhonov alexey-tikhonov added the no-backport This should go to target branch only. label Apr 30, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

no-backport This should go to target branch only.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants