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

Add a cron GH workflow that updates a default branch #23

Conversation

sanex3339
Copy link
Collaborator

@sanex3339 sanex3339 commented Mar 10, 2025

Add a cron GH workflow that updates a default branch

  • The workflow is scheduled every hour
  • It uses the value of vars.CURRENT_VERSION that is the org-level variable
  • It checks if a target version branch contains vars.CURRENT_VERSION exists
    • if not - it creates it
  • it checks this target branch is the default branch
    • if not - it makes it as the default branch

How to verify?

  • I used act to test it locally partially.
  • To test it in a real GH environment it should be merged. I will create a repo-level CURRENT_VERSION and will set it to 54 value. After the workflow is triggered and the new release-x.54.x branch is created I will remove it and set the proper release-x.53.x default branch

@sanex3339 sanex3339 added the enhancement New feature or request label Mar 10, 2025
@sanex3339 sanex3339 requested a review from a team March 10, 2025 09:29
@sanex3339 sanex3339 self-assigned this Mar 10, 2025
@sanex3339 sanex3339 force-pushed the emb-239-programmatically-change-a-default-branch-for-a-sample-app branch from 5ad963d to 3270b1e Compare March 10, 2025 09:30
Copy link
Contributor

@heypoom heypoom left a comment

Choose a reason for hiding this comment

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

All the shell commands look good to me 👍🏻

@sanex3339 sanex3339 merged commit 2684648 into main Mar 10, 2025
@sanex3339 sanex3339 deleted the emb-239-programmatically-change-a-default-branch-for-a-sample-app branch March 10, 2025 11:47
sanex3339 added a commit that referenced this pull request Mar 10, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants