From 12434d455067fe2c24d6073113f2c34f46f1a0c7 Mon Sep 17 00:00:00 2001 From: Owen Jacobson Date: Tue, 27 May 2025 00:50:52 -0400 Subject: Consolidate project linting into tool scripts. The new `tools/check-lint` script checks lints across _all_ lintable files - JS (through `eslint`), and Rust (through `clippy` and `cargo check`). It also checks `eslint` against the whole project, not just against what's in the `ui` subdir, which means it now catches lintable issues in various JS config files. --- git-hooks/pre-commit | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'git-hooks/pre-commit') diff --git a/git-hooks/pre-commit b/git-hooks/pre-commit index 3d0ae17..ea34684 100755 --- a/git-hooks/pre-commit +++ b/git-hooks/pre-commit @@ -4,14 +4,12 @@ # run. It gets old fast. That's why this doesn't run tests, for example. tools/check-format +tools/check-lint # Make sure package-lock.json is up to date with package.json npm ci --dry-run # Make sure Cargo.lock is up to date with Cargo.toml. cargo update --locked --workspace -# Make sure there are no screamers in the code (both languages). -npm run lint -cargo check # Make sure the prepared statement data in .sqlx is up to date. Requires # `cargo-sqlx` (`cargo install cargo-sqlx`). export DATABASE_URL=sqlite://pilcrow.db.pre-commit?mode=rwc -- cgit v1.2.3