mirror of
https://github.com/immich-app/immich
synced 2026-08-29 13:15:45 +00:00
89 lines
2.6 KiB
YAML
89 lines
2.6 KiB
YAML
name: Prepare new release
|
|
|
|
on:
|
|
workflow_dispatch:
|
|
inputs:
|
|
releaseType:
|
|
description: 'Release type'
|
|
required: true
|
|
default: 'false'
|
|
type: choice
|
|
options:
|
|
- 'false'
|
|
- minor
|
|
- patch
|
|
- premajor
|
|
- preminor
|
|
- prepatch
|
|
- prerelease
|
|
- release
|
|
skipTranslations:
|
|
description: 'Skip translations'
|
|
required: false
|
|
type: boolean
|
|
|
|
concurrency:
|
|
group: ${{ github.workflow }}-${{ github.ref }}-root
|
|
cancel-in-progress: true
|
|
|
|
permissions: {}
|
|
|
|
jobs:
|
|
merge_translations:
|
|
uses: ./.github/workflows/merge-translations.yml
|
|
with:
|
|
skip: ${{ inputs.skipTranslations }}
|
|
permissions:
|
|
pull-requests: write
|
|
secrets:
|
|
PUSH_O_MATIC_APP_CLIENT_ID: ${{ secrets.PUSH_O_MATIC_APP_CLIENT_ID }}
|
|
PUSH_O_MATIC_APP_KEY: ${{ secrets.PUSH_O_MATIC_APP_KEY }}
|
|
WEBLATE_TOKEN: ${{ secrets.WEBLATE_TOKEN }}
|
|
|
|
bump_version:
|
|
runs-on: ubuntu-latest
|
|
needs: [merge_translations]
|
|
outputs:
|
|
version: ${{ steps.output.outputs.version }}
|
|
permissions: {}
|
|
steps:
|
|
- id: token
|
|
uses: immich-app/devtools/actions/create-workflow-token@1af396ae134e4bc3b63d947e672bc68bf4ff9dc5 # create-workflow-token-action-v3.0.0
|
|
with:
|
|
client-id: ${{ secrets.PUSH_O_MATIC_APP_CLIENT_ID }}
|
|
private-key: ${{ secrets.PUSH_O_MATIC_APP_KEY }}
|
|
permission-contents: write
|
|
|
|
- name: Checkout code
|
|
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
|
|
with:
|
|
token: ${{ steps.token.outputs.token }}
|
|
persist-credentials: true
|
|
ref: main
|
|
|
|
- name: Setup Mise
|
|
uses: immich-app/devtools/actions/use-mise@06a9ef925332c91be647d6256642b86b398592c8 # use-mise-action-v3.2.1
|
|
with:
|
|
github_token: ${{ steps.token.outputs.token }}
|
|
|
|
# TODO move to mise
|
|
- name: Install uv
|
|
uses: astral-sh/setup-uv@20cfd1bf945f4377ade1205e4dbc17946fc9a30d # v10.0.1
|
|
|
|
- name: Bump version
|
|
env:
|
|
RELEASE_TYPE: ${{ inputs.releaseType }}
|
|
run: mise //:release --type "${RELEASE_TYPE}"
|
|
|
|
- id: output
|
|
run: echo "version=$IMMICH_VERSION" >> $GITHUB_OUTPUT
|
|
|
|
- name: Commit
|
|
env:
|
|
VERSION: ${{ steps.output.outputs.version }}
|
|
run: |
|
|
git config user.name 'immich-push-o-matic[bot]'
|
|
git config user.email '179150890+immich-push-o-matic[bot]@users.noreply.github.com'
|
|
git add -A
|
|
git commit -m "chore: version ${VERSION}"
|
|
git push
|