Skip to content

Commit

Permalink
Merge pull request #475 from EvanNotFound/dev
Browse files Browse the repository at this point in the history
ci: improve release workflow with PR creation
  • Loading branch information
EvanNotFound authored Dec 2, 2024
2 parents 2f94a92 + cdecc01 commit 81da820
Showing 1 changed file with 12 additions and 3 deletions.
15 changes: 12 additions & 3 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -57,9 +57,18 @@ jobs:
git commit -m "chore: bump version to ${VERSION}"
fi
- name: Push changes
- name: Create Pull Request
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
VERSION=$(node -p "require('./package.json').version")
BRANCH="release/v${VERSION}"
git checkout -b $BRANCH
git push -u origin $BRANCH
gh pr create --base main --head $BRANCH --title "Release v${VERSION}" --body "Automated release PR for version ${VERSION}"
- name: Update dev branch
run: |
git push --follow-tags origin main
git checkout dev
git merge main
git merge $BRANCH
git push origin dev

0 comments on commit 81da820

Please sign in to comment.