- Replace empty return in fileCollectWorker with descriptive error
- Simplify array flattening using flatMap instead of reduce
- Make test assertions OS-agnostic using path.join
- Improve encoding error detection with confidence checks and BOM handling
Remove redundant explanatory message from binary file listing to simplify output.
The main header already explains the detection method, making individual file
annotations unnecessary.
Changes:
- Remove "Detected as binary despite text extension" message from each file
- Improve type safety by using FileSkipReason type instead of string
- Update corresponding test expectations
- Clean up unused import in fileCollectWorker
The simplified output is cleaner while maintaining clarity about why files were excluded.
Add new "Binary Files Detected" section to CLI output that shows files which were
skipped due to binary content detection (not extension-based). This addresses issue #752
where users were not informed about files being silently excluded.
Changes:
- Update fileRead.ts to return detailed skip reasons (binary-extension, binary-content, size-limit, encoding-error)
- Modify file collection pipeline to track and propagate skipped files
- Add reportSkippedFiles function to display binary-content detected files
- Show files with relative paths and helpful exclusion messages
- Only display section when binary-content files are found
- Add comprehensive test coverage for new functionality
The implementation follows existing security check reporting patterns and provides
users clear visibility into why files were excluded from output.