Conversation
Worth a lookUnchecked items in the PR checklist Each checkbox is an attestation — please fill them in honestly. If one doesn't apply to your change, note why in the description. |
There was a problem hiding this comment.
Pull request overview
Adds a --watch mode to the sqts compiler so it can recompile automatically on file changes, while also expanding the test suite around SQL parsing/introspection and compiler helpers, and enabling package/type linting in the build configs.
Changes:
- Add watch mode (
--watch) to thesqts compileCLI and implement a chokidar-based watcher. - Refactor/add Bun tests (and snapshots) for SQL parsing, schema introspection, and compiler utilities.
- Enable
publint/attwin tsdown configs and add corresponding dev dependencies.
Reviewed changes
Copilot reviewed 19 out of 28 changed files in this pull request and generated 5 comments.
Show a summary per file
| File | Description |
|---|---|
| packages/core/src/compiler/compileProject.ts | Adds watchAndCompileProject, switches globbing to tinyglobby, and uses ctx.tsCompilerOptions for ts-morph project creation. |
| packages/core/src/compiler/getCompileContext.ts | Augments compile context with tsCompilerOptions loaded from tsconfig.json. |
| packages/core/src/cli.ts | Adds --watch flag to the compile command and routes to watch vs one-shot compile. |
| packages/core/package.json | Adds chokidar and replaces glob with tinyglobby. |
| packages/core/tsconfig.json | Adds @/tests/* path alias for test imports. |
| packages/core/tests/** | Adds/refactors compiler/parser tests and snapshots; introduces shared test utilities. |
| packages/core/src/compiler/lib/*.test.ts | Removes colocated tests in src (moved under packages/core/tests). |
| packages/sql/tests/** | Adds SQL parser + schema introspection tests and snapshots. |
| packages/*/tsdown.config.ts | Enables publint and attw during builds. |
| package.json / bun.lock | Adds publint + @arethetypeswrong/core and updates lockfile. |
| .changeset/spicy-hats-dream.md | Declares a minor bump for @sqts/core for watch mode. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 19 out of 28 changed files in this pull request and generated 4 comments.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
What this changes
Adds watch mode (
--watch) to the compiler.(Also reorganises some tests)
How I tested this
Ran it against the basic example
Checklist