Conversation
…ame, add verbose to dotenv Co-authored-by: panz3r <1754457+panz3r@users.noreply.github.com>
Co-authored-by: panz3r <1754457+panz3r@users.noreply.github.com>
Co-authored-by: panz3r <1754457+panz3r@users.noreply.github.com>
dotenv, improve error handling
There was a problem hiding this comment.
Pull request overview
This PR implements code review findings from the project's internal review documentation, focusing on quality improvements, consistency, and test coverage. The changes include correcting typos in error messages, adding missing license headers, normalizing path formats, improving type safety in app name extraction, and extending verbose logging support to the dotenv command.
Key changes:
- Fixed "retrive" → "retrieve" typo in icons.ts and splash.ts error messages
- Enhanced
extractAppName()with explicit return type, async implementation, and validation for empty/whitespace names - Added verbose flag support to dotenv command matching the pattern used in icons/splash commands
Reviewed changes
Copilot reviewed 9 out of 9 changed files in this pull request and generated 7 comments.
Show a summary per file
| File | Description |
|---|---|
| src/constants.ts | Added MPL-2.0 license header for compliance |
| src/utils/app.utils.ts | Converted to async with explicit return type and validation logic |
| src/commands/icons.ts | Fixed typo in error message ("retrive" → "retrieve") |
| src/commands/splash.ts | Fixed typo and removed ./ prefix from paths for consistency |
| src/commands/dotenv.ts | Added verbose flag with logVerbose() method matching sibling commands |
| test/app.utils.test.ts | Added comprehensive unit tests for extractAppName() edge cases |
| test/commands/icons.test.ts | Added verbose flag test |
| test/commands/splash.test.ts | Added verbose flag test |
| test/commands/dotenv.test.ts | Added verbose flag test |
|
@copilot update the specs document to mark the applied changes and check others not-applied ones |
Co-authored-by: panz3r <1754457+panz3r@users.noreply.github.com>
Updated the specs document in commit 0725433. The document now shows: Completed (6/11 items - 55%):
Pending (5/11 items):
Each section now has clear status indicators (✅/⏳) and updated completion tracking. |
Implements priority fixes and test coverage improvements from
docs/001-CODE-REVIEW-FINDINGS.md.Code Fixes
retrive→retrievein error messages (icons.ts, splash.ts)./prefix from splash.ts paths to match icons.ts conventionstring | nullreturn type and validation toextractAppName():Feature Addition
-v/--verboseflag matching icons/splash pattern withlogVerbose()methodTest Coverage
extractAppName()covering 7 edge cases (missing file, invalid JSON, empty/whitespace names, type mismatch)Documentation
docs/001-CODE-REVIEW-FINDINGS.mdwith completion status indicators (✅/⏳)Original prompt
💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.