Skip to content

Version 0.10.1

Version 0.10.1 #6

Workflow file for this run

---
name: Merge into upstream branches
on:
release:
types:
- published
jobs:
merge_release:
name: Merge into upstream branches
runs-on: ubuntu-latest
steps:
- name: Generate token
uses: actions/create-github-app-token@v1
id: app-token
with:
app-id: ${{ secrets.TOKEN_APP_ID }}
private-key: ${{ secrets.TOKEN_APP_SECRET }}
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
token: ${{ steps.app-token.outputs.token }}
- name: Setup git
uses: fregante/setup-git-user@v2
- name: Checkout release branch
run: |
git checkout ${{ github.event.release.target_commitish }}
- name: Reset development version
if: ${{ github.event.release.target_commitish == 'main' }}
run: |
./build reset_development_version
git add .version-dev && git commit -m "[Bot] Update development version to $(cat .version-dev)." && git push origin main
- name: Merge into feature branch
if: ${{ github.event.release.target_commitish == 'main' }}
run: |
git checkout -b feature origin/feature
git merge origin/main --strategy-option theirs -m "[Bot] Merge branch \"main\" into \"feature\"."
git push origin feature
- name: Merge into bugfix branch
if: ${{ github.event.release.target_commitish == 'main' || github.event.release.target_commitish == 'feature' }}
run: |
git checkout -b bugfix origin/bugfix
git merge origin/feature --strategy-option theirs -m "[Bot] Merge branch \"feature\" into \"bugfix\"."
git push origin bugfix
- name: Update major version
if: ${{ github.event.release.target_commitish == 'main' }}
run: |
git checkout main
./build increment_major_version
git add .version
git commit -m "[Bot] Update version to $(cat .version)."
git push origin main
git checkout feature
./build increment_minor_version
git add .version
git commit -m "[Bot] Update version to $(cat .version)."
git push origin feature
git checkout bugfix
./build increment_patch_version
git add .version
git commit -m "[Bot] Update version to $(cat .version)."
git push origin bugfix
- name: Update minor version
if: ${{ github.event.release.target_commitish == 'feature' }}
run: |
git checkout feature
./build increment_minor_version
git add .version
git commit -m "[Bot] Update version to $(cat .version)."
git push origin feature
git checkout bugfix
./build increment_patch_version
git add .version
git commit -m "[Bot] Update version to $(cat .version)."
git push origin bugfix
- name: Update patch version
if: ${{ github.event.release.target_commitish == 'bugfix' }}
run: |-
git checkout bugfix
./build increment_patch_version
git add .version
git commit -m "[Bot] Update version to $(cat .version)."
git push origin bugfix