Skip to content

Latest commit

 

History

History
250 lines (178 loc) · 5.47 KB

INSTALLATION.md

File metadata and controls

250 lines (178 loc) · 5.47 KB

Installation Guide

Detailed installation instructions for intellisearch extension for OpenCode.

Table of Contents

Prerequisites

Required

  • OpenCode installed and running
  • Bun - Fast JavaScript runtime

Optional

  • GitHub CLI (gh) - For direct GitHub repository search
    • Run gh auth login to authenticate
    • To opt out: deny gh tool permission in OpenCode

MCP Servers

  • deepwiki - Repository Q&A (docs)

Installation

Option 1: CLI (Recommended)

The easiest way—runs the installer which handles everything:

# Interactive installer (asks for preferences)
bunx opencode-intellisearch install

# Non-interactive, global (all projects)
bunx opencode-intellisearch install --scope global

# Non-interactive, local (current project only)
bunx opencode-intellisearch install --scope local

# Skip confirmation prompts
bunx opencode-intellisearch install --scope global --force

The installer will:

  • Copy skill and command files to .opencode/
  • Add MCP server configuration (mcp.servers.deepwiki)
  • Add the plugin to the plugins array in opencode.json

Option 2: npm/bun Package

Install globally or locally, then configure manually:

# Global install
bun add -g opencode-intellisearch

# Local install (project only)
bun add -d opencode-intellisearch

Then add to your opencode.json:

{
  "$schema": "https://opencode.ai/config.json",
  "plugins": ["opencode-intellisearch@latest"],
  "mcp": {
    "servers": {
      "deepwiki": {
        "type": "remote",
        "url": "https://mcp.deepwiki.com/mcp"
      }
    }
  }
}

Option 3: Local Development

For development and testing:

# Clone repository
git clone https://github.com/expert-vision-software/opencode-intellisearch.git
cd opencode-intellisearch

# Install dependencies
bun install

# Link globally
bun link

# Use in test project
cd /path/to/test-project
bun link opencode-intellisearch --cwd ~/.cache/opencode/node_modules/

Or use path-based plugin loading in opencode.json:

{
  "plugins": ["file:///C:/dev/projects/github/opencode-intellisearch"]
}

MCP Server Setup

Configure in ~/.config/opencode/opencode.json or project opencode.json:

{
  "$schema": "https://opencode.ai/config.json",
  "mcp": {
    "servers": {
      "deepwiki": {
        "type": "remote",
        "url": "https://mcp.deepwiki.com/mcp"
      }
    }
  }
}

Verification

Check Installation

Bash:

# Global installation
ls ~/.cache/opencode/node_modules/opencode-intellisearch/

# Local installation
ls node_modules/opencode-intellisearch/

PowerShell:

# Global installation
Get-ChildItem $env:USERPROFILE\.cache\opencode\node_modules\opencode-intellisearch

# Local installation
Get-ChildItem node_modules\opencode-intellisearch

Test in OpenCode

  1. Start or restart OpenCode
  2. Run a test query:
/search-intelligently How does React useEffect work?

Check MCP Server Status

In OpenCode TUI:

/mcp status

Verify deepwiki server is running.

Uninstallation

CLI

# Interactive (asks for scope and confirmation)
bunx opencode-intellisearch uninstall

# Non-interactive, local scope
bunx opencode-intellisearch uninstall --scope local --force

# Also remove the package-managed config entries
bunx opencode-intellisearch uninstall --scope local --purge-config

By default, uninstall is conservative: it removes the manifest-recorded skill and command files and the opencode-intellisearch entry from the plugins array, leaving an empty "plugins": [] behind (the documented manual state). The deepwiki MCP server entry is left untouched since it may hold consumer edits. A legacy v1 permission.skill.intellisearch entry (written by pre-v2 installs) is also left untouched.

Pass --purge-config to also remove those package-managed config entries: the opencode-intellisearch plugins entry, any legacy permission.skill.intellisearch entry, and the mcp.servers.deepwiki server (plus its legacy v1 mcp.deepwiki spelling). Unrelated keys (other plugins, other permissions, other MCP servers, comments, formatting) are never touched, and a config file that fails to parse is preserved byte-for-byte.

Manual

Remove from opencode.json:

{
  "plugins": []
}

Or for local installs:

bun remove opencode-intellisearch

Troubleshooting

"bun command not found"

Install Bun from bun.sh:

# Linux/macOS
curl -fsSL https://bun.sh/install | bash

# Windows
powershell -c "irm bun.sh/install.ps1 | iex"

"Plugin not loading"

  1. Check OpenCode logs: ~/.local/share/opencode/log/
  2. Verify plugin is in opencode.json plugin array
  3. Ensure Bun is installed and in PATH

"deepWiki unavailable"

  1. Verify deepWiki MCP server is configured in opencode.json
  2. Check MCP server status with /mcp status
  3. Restart OpenCode

"All tools failed"

  1. Rephrase your query
  2. Check internet connectivity
  3. Verify MCP server status

Getting Help