Skip to content

feat: improve bundle retention UI with clear options and multilingual… #9244

feat: improve bundle retention UI with clear options and multilingual…

feat: improve bundle retention UI with clear options and multilingual… #9244

Workflow file for this run

name: Bump version
on:
push:
branches:
- main
- development
jobs:
# Run all tests first before creating any tags
test:
if: ${{ !startsWith(github.event.head_commit.message, 'chore(release):') }}
uses: ./.github/workflows/tests.yml
# Only bump version and create tag if all tests pass
bump-version:
needs: [test]
if: ${{ !startsWith(github.event.head_commit.message, 'chore(release):') }}
runs-on: ubuntu-latest
name: Bump version and create tag
steps:
- name: Check out
uses: actions/checkout@v6
with:
token: "${{ secrets.PERSONAL_ACCESS_TOKEN }}"
- name: Setup bun
uses: oven-sh/setup-bun@v2
with:
bun-version: latest
- name: Git config
run: |
git config --local user.name "github-actions[bot]"
git config --local user.email "github-actions[bot]@users.noreply.github.com"
- name: Create version bump main
if: github.ref == 'refs/heads/main'
run: bun x standard-version --skip.changelog
- name: Create version bump development
if: github.ref != 'refs/heads/main'
run: bun x standard-version --prerelease alpha --skip.changelog
- name: Add version.ts to commit
run: |
git add supabase/functions/_backend/utils/version.ts
if ! git diff --cached --quiet; then
# Get the current tag before amending (if it exists)
CURRENT_TAG=$(git describe --tags --exact-match 2>/dev/null || echo "")
# Amend the commit
git commit --amend --no-edit
# Move the tag to the amended commit
if [ -n "$CURRENT_TAG" ]; then
git tag -f "$CURRENT_TAG"
fi
fi
- name: Push to origin
run: |
CURRENT_BRANCH=$(git rev-parse --abbrev-ref HEAD)
remote_repo="https://${GITHUB_ACTOR}:${{ secrets.PERSONAL_ACCESS_TOKEN }}@github.com/${GITHUB_REPOSITORY}.git"
git pull $remote_repo $CURRENT_BRANCH
git push $remote_repo HEAD:$CURRENT_BRANCH --follow-tags --tags