Summary
BunKill is currently only tested on macOS. Windows has not been validated and has several known incompatibilities that need to be addressed.
Known Issues
1. Shell commands not available on Windows
src/scanner.ts:157-169 — getDirectorySize() spawns du -sk which is not available on Windows by default
src/scanner.ts:426-429 — deleteModules() spawns rm -rf which is not available on Windows (should use rd /s /q or fs.rm)
2. Path separator handling
src/scanner.ts:51 — isWithinRoot() uses hardcoded / separator
src/scanner.ts:55 — hasHiddenPathSegment() uses hardcoded /
src/scanner.ts:245 — fullPath.split("/node_modules") hardcoded separator
src/scanner.ts:328 — projectPath = nmPath.replace(/\/node_modules$/, "") hardcoded separator
- Multiple other places use
/ instead of path.sep or path.join
3. Terminal UI
- Raw mode handling (
setRawMode) may behave differently on Windows
- ANSI escape codes for cursor movement and colors may need Windows Terminal or ConPTY
Proposed Solutions
- Replace
du -sk with a cross-platform size calculation (e.g., recursive Bun.file().stat() or use node:fs APIs)
- Replace
rm -rf with fs.promises.rm(path, { recursive: true, force: true }) (available in Node/Bun)
- Use
path.sep or path.join() consistently instead of hardcoded /
- Test on Windows Terminal and document minimum terminal requirements
- Add CI testing on Windows (GitHub Actions
windows-latest)
Testing Needed
Acceptance Criteria
Summary
BunKill is currently only tested on macOS. Windows has not been validated and has several known incompatibilities that need to be addressed.
Known Issues
1. Shell commands not available on Windows
src/scanner.ts:157-169—getDirectorySize()spawnsdu -skwhich is not available on Windows by defaultsrc/scanner.ts:426-429—deleteModules()spawnsrm -rfwhich is not available on Windows (should userd /s /qorfs.rm)2. Path separator handling
src/scanner.ts:51—isWithinRoot()uses hardcoded/separatorsrc/scanner.ts:55—hasHiddenPathSegment()uses hardcoded/src/scanner.ts:245—fullPath.split("/node_modules")hardcoded separatorsrc/scanner.ts:328—projectPath = nmPath.replace(/\/node_modules$/, "")hardcoded separator/instead ofpath.seporpath.join3. Terminal UI
setRawMode) may behave differently on WindowsProposed Solutions
du -skwith a cross-platform size calculation (e.g., recursiveBun.file().stat()or usenode:fsAPIs)rm -rfwithfs.promises.rm(path, { recursive: true, force: true })(available in Node/Bun)path.seporpath.join()consistently instead of hardcoded/windows-latest)Testing Needed
bunkillon Windows 10/11 with Windows Terminalbunkill --dry-runand verify paths display correctlybunkill --delete-allon a test directory and verify deletion works--full-scanmode on WindowsAcceptance Criteria