When Tauri invoke fails (e.g., paths with spaces/special chars on iCloud
Drive), the frontend falls back to REST API mode. The CLAUDE.md endpoints
were mapped in apiAdapter.ts but had no corresponding handlers in
web_server.rs, causing the fallback to also fail with "Failed to load
CLAUDE.md files".
Adds three GET route handlers:
- /api/claude-md?projectPath=... (find CLAUDE.md files)
- /api/claude-md/read?filePath=... (read a CLAUDE.md file)
- /api/claude-md/save?filePath=...&content=... (save a CLAUDE.md file)
Fixes winfunc#444
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Summary
Changes
src-tauri/src/web_server.rs — 3 new GET handlers + route registrations:
The handlers call the existing pub async fn functions from commands::claude (no changes needed there). Follows the same pattern as all other endpoints in the file.
Fixes #444
Test plan
🤖 Generated with Claude Code