Skip to content

fix(backend): Make SeqSet description optional for /update-seqset #4417

fix(backend): Make SeqSet description optional for /update-seqset

fix(backend): Make SeqSet description optional for /update-seqset #4417

name: Format Backend Code
on:
workflow_dispatch:
pull_request:
types: [synchronize, labeled]
paths:
- "backend/**"
- ".github/workflows/format-backend-on-request.yml"
jobs:
format:
if: github.event_name == 'workflow_dispatch' || (github.event_name == 'pull_request' && contains(github.event.pull_request.labels.*.name, 'format_me'))
permissions:
contents: write
runs-on: ubuntu-latest
timeout-minutes: 15
steps:
- name: Checkout Repository
uses: actions/checkout@v7
with:
ref: ${{ github.head_ref }}
- name: Set up JDK
uses: actions/setup-java@v6
with:
# Keep in sync with the other Java versions (backend/build.gradle, backend/Dockerfile)
java-version: "25"
distribution: "temurin"
- name: Setup Gradle
uses: gradle/actions/setup-gradle@v6
- name: Format Backend Code
run: ./gradlew ktlintFormat
working-directory: ./backend
- name: Commit and Push Changes
run: |
git config --global user.name 'Loculus bot'
git config --global user.email 'bot@loculus.org'
git add -A
git commit -m "Automated backend code formatting" || echo "No changes to commit"
git push origin HEAD:${{ github.head_ref }}