Skip to content

Simplify codebase: cleaner platform checks, modern fs API, remove boilerplate#208

Merged
otiai10 merged 1 commit intomainfrom
claude/review-code-simplifier-k86ne
Feb 14, 2026
Merged

Simplify codebase: cleaner platform checks, modern fs API, remove boilerplate#208
otiai10 merged 1 commit intomainfrom
claude/review-code-simplifier-k86ne

Conversation

@otiai10
Copy link
Copy Markdown
Owner

@otiai10 otiai10 commented Feb 14, 2026

  • Replace regex platform detection with direct process.platform === 'win32'
  • Use fs.promises.access instead of manual callback-to-Promise wrapper
  • Use bins.find(Boolean) instead of bins.find(bin => !!bin)
  • Deduplicate PATHEXT extensions to avoid redundant access checks on non-Windows
  • Remove 50+ lines of commented-out tsc --init boilerplate from tsconfig.json
  • Reuse isWindows constant in tests instead of inline regex checks

https://claude.ai/code/session_01KtrZQqBfLaiYkKwvATqJCd

…lerplate

- Replace regex platform detection with direct `process.platform === 'win32'`
- Use `fs.promises.access` instead of manual callback-to-Promise wrapper
- Use `bins.find(Boolean)` instead of `bins.find(bin => !!bin)`
- Deduplicate PATHEXT extensions to avoid redundant access checks on non-Windows
- Remove 50+ lines of commented-out tsc --init boilerplate from tsconfig.json
- Reuse `isWindows` constant in tests instead of inline regex checks

https://claude.ai/code/session_01KtrZQqBfLaiYkKwvATqJCd
@codecov
Copy link
Copy Markdown

codecov bot commented Feb 14, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 100.00%. Comparing base (13e32c0) to head (54152a2).
⚠️ Report is 2 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff            @@
##              main      #208   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files            1         1           
  Lines           22        24    +2     
  Branches        10         9    -1     
=========================================
+ Hits            22        24    +2     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@otiai10 otiai10 merged commit 372f53a into main Feb 14, 2026
11 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants