docs: unify all docs to use single installation path ~/.local/bin/mt5-quant
- Update WINDSURF.md: Use registry name io.github.masdevid/mt5-quant - Update CURSOR.md: Use ~/.local/bin/mt5-quant path - Update QUICKSTART.md: Use standard path for all clients - Update VSCODE.md: Use standard path - Update setup.sh: Prefer ~/.local/bin/mt5-quant over project path - Add fallback warning in setup.sh if project path used Single source of truth: ~/.local/bin/mt5-quant
This commit is contained in:
+2
-2
@@ -29,7 +29,7 @@ cargo build --release
|
||||
3. Click **Add Custom MCP**
|
||||
4. Enter:
|
||||
- **Name**: `mt5-quant`
|
||||
- **Command**: Full path to binary (e.g., `/Users/name/mt5-quant/target/release/mt5-quant`)
|
||||
- **Command**: `~/.local/bin/mt5-quant`
|
||||
- **Type**: `stdio`
|
||||
|
||||
### Method 2: Edit mcp.json Directly
|
||||
@@ -41,7 +41,7 @@ Add to `~/.cursor/mcp.json` (global) or `.cursor/mcp.json` (project):
|
||||
"mcpServers": {
|
||||
"mt5-quant": {
|
||||
"type": "stdio",
|
||||
"command": "/absolute/path/to/mt5-quant"
|
||||
"command": "~/.local/bin/mt5-quant"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
+6
-4
@@ -81,7 +81,7 @@ terminal_dir: "~/Library/Application Support/net.metaquotes.wine.metatrader5/dri
|
||||
### Claude Code
|
||||
|
||||
```bash
|
||||
claude mcp add MT5-Quant -- /path/to/mt5-quant/target/release/mt5-quant
|
||||
claude mcp add io.github.masdevid/mt5-quant -- ~/.local/bin/mt5-quant
|
||||
```
|
||||
|
||||
Verify:
|
||||
@@ -96,8 +96,10 @@ Add to `~/.codeium/windsurf/mcp_config.json`:
|
||||
```json
|
||||
{
|
||||
"mcpServers": {
|
||||
"mt5-quant": {
|
||||
"command": "/path/to/mt5-quant"
|
||||
"io.github.masdevid/mt5-quant": {
|
||||
"command": "~/.local/bin/mt5-quant",
|
||||
"disabled": false,
|
||||
"registry": "io.github.masdevid/mt5-quant"
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -111,7 +113,7 @@ Add to `~/.cursor/mcp.json` (global) or `.cursor/mcp.json` (project):
|
||||
{
|
||||
"mcpServers": {
|
||||
"mt5-quant": {
|
||||
"command": "/path/to/mt5-quant"
|
||||
"command": "~/.local/bin/mt5-quant"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
+4
-4
@@ -28,7 +28,7 @@ cargo build --release
|
||||
2. Run `MCP: Add Server`
|
||||
3. Choose **Workspace** or **User** scope
|
||||
4. Enter server name: `mt5-quant`
|
||||
5. Enter command: Full path to binary (e.g., `/Users/name/mt5-quant/target/release/mt5-quant`)
|
||||
5. Enter command: `~/.local/bin/mt5-quant`
|
||||
|
||||
### Method 2: Edit mcp.json Directly
|
||||
|
||||
@@ -38,7 +38,7 @@ Add to `.vscode/mcp.json` in your workspace:
|
||||
{
|
||||
"servers": {
|
||||
"mt5-quant": {
|
||||
"command": "/absolute/path/to/mt5-quant"
|
||||
"command": "~/.local/bin/mt5-quant"
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -52,7 +52,7 @@ cat > .vscode/mcp.json << 'EOF'
|
||||
{
|
||||
"servers": {
|
||||
"mt5-quant": {
|
||||
"command": "/path/to/mt5-quant"
|
||||
"command": "~/.local/bin/mt5-quant"
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -62,7 +62,7 @@ EOF
|
||||
### Method 3: VS Code CLI
|
||||
|
||||
```bash
|
||||
code --add-mcp '{"name":"mt5-quant","command":"/path/to/mt5-quant"}'
|
||||
code --add-mcp '{"name":"mt5-quant","command":"~/.local/bin/mt5-quant"}'
|
||||
```
|
||||
|
||||
## Verify Setup
|
||||
|
||||
+8
-2
@@ -27,8 +27,10 @@ Edit `~/.codeium/windsurf/mcp_config.json`:
|
||||
```json
|
||||
{
|
||||
"mcpServers": {
|
||||
"mt5-quant": {
|
||||
"command": "/Users/masdevid/jobs/mt5-quant/target/release/mt5-quant"
|
||||
"io.github.masdevid/mt5-quant": {
|
||||
"command": "~/.local/bin/mt5-quant",
|
||||
"disabled": false,
|
||||
"registry": "io.github.masdevid/mt5-quant"
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -37,6 +39,10 @@ Edit `~/.codeium/windsurf/mcp_config.json`:
|
||||
Or use the automated setup:
|
||||
|
||||
```bash
|
||||
# Install binary to standard location
|
||||
cp target/release/mt5-quant ~/.local/bin/
|
||||
|
||||
# Then configure
|
||||
bash scripts/setup.sh
|
||||
```
|
||||
|
||||
|
||||
+15
-7
@@ -1024,14 +1024,20 @@ _register_with_platform() {
|
||||
local platform="$1"
|
||||
local use_binary="${2:-false}"
|
||||
|
||||
# Determine command path (binary for Windsurf/Cursor, Python for Claude)
|
||||
# Determine command path - use standard installation location
|
||||
local cmd_path
|
||||
if $use_binary && [[ -f "${REPO_DIR}/target/release/mt5-quant" ]]; then
|
||||
local default_install="$HOME/.local/bin/mt5-quant"
|
||||
|
||||
if [[ -f "$default_install" ]]; then
|
||||
cmd_path="$default_install"
|
||||
elif [[ -f "${REPO_DIR}/target/release/mt5-quant" ]]; then
|
||||
# Fallback to project build if standard location not found
|
||||
cmd_path="${REPO_DIR}/target/release/mt5-quant"
|
||||
elif [[ -f "${REPO_DIR}/mt5-quant" ]]; then
|
||||
cmd_path="${REPO_DIR}/mt5-quant"
|
||||
_warn "Using project build at $cmd_path"
|
||||
_warn "Consider installing to standard location: cp $cmd_path ~/.local/bin/"
|
||||
else
|
||||
cmd_path="python3 ${REPO_DIR}/server/main.py"
|
||||
_fail "mt5-quant not found at $default_install or ${REPO_DIR}/target/release/"
|
||||
return 1
|
||||
fi
|
||||
|
||||
case "$platform" in
|
||||
@@ -1066,8 +1072,10 @@ if os.path.exists(config_path):
|
||||
if 'mcpServers' not in data:
|
||||
data['mcpServers'] = {}
|
||||
|
||||
data['mcpServers']['mt5-quant'] = {
|
||||
'command': '$cmd_path'
|
||||
data['mcpServers']['io.github.masdevid/mt5-quant'] = {
|
||||
'command': '$cmd_path',
|
||||
'disabled': False,
|
||||
'registry': 'io.github.masdevid/mt5-quant'
|
||||
}
|
||||
|
||||
with open(config_path, 'w') as f:
|
||||
|
||||
Reference in New Issue
Block a user