Skip to content

fix: allow autobump for Non Conditional %{dist} Releases#179

Merged
reubeno merged 1 commit into
microsoft:mainfrom
MadhurAggarwal:madagg/allow-nonconditional-dist-autobump
May 12, 2026
Merged

fix: allow autobump for Non Conditional %{dist} Releases#179
reubeno merged 1 commit into
microsoft:mainfrom
MadhurAggarwal:madagg/allow-nonconditional-dist-autobump

Conversation

@MadhurAggarwal
Copy link
Copy Markdown
Member

@MadhurAggarwal MadhurAggarwal commented May 12, 2026

Local Build and Unit Test:
image

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Enables azldev’s automatic Release auto-bump logic to handle RPM specs that use a non-conditional dist macro (%{dist}) in addition to the existing conditional form (%{?dist}), aligning behavior with real-world Fedora spec usage.

Changes:

  • Expanded the static Release matching regex to accept both %{?dist} and %{dist} suffixes.
  • Updated unit tests to cover the new accepted %{dist} form (and removed the prior rejection expectation).
  • Updated component release configuration documentation to reflect the newly supported Release formats.

Reviewed changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated no comments.

File Description
internal/app/azldev/core/sources/release.go Broadens staticReleasePattern to allow auto-bumping N%{dist} as well as N%{?dist}.
internal/app/azldev/core/sources/release_test.go Adds acceptance coverage for 1%{dist} in BumpStaticRelease.
internal/app/azldev/core/sources/release_internal_test.go Adds integration-style coverage ensuring tryBumpStaticRelease rewrites Release: 1%{dist} to the bumped value.
docs/user/reference/config/components.md Documents that auto/static modes support static integer releases optionally suffixed by %{?dist} or %{dist}.

@MadhurAggarwal MadhurAggarwal marked this pull request as ready for review May 12, 2026 12:34
@reubeno reubeno merged commit 7508813 into microsoft:main May 12, 2026
20 of 21 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants