Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ci: rework release workflow making dev the default branch #9514

Merged
merged 3 commits into from
Jun 10, 2024

Conversation

benelan
Copy link
Member

@benelan benelan commented Jun 4, 2024

Related Issue: #9469 will be closed in favor of this PR

Summary

Make CI changes for a new release workflow that supports hotfixes as patch bumps without causing friction with the versioning and changelog generation setup.

  • All PRs are switched to target the dev branch instead of main
  • When it's time for a release, create a branch off of dev, open a PR targeting main, and use the rebase merge method when installing.
  • Install the Release Please PR generated via the step above, which creates the github releases and git tags on main (where they currently are for all previous releases) and deploys to NPM.
  • Checkout a branch off of and create/install a PR to dev containing the cherry-picked the release commit (changelog and package.json version modifications) from main.
  • Continue development on dev, where next releases are deployed from.
  • Commits for a hotfix get cherry-picked from dev to main as needed.
  • When its time for a hotfix release, install the Release Please PR into main and cherry-pick the release commit back to dev
  • Cycle continues...

Notes

  • The default branch will be changed to dev and main will be our release branch, since that's where all of the tags already exist.
  • We need to rebase merge dev to main due to our changelog generation and versioning setup:
    • squashing won't work, since all of the commits need to be on main
    • a normal merge won't work, since a linear history is required
  • There won't be duplicate commits from syncing back and forth because rebasing automatically drops cherry-picked commits.
  • Unfortunately, GitHub doesn't support per-branch merge methods, so we will need to remember to:
    • enable rebase-merge method in the repo settings

      image

    • switch the method to rebase-merge in the PR when installing changes from dev to main

      image

    • disable rebase-merge in the repo settings

@github-actions github-actions bot added the chore Issues with changes that don't modify src or test files. label Jun 4, 2024
@benelan benelan added the skip visual snapshots Pull requests that do not need visual regression testing. label Jun 4, 2024
Copy link
Contributor

@alisonailea alisonailea left a comment

Choose a reason for hiding this comment

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

we will need to remember to:

  • enable rebase-merge method in the repo settings
  • switch the method to rebase-merge in the PR when installing changes from dev to main
  • disable rebase-merge in the repo settings

Is this documented anywhere?
Otherwise looks good!

Copy link
Member

@jcfranco jcfranco left a comment

Choose a reason for hiding this comment

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

Awesome!

I second @alisonailea's comment. Can you add a note about that to releasing.md?

…orkflow

* origin/main: (26 commits)
  revert: refactor: add simpler `componentFocusable` util (deprecates `LoadableComponent`) (#9515)
  chore(linting): enable selector-pseudo-element-colon-notation rule (#9518)
  refactor(storybook): refactor tooltip simple story interface (#9538)
  refactor(dom): consolidate transition/animation waiting utils (#9341)
  refactor(storybook): build storybook simple story args interfaces using component class (#9457)
  chore: release next
  fix(block): add accessible label for slotted controls (#9502)
  feat(action-bar, action-pad): add expandLabel and collapseLabel to messages (#9497)
  chore: release next
  feat(action-menu, combobox, dropdown, input-date-picker, popover): allow logical placements for flipPlacements property. #8825 (#9490)
  fix(popover): correct border radius on close button (#9485)
  fix(list-item): hide nested list items by default (#9474)
  refactor: move component types into component specific interfaces files (#9527)
  chore: release next
  fix(alert): pause auto-close alert when link focused (#9503)
  refactor(storybook): consolidate storybook and component types (#9500)
  refactor(calcite-block-section,calcite-card): consolidate interfaces imports (#9517)
  chore: release next
  fix(block-section): restore block toggling when clicking on the header switch (#9472)
  chore: release next
  ...
@benelan benelan merged commit d8d1629 into main Jun 10, 2024
9 checks passed
@benelan benelan deleted the benelan/new-release-workflow branch June 10, 2024 09:04
@github-actions github-actions bot added this to the 2024-06-25 - Jun Release milestone Jun 10, 2024
benelan added a commit that referenced this pull request Jun 10, 2024
* origin/dev:
  build(deps): update dependency markdownlint-cli to v0.41.0 (#9531)
  chore: add translations (#9461)
  build(deps): update dependency @whitespace/storybook-addon-html to v6.1.1 (#9510)
  build(deps): update dependency chromatic to v11.5.3 (#9519)
  build(deps): update dependency jsdom to v24.1.0 (#9530)
  build(deps): update dependency semver to v7.6.2 (#9508)
  build(deps): update dependency dayjs to v1.11.11 (#9452)
  build: update browserslist db (#9528)
  build(deps): update dependency @cspell/eslint-plugin to v8.8.4 (#9509)
  build(deps): update dependency quicktype-core to v23.0.170 (#9507)
  fix(combobox): open the component when typing within it (#9543)
  feat(split-button): add placement and flipPlacements property (#9548)
  ci(prerelease): use absolute path to publish script (#9546)
  ci: rework release workflow making dev the default branch (#9514)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
chore Issues with changes that don't modify src or test files. skip visual snapshots Pull requests that do not need visual regression testing.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants