Skip to content

branch sync: trickle bugfixes up the release branches#112

Merged
oliver-sanders merged 2 commits intocylc:v1from
oliver-sanders:branch-sync++
Aug 4, 2025
Merged

branch sync: trickle bugfixes up the release branches#112
oliver-sanders merged 2 commits intocylc:v1from
oliver-sanders:branch-sync++

Conversation

@oliver-sanders
Copy link
Member

[Low priority until 8.6.0 is released]

It is likely that the 8.6.x branch will continue development post 8.7.0 release, so it's time to exercise our release branch system for real!

At present the branch sync will only sync into master, with this PR it will pick the next sequential release branch instead, defaulting to master once release branches have been exhausted.

Ideally:

  1. When we merge a fix into 8.6.x, we will get a sync PR against 8.7.x.
  2. When we merge that sync PR, we will get another sync PR against master.

I'm not sure whether the (2) will happen automatically or not though?

I'm also not sure how to test this.

@oliver-sanders oliver-sanders requested a review from MetRonnie July 16, 2025 11:09
break
fi
done
echo "BASE_BRANCH=$branch" >> "$GITHUB_OUTPUT"
Copy link
Member

Choose a reason for hiding this comment

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

(1/2) Think we don't need the output

Suggested change
echo "BASE_BRANCH=$branch" >> "$GITHUB_OUTPUT"


- name: Configure git
uses: cylc/release-actions/configure-git@v1
ref: ${{ steps.get-base-branch.BASE_BRANCH }}
Copy link
Member

Choose a reason for hiding this comment

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

(2/2)

Suggested change
ref: ${{ steps.get-base-branch.BASE_BRANCH }}
ref: ${{ env.BASE_BRANCH }}

fi
done
echo "BASE_BRANCH=$branch" >> "$GITHUB_OUTPUT"
echo "BASE_BRANCH=$branch" >> "$GITHUB_ENV"
Copy link
Member

Choose a reason for hiding this comment

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

Mistake? (Credit to GH Copilot for spotting this!)

Suggested change
echo "BASE_BRANCH=$branch" >> "$GITHUB_ENV"
echo "BASE_BRANCH=$base_branch" >> "$GITHUB_ENV"

# * if a change is made to 1.4.x, merge it into master.

# default to the HEAD branch (typically either master or main)
base_branch=$(git remote show origin | sed -n 's/.*HEAD branch: \(.*\)/\1/p')
Copy link
Member

Choose a reason for hiding this comment

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

I also asked Copilot how to do this with GH CLI instead which might be nicer (I've tested it):

gh repo view --json defaultBranchRef -q .defaultBranchRef.name
Suggested change
base_branch=$(git remote show origin | sed -n 's/.*HEAD branch: \(.*\)/\1/p')
base_branch=$(gh repo view --json defaultBranchRef -q .defaultBranchRef.name)

@MetRonnie MetRonnie requested a review from wxtim July 31, 2025 11:01
@MetRonnie MetRonnie added this to the v1 milestone Jul 31, 2025
@MetRonnie MetRonnie removed the request for review from wxtim August 4, 2025 13:35
Copy link
Member

@MetRonnie MetRonnie left a comment

Choose a reason for hiding this comment

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

@oliver-sanders Merge if you're happy with my added commit

@oliver-sanders oliver-sanders merged commit d2f2779 into cylc:v1 Aug 4, 2025
7 checks passed
@oliver-sanders oliver-sanders deleted the branch-sync++ branch August 4, 2025 14:51
This was referenced Aug 12, 2025
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.

2 participants