okami.mom/strata

git clone https://git.nkp.pet/okami.mom/strata

Niko1221Merge f-020-docs3 into f-020-int (0.2.0 release wiring and docs)6ff75059a

main
1005 B28 linesraw
1name: Title area
2
3# Checks that a pull request or issue title starts with its area: [Engine], [GUI], [TUI], [Benchmark], [Docs] or [Other].
4# It reads the title only: no checkout, no labels, no comments, no write access.
5
6on:
7  pull_request:
8    types: [opened, edited, reopened, synchronize]
9  issues:
10    types: [opened, edited, reopened]
11
12permissions: {}
13
14jobs:
15  title:
16    runs-on: ubuntu-latest
17    steps:
18      - name: Check the title
19        env:
20          TITLE: ${{ github.event.pull_request.title || github.event.issue.title }}
21        run: |
22          case "$TITLE" in
23            "[Engine] "?*|"[GUI] "?*|"[TUI] "?*|"[Benchmark] "?*|"[Docs] "?*|"[Other] "?*)
24              echo "Title OK: $TITLE" ;;
25            *)
26              echo "::error::The title must start with its area and then a short description. Allowed areas: [Engine], [GUI], [TUI], [Benchmark], [Docs], [Other]. Example: \"[Engine] fix decode stop on long prompts\". Your title: $TITLE"
27              exit 1 ;;
28          esac