Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 12 additions & 0 deletions .github/pull_request_template.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
## Summary

-

## Validation

- [ ] `bun run check`
- [ ] `bun run typecheck`

## Notes

-
29 changes: 29 additions & 0 deletions .github/workflows/check.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
name: Check

on:
pull_request:
branches: [main]
push:
branches: [main]

jobs:
Check:
name: Check
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4

- name: Setup Bun
uses: oven-sh/setup-bun@v2
with:
bun-version: 1.3.8

- name: Install dependencies
run: bun install --frozen-lockfile

- name: Biome check
run: bun run check

- name: TypeScript typecheck
run: bun run typecheck
30 changes: 30 additions & 0 deletions .github/workflows/validate-pr-title.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
name: ValidatePrTitle

on:
pull_request:
types: [opened, edited, synchronize, reopened]

permissions:
pull-requests: read

jobs:
ValidatePrTitle:
name: ValidatePrTitle
runs-on: ubuntu-latest
steps:
- name: Validate pull request title
env:
PR_TITLE: ${{ github.event.pull_request.title }}
run: |
title="${PR_TITLE}"
if [ -z "${title// /}" ]; then
echo "PR title cannot be empty."
exit 1
fi

if [[ "$title" =~ ^[Ww][Ii][Pp]([:\ ]|$) ]]; then
echo "PR title cannot start with WIP."
exit 1
fi

echo "PR title is valid: $title"