TypeScript Rewrite: Check command with built-in checks#38
Closed
d4mation wants to merge 18 commits intoENG-219/command-helpfrom
Closed
TypeScript Rewrite: Check command with built-in checks#38d4mation wants to merge 18 commits intoENG-219/command-helpfrom
d4mation wants to merge 18 commits intoENG-219/command-helpfrom
Conversation
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Add emoji messages and detailed guidance when no checks are configured. Use output module prefix system, bail early on error-level failures with a descriptive message, and show a failure summary at the end. Built-in checks now use output.section/success/error for formatted output matching the PHP version's color and structure, and the TBD check skips .pup-/.puprc files.
Verify section headers, prefixed output lines, file path listings, and bail message in test expectations.
Verify section headers, prefixed output lines, updated error messages, version listing, and bail message in test expectations.
…file validation
Register check:{slug} subcommands dynamically from .puprc config instead of
hardcoding them. Defer version file existence and regex validation from config
parsing to the version-conflict check runtime, matching PHP behavior.
… check Output plain ERROR message matching PHP behavior when a version file does not exist, without prefix or section header formatting.
…n conflict error Remove prefix from standalone check subcommands (check:tbd, check:version-conflict) to match PHP behavior where only the main check command uses prefixes. Use white on red background for version conflict error message to match PHP error tag styling.
Scan src/commands/checks/ at build time and inject BUILTIN_CHECK_SLUGS as a compile-time constant. Built-in checks are always registered as subcommands and fall back to default config when not explicitly configured in .puprc.
Tests cover built-in check registration without .puprc config, standalone subcommand output (no prefix), custom command/module checks, fail methods (warn vs error), and empty checks guidance.
Contributor
Author
|
Going to recreate this as multiple PRs. It is too large and complex. |
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.
🎫 ENG-219
Reference
Summary
checkcommand that runs validation checks against the projectCheckCollectionclass andCheckModule/CheckContextinterfaces for extensible check systemtbdcheck that scans for@since TBDmarkers in source filesversion-conflictcheck that detects mismatched version strings across configured filesDependencies
This PR depends on #30 (app-bootstrap) being merged first.
Test plan
npx pup checkruns all configured checks@since TBDmarkers