Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
269 changes: 269 additions & 0 deletions .codebuddy/INSTALL.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,269 @@
# Superpowers Installation Guide for CodeBuddy

## Quick Install (One-Command)

Tell CodeBuddy in Craft mode:

```
Fetch and follow instructions from https://raw.githubusercontent.com/binbinao/superpowers/refs/heads/main/.codebuddy/INSTALL.md
```

Or run these commands in your terminal:

```bash
# Clone superpowers
mkdir -p ~/.codebuddy
git clone https://github.com/binbinao/superpowers.git ~/.codebuddy/superpowers

# Install MCP server dependencies
cd ~/.codebuddy/superpowers/.codebuddy/mcp-server
npm install

# Verify installation
node test.js
```

## Manual Installation

### Step 1: Clone Repository

```bash
mkdir -p ~/.codebuddy
git clone https://github.com/binbinao/superpowers.git ~/.codebuddy/superpowers
cd ~/.codebuddy/superpowers
```

### Step 2: Install Dependencies

```bash
cd .codebuddy/mcp-server
npm install
```

### Step 3: Configure MCP in CodeBuddy

#### For VS Code Plugin:

1. Open VS Code with CodeBuddy plugin installed
2. Click CodeBuddy icon in the sidebar
3. Select **Craft** mode
4. Click **MCP** option
5. Click **Add MCP Server** or **Configure**
6. Add new server with these settings:

**Method A: Using npx (Easiest)**

```json
{
"name": "superpowers",
"type": "stdio",
"command": "npx",
"args": [
"-y",
"github.com/binbinao/superpowers#main/.codebuddy/mcp-server"
],
Comment on lines +54 to +64
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟠 Major

🧩 Analysis chain

🏁 Script executed:

# Read the INSTALL.md file around the mentioned lines
cd /tmp && find . -name "INSTALL.md" 2>/dev/null | head -5 || echo "Need to search in repo"

Repository: obra/superpowers

Length of output: 42


🌐 Web query:

npx github subdirectory path support

💡 Result:

Short answer: No — npx follows npm's package specifiers and does not support pointing directly at a package.json inside a GitHub repo subdirectory. npx accepts git/GitHub specifiers, but npm's git-install semantics don't include a subdirectory path. [1][2]

Workarounds:

  • Publish the subpackage to npm (or GitHub Packages) and npx that package. [1]
  • Use tools that extract subfolders (degit, gitpkg, github-partials) and then run/install from the extracted folder (you can call these via npx). [3][4]

Sources:

  • npx README (shows git/GitHub specifiers and notes it uses npm's specifiers). [1]
  • npm issue requesting subdirectory installs (closed; explains lack of support). [2]
  • degit / gitpkg / github-partials docs for subdirectory extraction workarounds. [3][4]

🏁 Script executed:

# Also search for any npx documentation or usage in the repo
rg "npx.*github" -A 5 -B 5

Repository: obra/superpowers

Length of output: 42


🏁 Script executed:

# Find the INSTALL.md file
fd -name "INSTALL.md" -type f

Repository: obra/superpowers

Length of output: 290


🏁 Script executed:

# Also check if .codebuddy directory exists
fd -path "*/.codebuddy/INSTALL.md" -type f

Repository: obra/superpowers

Length of output: 228


🏁 Script executed:

# Find the INSTALL.md file with correct syntax
fd "INSTALL.md" -type f

Repository: obra/superpowers

Length of output: 230


🏁 Script executed:

# Alternative: search from root
git ls-files | grep -i install.md

Repository: obra/superpowers

Length of output: 120


🏁 Script executed:

# Read the INSTALL.md file to see lines 54-64 and surrounding context
cat -n .codebuddy/INSTALL.md | sed -n '50,75p'

Repository: obra/superpowers

Length of output: 695


🏁 Script executed:

# Also check what's near lines 248-269 mentioned in the scratchpad
wc -l .codebuddy/INSTALL.md

Repository: obra/superpowers

Length of output: 85


The npx command on line 63 will fail—npm/npx do not support GitHub subdirectory paths.

The syntax github.com/binbinao/superpowers#main/.codebuddy/mcp-server is invalid. npx/npm do not support subdirectory specifications in GitHub URLs; they expect a package.json at the repository root. Either publish the package to npm and reference it by name, or remove Method A and make Method B (local installation) the primary approach.

🤖 Prompt for AI Agents
In @.codebuddy/INSTALL.md around lines 54 - 64, The "Method A" npx example is
invalid because npm/npx do not accept GitHub subdirectory refs; replace or
remove the npx snippet that uses the string
"github.com/binbinao/superpowers#main/.codebuddy/mcp-server": either remove
Method A and promote Method B as the primary install option, or update the
instructions to require publishing the package and show using its npm package
name with the "command": "npx" entry; ensure any remaining example uses a valid
npx target (a published package name or a GitHub repo root accepted by npx)
rather than the subdirectory syntax.

"disabled": false
}
```

**Method B: Using local installation**

```json
{
"name": "superpowers",
"type": "stdio",
"command": "node",
"args": ["/Users/YOUR_HOME/.codebuddy/superpowers/.codebuddy/mcp-server/index.js"],
"disabled": false
}
```

Replace `/Users/YOUR_HOME` with your actual home directory (run `echo ~` to see it).

#### For JetBrains Plugin:

1. Open CodeBuddy settings in your JetBrains IDE
2. Navigate to **MCP Configuration**
3. Add new server with same settings as above

#### For Internal Version:

The internal version of CodeBuddy supports additional configuration options:

```json
{
"name": "superpowers",
"type": "stdio",
"command": "node",
"args": ["/Users/YOUR_HOME/.codebuddy/superpowers/.codebuddy/mcp-server/index.js"],
"disabled": false,
"configSource": "user",
"timeout": 60
}
```

### Step 4: Restart CodeBuddy

Restart CodeBuddy to load the MCP server.

### Step 5: Verify Installation

In CodeBuddy Craft mode, ask:

```
Use find_skills tool to list all available superpowers skills
```

You should see a list of available skills.

## Verification

Run the test suite:

```bash
cd ~/.codebuddy/superpowers/.codebuddy/mcp-server
node test.js
```

All tests should pass with ✓ marks.

## Usage Examples

### Load a Skill

```
Use use_skill tool with skill_name: "superpowers:brainstorming"
```

### Find Available Skills

```
Use find_skills tool
```

### Get Bootstrap

```
Use get_bootstrap tool
```

## Creating Personal Skills

Create your own skills in `~/.config/codebuddy/skills/`:

```bash
mkdir -p ~/.config/codebuddy/skills/my-skill
cat > ~/.config/codebuddy/skills/my-skill/SKILL.md << 'EOF'
---
name: my-skill
description: Use when [condition] - [what it does]
---
# My Skill
[Your skill content here]
EOF
```

Then use it: `use_skill tool with skill_name: "my-skill"`

## Creating Project Skills

For project-specific skills, create them in your project directory:

```bash
mkdir -p .codebuddy/skills/my-project-skill
cat > .codebuddy/skills/my-project-skill/SKILL.md << 'EOF'
---
name: my-project-skill
description: Use when [condition] - [what it does]
---
# My Project Skill
[Your skill content here]
EOF
```

Then use: `use_skill tool with skill_name: "project:my-project-skill"`

## Skill Priority

When you use `use_skill` with a skill name:

1. **Project skills** (`.codebuddy/skills/`) - Checked first
2. **Personal skills** (`~/.config/codebuddy/skills/`) - Checked second
3. **Superpowers skills** (`~/.codebuddy/superpowers/skills/`) - Checked last

Force specific skill type:
- `project:skill-name` - Only check project skills
- `skill-name` - Check project → personal → superpowers
- `superpowers:skill-name` - Only check superpowers skills

## Troubleshooting

### Installation Fails

```bash
# Check Node.js version
node --version # Should be 18+

# Verify git clone worked
ls ~/.codebuddy/superpowers

# Check npm install worked
ls ~/.codebuddy/superpowers/.codebuddy/mcp-server/node_modules
```

### MCP Server Won't Start

```bash
# Test manually
node ~/.codebuddy/superpowers/.codebuddy/mcp-server/index.js

# Check for errors
# Should see: "Superpowers MCP server running on stdio"
```

### Skills Not Found

```bash
# Run test to verify skills discovery
cd ~/.codebuddy/superpowers/.codebuddy/mcp-server
node test.js

# Should show "Found XX skills"
```

### CodeBuddy Can't Connect to MCP

1. Check CodeBuddy version (requires recent version with MCP support)
2. Verify MCP configuration file syntax is correct JSON
3. Check file paths are absolute (not relative)
4. Enable debug logging in CodeBuddy to see error messages
5. Try disabling and re-enabling the MCP server

## Next Steps

- Read full documentation: [docs/README.codebuddy.md](../docs/README.codebuddy.md)
- Learn skill development: [skills/writing-skills/SKILL.md](../skills/writing-skills/SKILL.md)
- Browse available skills: [skills/](../skills/)
- Report issues: [https://github.com/binbinao/superpowers/issues](https://github.com/binbinao/superpowers/issues)

## Uninstallation

```bash
# Remove the superpowers repository
rm -rf ~/.codebuddy/superpowers

# Remove MCP configuration from CodeBuddy settings
# (Go to CodeBuddy MCP settings and delete superpowers server)
```

Your personal and project skills in `~/.config/codebuddy/skills/` and `.codebuddy/skills/` will remain unless you delete them.

## Support

- **Issues**: https://github.com/binbinao/superpowers/issues
- **CodeBuddy Docs**: https://cloud.tencent.com/document/product/1749
- **CodeBuddy MCP Guide**: https://cloud.tencent.com/developer/article/2526313
Comment on lines +248 to +269
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟡 Minor

Replace bare URLs with Markdown links.

Lines 248–269 include bare URLs, which markdownlint flags (MD034). Wrap them with link text or angle brackets.

📝 Example fix
-- Report issues: [https://github.com/binbinao/superpowers/issues](https://github.com/binbinao/superpowers/issues)
-- **CodeBuddy Docs**: https://cloud.tencent.com/document/product/1749
-- **CodeBuddy MCP Guide**: https://cloud.tencent.com/developer/article/2526313
+- Report issues: [GitHub Issues](https://github.com/binbinao/superpowers/issues)
+- **CodeBuddy Docs**: <https://cloud.tencent.com/document/product/1749>
+- **CodeBuddy MCP Guide**: <https://cloud.tencent.com/developer/article/2526313>
🤖 Prompt for AI Agents
In @.codebuddy/INSTALL.md around lines 248 - 269, The Support section contains
bare URLs (e.g., https://github.com/binbinao/superpowers/issues,
https://cloud.tencent.com/document/product/1749,
https://cloud.tencent.com/developer/article/2526313) which markdownlint flags
(MD034); update the "Support" list in .codebuddy/INSTALL.md to convert each bare
URL into a proper Markdown link with descriptive link text (for example
"Issues", "CodeBuddy Docs", "CodeBuddy MCP Guide") or wrap them in angle
brackets, ensuring the visible text replaces the raw URLs under the "Support"
heading.

Loading