feat: Add binary path resolution and Docker support (v0.1.0)

This release adds intelligent binary discovery and Docker support to Tendril,
making it more flexible and cross-platform compatible.

## Features

### Binary Path Resolution
- Intelligent binary discovery with smart fallbacks
- Explicit user configuration via gitea_mcp_binary_path setting
- Standard system paths (/usr/local/bin, /usr/bin)
- User home directories (~/.local/bin, ~/.cargo/bin, ~/bin)
- Platform-specific paths (/opt/homebrew/bin on macOS M-series)
- System PATH environment variable search
- Robust WASM sandbox handling for filesystem checks
- Comprehensive error messages with troubleshooting guidance
- Removed hardcoded /usr/local/bin/gitea-mcp path

### Docker Support
- New use_docker configuration option for containerized deployment
- New docker_image configuration for custom images (default: gitea/gitea-mcp-server:latest)
- Automatic docker binary detection at /usr/bin/docker or other standard locations
- Proper gitea-mcp command-line flag formatting (-token, -t stdio, -host, -insecure)
- STDIO communication through Docker containers

### Cross-Platform Support
- Linux: Standard system and user paths
- macOS Intel: Same as Linux
- macOS M-series (ARM64): Optimized for /opt/homebrew/bin
- Windows: Program Files paths (code ready, untested)
- Proper PATH separator handling (: on Unix, ; on Windows)

## Bug Fixes

- Fixed WASM sandbox filesystem access limitations
- Corrected Docker image name to gitea/gitea-mcp-server:latest
- Fixed Docker command flag formatting for gitea-mcp arguments
- Improved error handling with helpful resolution steps

## Documentation

- Updated README.md with Docker mode examples and configuration reference
- Expanded DEVELOPMENT.md with architecture and testing roadmap
- Updated PROJECT_STATUS.md with v0.1.0 feature status
- Updated configuration with all new options and detailed comments
- Added comprehensive inline code comments

## Testing

- Binary mode auto-detection: Tested and working
- Binary mode custom path: Tested and working
- Docker mode with default image: Tested and working
- Self-hosted Gitea instances: Tested and working
- Self-signed certificate support: Tested and working

## Files Changed

- src/mcp_server_gitea.rs: Core extension (~350 lines)
- configuration/default_settings.jsonc: New settings
- configuration/installation_instructions.md: Updated guide
- README.md: Expanded documentation
- DEVELOPMENT.md: Complete developer guide
- PROJECT_STATUS.md: Updated status
- .gitignore: Added comprehensive ignore file

## Breaking Changes

None - fully backward compatible.

## Next Steps (v0.2.0)

- Cross-platform testing
- Interactive configuration wizard
- Performance optimizations
- Marketplace publication
This commit is contained in:
2025-11-10 16:43:11 -07:00
parent 83d9664f72
commit 6a8dfa8b66
13 changed files with 2761 additions and 2 deletions

130
QUICKSTART.md Normal file
View File

@@ -0,0 +1,130 @@
# Tendril Quick Start Guide
**TL;DR**: Get Tendril working in 5 minutes.
## Prerequisites
```bash
# 1. Install Rust (if not already installed)
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh
# 2. Download and install gitea-mcp binary
wget https://gitea.com/gitea/gitea-mcp/releases/download/v1.0.0/gitea-mcp-linux-amd64
chmod +x gitea-mcp-linux-amd64
sudo mv gitea-mcp-linux-amd64 /usr/local/bin/gitea-mcp
# Verify
/usr/local/bin/gitea-mcp --help
```
## Generate Gitea Token
1. Log in to your Gitea instance
2. Settings → Applications → Authorize New Application
3. Name: "Zed MCP"
4. Check repository permissions
5. Copy the token
## Install in Zed (Dev Extension)
```bash
# 1. Open Zed
# 2. Extensions → Install Dev Extension
# 3. Select the tendril directory
# 4. Wait for Zed to compile (a few seconds first time)
```
## Configure Zed
Add to your `settings.json`:
```json
{
"context_servers": {
"tendril-gitea-mcp": {
"settings": {
"gitea_access_token": "YOUR_TOKEN_HERE"
}
}
}
}
```
## Test It
1. Open Zed's Assistant (Cmd+K)
2. Type: `list my repositories`
3. Done! 🎉
---
## Configuration Options
```json
{
"context_servers": {
"tendril-gitea-mcp": {
"settings": {
"gitea_access_token": "required", // Your token
"gitea_host": "https://git.example.com", // Self-hosted Gitea
"gitea_insecure": false, // Self-signed certs
"gitea_port": 8080, // SSE mode port
"use_sse": false // Use SSE instead of STDIO
}
}
}
}
```
## Troubleshooting
| Problem | Solution |
|---------|----------|
| "failed to spawn command" | Make sure `/usr/local/bin/gitea-mcp` exists: `ls -l /usr/local/bin/gitea-mcp` |
| Extension not loading | Check Zed logs: `zed: open log` |
| Auth errors | Verify token and permissions, regenerate if needed |
| SSE mode issues | Try STDIO mode: set `"use_sse": false` |
## Useful Commands
```bash
# Test the binary
/usr/local/bin/gitea-mcp --help
# View logs
tail -f ~/.gitea-mcp/gitea-mcp.log
# Check Zed logs (in Zed)
zed: open log
# Rebuild extension
cargo build --release
```
## Need More Help?
- 📖 See **README.md** for full documentation
- 👨‍💻 See **DEVELOPMENT.md** for development guide
- 🔍 See **PROJECT_STATUS.md** for current status and roadmap
- 📋 See **configuration/installation_instructions.md** for detailed setup
## What Tendril Does
Tendril is a **Zed extension** that connects to a **gitea-mcp server** running on your system.
```
Zed (with Tendril extension)
gitea-mcp binary (at /usr/local/bin/gitea-mcp)
Gitea Instance (your self-hosted or public Gitea)
```
The extension lets you interact with Gitea repositories, issues, PRs, and more directly from Zed's Assistant panel using natural language.
## Quick Links
- 🏠 Repository: https://git.parkingmeter.info/Mycelium/tendril
- 🔗 Gitea MCP: https://gitea.com/gitea/gitea-mcp
- 📝 Zed Docs: https://zed.dev/docs/extensions
- 🧬 Mycelium Project: https://git.parkingmeter.info/Mycelium