refactor: standardize typecheck task as tscheck#240
Merged
Conversation
Rename the `test:types` turbo task and package scripts to `tscheck` so the shared lefthook pre-commit job runs `turbo run tscheck`, matching the task name used by consumers. - turbo.json: test:types -> tscheck - root + shared/loggy, shared/clibuddy, vland/cli, run-run/cli scripts - lefthook/turborepo.yml pre-commit job - update init-templates test guard and run-run docs example Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
|
rqbazan
added a commit
that referenced
this pull request
Jun 15, 2026
## What Adds `pretscheck` to the front of the `rr tsc` pre-script precedence chain: ``` pretscheck ?? pretsc ?? pretypecheck ``` ## Why #240 standardized the typecheck task as `tscheck`. The npm `pre<script>` convention implies the matching pre-hook should be `pretscheck` — so a package's `pretscheck` now runs (captured, inside the task) before the type check. The legacy `pretsc` / `pretypecheck` aliases remain as fallbacks, so nothing breaks for existing setups. ## Tests The pre-script feature previously had **no** coverage. This PR adds two integration tests in `test/integration/tsc.test.ts`: - `pretscheck` runs before tsc and fails the task when it fails. - `pretscheck` takes precedence over the legacy `pretsc` / `pretypecheck` aliases (the legacy scripts never fire). `pnpm rr check` and the full `@rrlab/cli` test suite are green; a `patch` changeset is included. 🤖 Generated with [Claude Code](https://claude.com/claude-code) --------- Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Merged
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Rename the typecheck task/script from
test:typestotscheckacross the workspace, and update the shared lefthook pre-commit job to runturbo run tscheck.Why
The shared lefthook config (
lefthook/turborepo.yml, consumed viaextends/remotes) ranturbo run test:types. Consumers that name their turbo tasktscheck(e.g. yoppy, and all ofapps/*+packages/*there) hitCould not find task 'test:types', which blocked their pre-commit. Standardizing ontscheckaligns the shared hook with the consumer convention.Changes
turbo.json:test:typestask →tscheckpackage.json+shared/loggy,shared/clibuddy,vland/cli,run-run/cliscripts:test:types→tschecklefthook/turborepo.yml: pre-commit job →pnpm turbo run tscheckvland/cliinit-templates test guard andrun-run/CLAUDE.mdexample updated to the new nameVerification
turbo run tscheckresolves; this branch's own pre-commit ran green (jscheck+tscheck). CHANGELOG history left untouched.Heads-up
This makes
tscheckthe standard. Any other repo that extends this lefthook config and still names its turbo tasktest:typeswill need to rename totscheck(or it will fail pre-commit). Consumers already ontscheck(e.g. yoppy) start working once this lands onmainand they re-runlefthook install.🤖 Generated with Claude Code