-
Notifications
You must be signed in to change notification settings - Fork 2
fix: ignore internalRoutes when --ignore enabled
#182
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
close IDP-1316
🦋 Changeset detectedLatest commit: 88e3d2a The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
|
Note Other AI code review bot(s) detectedCodeRabbit has detected other AI code review bot(s) in this pull request and will avoid duplicating their findings in the review comments. This may lead to a less comprehensive review. WalkthroughAdds a conditional ESLint ignorePatterns based on globalOptions.ignore to exclude config.internalRoutes during lint runs, and introduces a changeset documenting this bug fix for a patch release. Changes
Sequence Diagram(s)sequenceDiagram
actor User
participant CLI as CLI (doom)
participant Lint as lint.ts
participant ESLint as ESLint
User->>CLI: doom lint [--ignore]
CLI->>Lint: runLint(globalOptions, config)
alt globalOptions.ignore is true
Note over Lint,ESLint: Set ignorePatterns = config.internalRoutes
Lint->>ESLint: new ESLint({ ignorePatterns: internalRoutes, ... })
else globalOptions.ignore is false
Note over Lint,ESLint: No ignorePatterns override
Lint->>ESLint: new ESLint({ ... })
end
ESLint-->>Lint: Lint results
Lint-->>CLI: Report
CLI-->>User: Output
Estimated code review effort🎯 2 (Simple) | ⏱️ ~10 minutes Possibly related PRs
Suggested labels
Poem
Pre-merge checks and finishing touches✅ Passed checks (3 passed)
✨ Finishing touches
🧪 Generate unit tests
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Signed-off-by: JounQin <admin@1stg.me>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR fixes a bug where internal routes were not being properly ignored when the --ignore flag was enabled in the lint command.
- Adds conditional logic to respect the
--ignoreflag by settingignorePatternsin ESLint configuration - Uses
config.internalRoutesas the ignore patterns when the globalignoreoption is true
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
commit: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 1
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (2)
.changeset/late-bees-draw.md(1 hunks)packages/doom/src/cli/lint.ts(1 hunks)
🔇 Additional comments (2)
packages/doom/src/cli/lint.ts (1)
39-39: Validate internalRoutes format (array/string) and relative pathsEchoing Copilot’s note: ensure config.internalRoutes is string or string[] and paths are correct relative to cwd (docsDir).
.changeset/late-bees-draw.md (1)
1-6: Changeset LGTMClear, scoped patch note aligned with the code change.
close IDP-1316
Summary by CodeRabbit
Bug Fixes
Chores