Commit Graph

19 Commits

Author SHA1 Message Date
Kazuki Yamada 8d27a5b427 fix(test): Update MCP tool tests for SDK type changes
The @modelcontextprotocol/sdk package updated CallToolResult.content
to a union type (text | image | audio | ...). Added proper type
assertions to access the text property in packCodebaseTool tests.
2025-11-28 00:11:29 +09:00
Kazuki Yamada f87e00dbdf chore(lint): upgrade biome to v2.2.4 and fix all lint errors
Updated biome from v1.9.4 to v2.2.4 to take advantage of latest linting improvements.

- Upgraded @biomejs/biome from ^1.9.4 to ^2.2.4
- Updated biome.json configuration for v2 compatibility:
  - Changed schema to 2.2.4
  - Updated file includes/ignores syntax
  - Added Vue file overrides to disable noUnusedVariables/noUnusedImports
- Fixed all lint errors:
  - Added radix parameter to parseInt calls
  - Prefixed unused parameters with underscore
  - Removed unused imports
  - Fixed biome suppression comments
  - Removed !important from CSS
  - Added type ignores for Vue component definitions

All 325 files now pass lint with 0 warnings and 0 errors.
2025-09-21 13:39:43 +09:00
Kazuki Yamada 8bf797114b feat(cli): Report files detected as binary by content inspection
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.
2025-08-23 14:35:54 +09:00
Kazuki Yamada 5b5ee862a0 feat(cli): Add --include-logs option for git commit history
This feature allows users to include git log information in the output to help AI understand development patterns and file change relationships.

Key changes:
- Added --include-logs and --include-logs-count CLI options
- Default to 50 commits, configurable via CLI and config file
- Includes commit date, message, and changed file paths (excludes commit hashes)
- Added security checks and metrics calculation for git logs
- Updated output templates to include git logs section
- Comprehensive test coverage and TypeScript fixes

Resolves user request for including git commit history to provide development context for AI analysis.
2025-08-22 14:09:58 +09:00
Kazuki Yamada 0efe7ba3cd test: use createMockConfig helper for all test mock configurations
- Replace manual config objects with createMockConfig() in test files
- Ensures consistency and automatic handling of new config properties
- Fixes truncateBase64 property linter errors
- Improves maintainability for future config schema changes
2025-07-15 22:44:47 +09:00
Kazuki Yamada 8cb6850e8f feat: migrate MCP tools to registerTool() API for SDK v1.15.0
- Update all 7 MCP tool files from tool() to registerTool() API
- Add structured outputSchema with Zod schemas for type safety
- Reorganize tool configuration with inputSchema and annotations
- Update test mocks to use registerTool instead of deprecated tool()
- Maintain backward compatibility with result field in pack tools
- Add comprehensive output schemas for better LLM integration

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-07-08 00:07:18 +09:00
Kazuki Yamada 01e7a4ca7e refactor: improve MCP response field naming for clarity
- Change buildMcpToolSuccessResponse: message → description
- Change buildMcpToolErrorResponse: message → errorMessage
- Update convertErrorToJson to return errorMessage field
- Update all tool implementations to use new field names
- Update all test expectations to match new response format

This provides better semantic clarity:
- description: explanatory text for successful operations
- errorMessage: specific error information for failures

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-07-08 00:07:17 +09:00
Kazuki Yamada 3eb8833369 feat: update MCP tools to structured output format
- Upgrade @modelcontextprotocol/sdk from 1.11.0 to 1.15.0
- Add structured content support to all MCP tool responses
- Update error handling to use convertErrorToJson utility
- Rename formatToolResponse to formatPackToolResponse for clarity
- Fix property naming consistency (contents → content)
- Update all tests to expect new JSON response format
- Replace 'any' types with proper TypeScript types for better type safety

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-07-08 00:07:17 +09:00
Kazuki Yamada 9f6aa1ad10 refactor(mcp): Introduce buildMcpToolSuccessResponse and buildMcpToolErrorResponse for consistent response handling 2025-05-25 16:51:09 +09:00
Kazuki Yamada 712b982e00 feat(mcp): Add processedFiles and safeFilePaths to PackResult and update related interfaces 2025-05-25 12:18:58 +09:00
Kazuki Yamada e62ce0caed refactor(mcp): Enhance tool descriptions for clarity and detail 2025-05-25 12:18:58 +09:00
Devin AI dcc2f10395 feat(mcp): enhance MCP tools with line specification and grep functionality
- Add line number specification (startLine, endLine) to read_repomix_output
- Add new grep_repomix_output tool for searching output content
- Include total line count in pack_codebase and pack_remote_repository results
- Add comprehensive tests for new functionality

Co-Authored-By: Kazuki Yamada <koukun0120@gmail.com>
2025-05-25 12:18:58 +09:00
Devin AI 2161dbc1c8 feat(mcp): Add support for MCP tool annotations
Co-Authored-By: Kazuki Yamada <koukun0120@gmail.com>
2025-05-10 19:50:50 +09:00
Kazuki Yamada 95f7092b94 feat(cli): add --stdout option for output to stdout instead of file, enhancing CLI flexibility
- Introduced `--stdout` flag to allow output to standard output, which cannot be used with the `--output` option.
- Updated CLI configuration to handle `stdout` mode.
- Enhanced documentation with examples for using `--stdout`.
- Added tests to ensure correct behavior when using `--stdout` in various scenarios.
2025-05-10 16:33:09 +09:00
Kazuki Yamada 265845a9c0 fix(gitDiff): Fix syntax and tests 2025-05-10 11:26:05 +09:00
pmdyy cdfa93c594 feat(output): Add git diff support with --diffs flag 2025-05-05 23:57:05 -06:00
Kazuki Yamada 46518a847a fix: add input.maxFileSize to tests config 2025-04-20 14:42:03 +09:00
Kazuki Yamada f1993c62c4 Fix tests for metadata-only output mode 2025-04-19 17:58:44 +09:00
Kazuki Yamada 4dbd17a4d3 test: improved coverage of MCP-related tests 2025-03-16 15:44:13 +09:00