Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
34 changes: 28 additions & 6 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -179,11 +179,33 @@ jobs:
if: github.event.inputs.dry_run == 'false'
run: |
npx -p @semantic-release/changelog -p @semantic-release/git -p @semantic-release/exec -p semantic-release semantic-release


- name: Updating `stable` branch after release.
update_stable_branch:
name: Update Stable Branch after release
runs-on: ubuntu-latest
needs: release
env:
GITHUB_TOKEN: ${{ github.event.inputs.token }}
GIT_AUTHOR_NAME: feast-ci-bot
GIT_AUTHOR_EMAIL: feast-ci-bot@willem.co
GIT_COMMITTER_NAME: feast-ci-bot
GIT_COMMITTER_EMAIL: feast-ci-bot@willem.co
steps:
- name: Checkout code
uses: actions/checkout@v4
with:
persist-credentials: false

- name: Set up Git credentials
run: |
git config --global user.name "$GIT_AUTHOR_NAME"
git config --global user.email "$GIT_AUTHOR_EMAIL"

- name: Fetch all branches
run: git fetch --all

- name: Reset stable branch to match release branch
run: |
git fetch origin
# note that this checkout creates a branch called `stable` if it does not exist
git checkout -B stable
git reset --hard origin/${GITHUB_REF##*/}
git push -f origin stable
git checkout -B stable origin/${GITHUB_REF#refs/heads/}
git push origin stable --force
Loading