ts_query_ls/.github/workflows/ci.yml
Riley Bruins 99b10a6cc1 feat: partial support for capture name validation
Currently not support by the `check` subcommand, nor autocompletions or
hover.
2025-04-20 15:33:23 -07:00

64 lines
1.5 KiB
YAML

name: CI
on:
push:
branches: ['master']
pull_request:
branches: ['master']
permissions:
contents: read
jobs:
lint:
name: Lint
runs-on: ubuntu-latest
timeout-minutes: 10
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@1.86.0
id: toolchain
with:
components: clippy
- run: cargo clippy --tests --no-deps -- -D warnings
format:
name: Format
runs-on: ubuntu-latest
timeout-minutes: 10
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@1.86.0
id: toolchain
with:
components: rustfmt
- run: cargo fmt --check
test:
name: Test
runs-on: ubuntu-latest
timeout-minutes: 10
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@1.86.0
id: toolchain
- run: cargo test
generate-schema:
name: Generate schema
runs-on: ubuntu-latest
timeout-minutes: 10
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@1.86.0
id: toolchain
- name: Check schema generation
run: |
# Generate schema
cargo xtask schema
# Check for uncommitted changes
if [[ -n "$(git status --porcelain)" ]]; then
echo '❌ Uncommitted changes detected after running `cargo xtask schema`:'
git --no-pager diff
exit 1
else
echo "✅ No changes; schema is up to date."
fi