-
Notifications
You must be signed in to change notification settings - Fork 0
Replace custom getenv with npm package #3
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
Replace custom getenv with npm package #3
Conversation
- Install getenv npm package as dependency - Refactor getenv() to use official package internally for type casting - Maintain case-insensitive lookup across multiple naming conventions - Update README.md to document dependency on getenv package - Add getenv to Related Projects section - All tests pass successfully
- Replace all catch (_error) with catch { } for ignored errors
- Remove all underscore ignore patterns from eslint config
- Set no-unused-vars to strict 'error' with no exceptions
- Update 6 catch blocks in src/index.js and 1 in scripts/format-release-notes.mjs
- All tests and linter checks pass
|
🤖 AI Work Session Started Starting automated work session at 2025-11-15T11:57:43.595Z The PR has been converted to draft mode while work is in progress. This comment marks the beginning of an AI work session. Please wait working session to finish, and provide your feedback. |
This changeset documents the replacement of the custom getenv implementation with the official npm package, enhanced with case-insensitive lookup. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
|
✅ PR is ready for review I've successfully resolved the CI failure and completed the implementation: What was done:
Summary of changes in this PR:
The PR is now ready for merge! 🚀 🤖 Generated with Claude Code |
🤖 Solution Draft LogThis log file contains the complete execution trace of the AI solution draft process. 💰 Cost estimation:
Now working session is ended, feel free to review and add any feedback on the solution draft. |
🔄 Auto-restart 1/3Detected uncommitted changes from previous run. Starting new session to review and commit them. Uncommitted files: Auto-restart will stop after changes are committed or after 2 more iterations. Please wait until working session will end and give your feedback. |
Automated npm update that adds "peer": true markers to dev dependencies (acorn, eslint-plugin-n, eslint-config-prettier, prettier). 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
✅ Auto-restart CompleteSuccessfully handled uncommitted changes from previous session. What was done:
Current PR Status:
The PR is ready for merge! 🚀 🤖 Generated with Claude Code |
🤖 Solution Draft LogThis log file contains the complete execution trace of the AI solution draft process. 💰 Cost estimation:
Now working session is ended, feel free to review and add any feedback on the solution draft. |
Summary
This PR addresses issue #3 by replacing the custom
getenvimplementation with the official getenv npm package, while maintaining backward compatibility and the existing case-insensitive lookup feature.Key Changes
getenvnpm package (v2.0.0) for robust type casting and validationgetenv()function: Now uses the official package's type-safe methods:getenv.int()/getenv.float()for numeric valuesgetenv.boolish()for boolean values with flexible parsinggetenv.string()for string valuesno-unused-varsrule without exceptions, using moderncatch { }syntax for ignored errorsTest Results
All tests passing locally and in CI:
Breaking Changes
None - the changes are fully backward compatible with the existing API.
🤖 Generated with Claude Code
Fixes #3