Skip to content

Commit

Permalink
Fixed version bumping
Browse files Browse the repository at this point in the history
  • Loading branch information
herr-bubu committed Mar 5, 2024
1 parent 4822f2c commit 6bee358
Showing 1 changed file with 16 additions and 4 deletions.
20 changes: 16 additions & 4 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -256,18 +256,30 @@ jobs:
node-version: 18
- name: Install tools
run: npm i -g semver
- name: Set up Repository
- name: Configure Git
run: |
npm ci
git config --global user.name "$(git log -1 --pretty=format:'%an')"
git config --global user.email "$(git log -1 --pretty=format:'%ae')"
NEW_SDK_VERSION="$(semver "$(< package.json jq -r '.version')" -i)"
./unifyVersions.js "$NEW_SDK_VERSION"
- name: Create a new branch for version bump
git checkout -b version-bump-"${{ NEW_SDK_VERSION }}"
- name: Bump version and commit
./unifyVersions.js "${{ NEW_SDK_VERSION }}"
npm ci
npm i
git add .
git commit -m "Bump version to $NEW_SDK_VERSION"
git commit -m "Bump version to ${{ NEW_SDK_VERSION }}"
- name: Push Changes
uses: ad-m/github-push-action@master
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
branch: 'main'
- name: Create Pull Request
uses: peter-evans/create-pull-request@v3
with:
commit-message: "Bump version to ${{ NEW_SDK_VERSION }}"
branch: version-bump-"${{ NEW_SDK_VERSION }}"
delete-branch: true
body: "Version bump to ${{ NEW_SDK_VERSION }}"
labels: version-bump
token: ${{ secrets.GITHUB_TOKEN }}

0 comments on commit 6bee358

Please sign in to comment.