docs: Update exampels in README and help cmd#8
Conversation
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (1)
🚧 Files skipped from review as they are similar to previous changes (1)
📝 WalkthroughWalkthroughAdds README "Skill input formats" and updates programmatic example to ES module import; replaces Changes
Sequence Diagram(s)sequenceDiagram
participant User as User
participant CLI as CLI Parser
participant Help as printHelp()
participant Cmd as Command Handler
User->>CLI: invoke "skilleton add --help" or "-h"
CLI->>CLI: normalize flags (-h → help), parse args
CLI->>Help: help requested for command "add"
Help-->>User: print add-specific usage, examples
CLI--xUser: exit (do not run Cmd)
alt help not requested
User->>CLI: invoke "skilleton add ..."
CLI->>Cmd: run add handler with parsed args
Cmd-->>User: command output
end
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~20 minutes Poem
🚥 Pre-merge checks | ✅ 1 | ❌ 2❌ Failed checks (2 warnings)
✅ Passed checks (1 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Comment |
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Inline comments:
In `@bin/skilleton.ts`:
- Around line 79-80: The help flag check (if (args.flags.help || args.flags.h)
in bin/skilleton.ts) never sees -h because parseArgs currently only parses long
(--help) flags; update parseArgs to recognize short flags (e.g., map -h to
flags.h) or add a quick check that treats a single positional "-h" as help
before command execution. Locate the parseArgs implementation and ensure it
converts "-h" into args.flags.h (or sets args.flags.help), or modify the caller
to inspect args.positional for "-h" and call printHelp(command) if found,
keeping the existing printHelp usage intact.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: defaults
Review profile: CHILL
Plan: Pro
Run ID: 7bb3f2da-4758-478c-9239-62bead2d924d
📒 Files selected for processing (2)
README.mdbin/skilleton.ts
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Inline comments:
In `@bin/skilleton.ts`:
- Around line 83-87: The help check currently short-circuits before validating
the requested command (args.flags.help -> printHelp(command)), letting invalid
commands like "nope --help" succeed; change control flow so command
validation/unknown-command handling runs before honoring --help: call the
existing unknown-command validation logic (the code that verifies "command" and
emits the error) first, and only if the command is known then call
printHelp(command) when args.flags.help is true; alternatively, check
args.command/command validity at the top and return an error before printing
help, ensuring the process exits with an error status for unknown commands.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
Summary by CodeRabbit
Documentation
validatecommand withaudit(placeholder)New Features
listcommand supports --format=table|json