-
Notifications
You must be signed in to change notification settings - Fork 8
feat: add disclaimer #57
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
📝 WalkthroughWalkthroughAdds development warning text to README, prints two yellow warnings at CLI startup, wires a versionCheck middleware into the yargs startup chain, enables stricter yargs command validation, and restructures ESLint settings in package.json (Jest rules moved into overrides). No functional public API changes. Changes
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~20 minutes Poem
Pre-merge checks and finishing touches❌ Failed checks (1 inconclusive)
✅ Passed checks (2 passed)
✨ Finishing touches🧪 Generate unit tests (beta)
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 |
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: 0
🧹 Nitpick comments (2)
README.md (1)
3-4: Clear development warning added.The warning is prominent and well-placed at the top of the README. It aligns well with the runtime warnings added to the CLI.
Optional enhancement: Add link to TrustVC library
Consider adding a link to the TrustVC library documentation to help users find the production-ready alternative:
> ⚠️ This CLI is for development work only. It is not recommended for production use. -> For production, please integrate the TrustVC library. +> For production, please integrate the [TrustVC library](https://github.com/TradeTrust/trustvc).src/index.ts (1)
6-8: Development warnings appropriately placed.The startup warnings are clear and align well with the README documentation. Placing them at the top level before yargs initialization ensures users see the warning immediately when the CLI is invoked, which is the correct behavior for a development-only tool.
The static analysis complaint about "should be done within a hook" appears to be a false positive—it's likely applying frontend framework rules (e.g., React hooks) to a Node.js CLI context where top-level execution is appropriate and intentional.
Optional enhancement: Add link to TrustVC library
Consider adding a URL or more context about the TrustVC library to help users find the production alternative:
// Display development warning console.warn(chalk.yellow("\n⚠️ This CLI is for development work only. It is not recommended for production use.")); -console.warn(chalk.yellow("For production, please integrate the TrustVC library.\n")); +console.warn(chalk.yellow("For production, please integrate the TrustVC library: https://github.com/TradeTrust/trustvc\n"));
📜 Review details
Configuration used: defaults
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (2)
README.mdsrc/index.ts
🧰 Additional context used
🪛 GitHub Check: Linters / Code Lint
src/index.ts
[failure] 8-8:
This should be done within a hook
[failure] 7-7:
This should be done within a hook
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
- GitHub Check: Tests / Run Tests
🔇 Additional comments (1)
src/index.ts (1)
3-3: No action required. Thechalkpackage is properly included in the project's dependencies.
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: 0
🧹 Nitpick comments (1)
package.json (1)
118-122: Remove thebrowserenvironment for a Node.js CLI tool.The
browser: trueenvironment setting is inappropriate for a CLI tool that runs exclusively in Node.js. This setting tells ESLint that browser globals (likewindow,document, etc.) are available, which could lead to false negatives where browser-only APIs aren't flagged as errors.🔎 Proposed fix
"eslintConfig": { "parser": "@typescript-eslint/parser", "env": { - "browser": true + "node": true, + "es2020": true },
📜 Review details
Configuration used: defaults
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (1)
package.json
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
- GitHub Check: Tests / Run Tests
🔇 Additional comments (1)
package.json (1)
142-162: LGTM! Good refactor to scope Jest rules to test files.Moving Jest-specific linting rules into an overrides block is a best practice. This ensures production code is linted without Jest rules while test files receive appropriate Jest-specific linting. The disabled rules (
prefer-expect-assertions,no-hooks,prefer-strict-equal) are reasonable choices that prevent overly strict test linting.
|
🎉 This PR is included in version 3.4.0 🎉 The release is available on: Your semantic-release bot 📦🚀 |
Summary
add in disclaimer on readme and cli
Jira Ticket
Summary by CodeRabbit
Documentation
Chores
✏️ Tip: You can customize this high-level summary in your review settings.