You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
50 lines
1.1 KiB
YAML
50 lines
1.1 KiB
YAML
name: ci
|
|
|
|
on:
|
|
push:
|
|
branches:
|
|
- main
|
|
|
|
pull_request:
|
|
workflow_dispatch:
|
|
|
|
concurrency:
|
|
group: ${{ github.workflow }}-${{ github.ref }}
|
|
cancel-in-progress: ${{ github.ref != 'refs/heads/main' }}
|
|
|
|
jobs:
|
|
test:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
- uses: oven-sh/setup-bun@v1
|
|
with:
|
|
bun-version: latest
|
|
- name: Setup
|
|
run: bun install
|
|
- run: bun test
|
|
pretty:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
- uses: oven-sh/setup-bun@v1
|
|
with:
|
|
bun-version: latest
|
|
- name: Setup
|
|
run: bun install
|
|
- name: Format
|
|
run: bun fmt:ci
|
|
- name: typos-action
|
|
uses: crate-ci/typos@v1.17.2
|
|
- name: Lint
|
|
run: |
|
|
bun lint
|
|
# check for version changes
|
|
./update-version.sh
|
|
if [[ `git status --porcelain` ]]; then
|
|
echo "Version mismatch. Please run ./update-version.sh"
|
|
exit 1
|
|
else
|
|
echo "No changes detected."
|
|
fi
|