-
-
Notifications
You must be signed in to change notification settings - Fork 2.3k
Add experimental GitHub Copilot support #91
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add experimental GitHub Copilot support #91
Conversation
Extends Superpowers skills library to GitHub Copilot, following the successful pattern established by the .codex integration. Makes all 20 core skills available to GitHub Copilot users across VS Code, IntelliJ, Visual Studio, and other supported IDEs. New .copilot/ directory includes: - INSTALL.md: Complete installation guide with two bootstrap methods - superpowers-bootstrap.md: Tool mappings and integration tips - superpowers-copilot: Node.js CLI (bootstrap/find-skills/use-skill) - templates/: Bootstrap templates for both .github/copilot-instructions.md and AGENTS.md approaches Key features: - @workspace semantic search integration - Slash commands support (/tests, /fix, /refactor) - File-based planning with markdown checklists - Custom agents support via .github/agents/ - Cross-platform compatibility (Windows, macOS, Linux) - 95% code reuse from .codex integration Also updated: - README.md: Added GitHub Copilot installation section - RELEASE-NOTES.md: Added v3.5.0 release notes - skills/writing-skills/SKILL.md: Added ~/.copilot/skills directory Status: Experimental - requires user feedback and testing
WalkthroughThis pull request introduces experimental GitHub Copilot integration by adding comprehensive documentation, a Node.js CLI for skill discovery and loading, template bootstrap files, and project documentation updates to support Copilot as a new code assistant platform with superpowers skill management capabilities. Changes
Sequence Diagram(s)sequenceDiagram
participant User
participant CLI as superpowers-copilot
participant Git as Git/Network
participant FS as File System
participant Copilot as GitHub Copilot
User->>CLI: bootstrap
CLI->>Git: Check for updates (guarded)
Git-->>CLI: Update info or timeout
CLI->>FS: Read bootstrap markdown
CLI->>FS: Discover skills (find ~/.copilot/skills, ~/.copilot/superpowers/skills)
FS-->>CLI: List of skills (personal override superpowers)
CLI->>User: Display instructions & available skills
CLI->>CLI: Auto-load superpowers:using-superpowers
CLI->>Copilot: Load default skill content
Copilot-->>User: Skill ready
User->>CLI: use-skill <name>
CLI->>FS: Resolve skill path (personal priority)
FS-->>CLI: SKILL.md found/not found
CLI->>FS: Extract frontmatter & content
FS-->>CLI: Name, description, when_to_use, body
CLI->>User: Display skill metadata & content
CLI->>Copilot: Skill loaded
Estimated code review effort🎯 4 (Complex) | ⏱️ ~50 minutes
Possibly related PRs
Poem
Pre-merge checks and finishing touches✅ Passed checks (2 passed)
✨ Finishing touches🧪 Generate unit tests (beta)
Warning Review ran into problems🔥 ProblemsReview was content moderated. The following message was provided by the moderation system: …and bump the Please ensure that the code content and your reviewer tone settings are appropriate. Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 1
🧹 Nitpick comments (1)
.copilot/INSTALL.md (1)
69-71: Add language specifications to code blocks.These bash code blocks are missing language specifiers. Add
bashto the fenced code block delimiters for proper syntax highlighting and consistency with markdown best practices.-In Copilot Chat: -``` -Load the superpowers:brainstorming skill and help me design a feature -``` - -Copilot should run: -``` -~/.copilot/superpowers/.copilot/superpowers-copilot use-skill superpowers:brainstorming -``` +In Copilot Chat: +``` +Load the superpowers:brainstorming skill and help me design a feature +``` + +Copilot should run: +```bash +~/.copilot/superpowers/.copilot/superpowers-copilot use-skill superpowers:brainstorming +```Also applies to: 74-76
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (8)
.copilot/INSTALL.md(1 hunks).copilot/superpowers-bootstrap.md(1 hunks).copilot/superpowers-copilot(1 hunks).copilot/templates/AGENTS.md.template(1 hunks).copilot/templates/copilot-instructions.md.template(1 hunks)README.md(1 hunks)RELEASE-NOTES.md(1 hunks)skills/writing-skills/SKILL.md(1 hunks)
🧰 Additional context used
🪛 LanguageTool
.copilot/INSTALL.md
[uncategorized] ~37-~37: The official name of this software platform is spelled with a capital “H”.
Context: ...ing superpowers: #### Option A: Using .github/copilot-instructions.md (Recommended) ...
(GITHUB)
[uncategorized] ~39-~39: The official name of this software platform is spelled with a capital “H”.
Context: ...t-instructions.md (Recommended) Create .github/copilot-instructions.md in your projec...
(GITHUB)
[uncategorized] ~100-~100: The official name of this software platform is spelled with a capital “H”.
Context: ...ting Skills not loading? - Verify .github/copilot-instructions.md or AGENTS.md ex...
(GITHUB)
.copilot/superpowers-bootstrap.md
[uncategorized] ~12-~12: The official name of this software platform is spelled with a capital “H”.
Context: ...agents require custom agents setup (via .github/agents/) or do the work manually - `Sk...
(GITHUB)
[uncategorized] ~25-~25: Did you mean the formatting language “Markdown” (= proper noun)?
Context: ...cise context - When creating plans, use markdown format with checkboxes for tracking **...
(MARKDOWN_NNP)
RELEASE-NOTES.md
[uncategorized] ~16-~16: The official name of this software platform is spelled with a capital “H”.
Context: ... /refactor) - Bootstrap integration via .github/copilot-instructions.md or AGENTS.md...
(GITHUB)
[uncategorized] ~24-~24: The official name of this software platform is spelled with a capital “H”.
Context: ...ocs/plans/) - Custom agents support via .github/agents/ for specialized tasks - Semant...
(GITHUB)
[uncategorized] ~32-~32: The official name of this software platform is spelled with a capital “H”.
Context: ...GENTS.md supported) - Custom agents via .github/agents/ directory (optional) - File-ba...
(GITHUB)
[uncategorized] ~39-~39: The official name of this software platform is spelled with a capital “H”.
Context: ...structions.md.template- Template for .github/copilot-instructions.md -.copilot/tem...
(GITHUB)
🪛 markdownlint-cli2 (0.18.1)
.copilot/INSTALL.md
48-48: Bare URL used
(MD034, no-bare-urls)
61-61: Fenced code blocks should have a language specified
(MD040, fenced-code-language)
66-66: Fenced code blocks should have a language specified
(MD040, fenced-code-language)
71-71: Fenced code blocks should have a language specified
(MD040, fenced-code-language)
RELEASE-NOTES.md
7-7: Emphasis used instead of a heading
(MD036, no-emphasis-as-heading)
🔇 Additional comments (12)
README.md (1)
50-54: Consistent and well-placed addition.The new GitHub Copilot section mirrors the Codex pattern and is appropriately positioned in the Installation section. Content is clear and links correctly to the installation guide.
RELEASE-NOTES.md (1)
3-42: Comprehensive and well-organized release notes.The v3.5.0 section effectively documents the new Copilot integration with clear feature descriptions, comparative context against Claude Code and Codex, and a complete file manifest. The experimental status and cross-platform support are properly highlighted.
.copilot/superpowers-bootstrap.md (3)
7-7: Path consistency issue (same as in templates).Lines 7 and 34 reference the same potentially incorrect path:
~/.copilot/superpowers/.copilot/superpowers-copilot. This appears across all bootstrap/template files and needs verification (see duplicate comment on copilot-instructions.md.template for details).Also applies to: 34-34
9-16: Comprehensive tool mapping for Copilot constraints.The tool substitution table clearly explains how to adapt Claude Code tools (TodoWrite, Task, Skill, Read, Write, Bash, Grep) to Copilot equivalents (markdown checklists, custom agents, CLI, native file ops, terminal, @workspace). This helps users understand the architectural differences without getting stuck.
32-43: Effective enforcement language for skill adoption.The critical rules section uses appropriately forceful language ("DO NOT HAVE A CHOICE", "YOU MUST USE IT") consistent with the project's Superpowers philosophy, reinforced with the all-caps closing statement. This mirrors the enforcement patterns documented in skills/writing-skills/SKILL.md.
.copilot/templates/AGENTS.md.template (1)
1-7: Simple, focused bootstrap template.The template appropriately uses the EXTREMELY_IMPORTANT badge consistent with other bootstrap files. Note: Line 6 contains the same path verification issue flagged elsewhere; once the actual executable location is confirmed, all templates and docs need consistent updates.
skills/writing-skills/SKILL.md (1)
12-12: Consistent skills directory documentation.The update properly adds
~/.copilot/skillsto the list of agent-specific personal skills directories, aligning with the new Copilot bootstrap infrastructure and the directory creation step in INSTALL.md..copilot/INSTALL.md (4)
13-31: Clear and concise installation steps.The four-step setup process (clone, create directory, make executable, choose bootstrap method) is well-ordered and easy to follow. Each step includes appropriate bash snippets with correct paths and clear intent.
30-30: Path verification needed here as well.Lines 30, 63, and 75 all reference
~/.copilot/superpowers/.copilot/superpowers-copilot. Once the actual executable location is confirmed, ensure all path references in this guide match the corrected path.Also applies to: 63-63, 75-75
56-76: Comprehensive verification section with concrete test cases.The verification workflow provides clear, actionable tests: bootstrap command execution, skill loading verification, and expected output patterns. This helps users confirm correct setup quickly.
97-115: Practical troubleshooting guidance.The troubleshooting section addresses the most likely failure modes (missing instructions file, node not installed, outdated skills, Copilot not recognizing instructions) with specific diagnostic steps and remedies. Good coverage for user self-service.
.copilot/templates/copilot-instructions.md.template (1)
6-6: Disregard this review comment—the bootstrap path is correct.The path
~/.copilot/superpowers/.copilot/superpowers-copilot bootstrapis not duplicated or incorrect. The.copilot/superpowers-copilotfile exists in the repository root within the.copilotdirectory. When INSTALL.md clones the repository to~/.copilot/superpowersusinggit clone https://github.com/obra/superpowers.git ., the entire.copilotdirectory is cloned into that location, making the resulting path~/.copilot/superpowers/.copilot/superpowers-copilotthe correct executable location. This is confirmed in RELEASE-NOTES.md, which documents the file as part of the Copilot integration.Likely an incorrect or invalid review comment.
| function findSkillsInDir(dir, sourceType, maxDepth = 1) { | ||
| const skills = []; | ||
|
|
||
| if (!fs.existsSync(dir)) return skills; | ||
|
|
||
| function searchDir(currentDir, currentDepth) { | ||
| if (currentDepth > maxDepth) return; | ||
|
|
||
| try { | ||
| const entries = fs.readdirSync(currentDir, { withFileTypes: true }); | ||
|
|
||
| for (const entry of entries) { | ||
| if (entry.isDirectory()) { | ||
| const skillDir = path.join(currentDir, entry.name); | ||
| const skillFile = path.join(skillDir, 'SKILL.md'); | ||
|
|
||
| if (fs.existsSync(skillFile)) { | ||
| skills.push(skillDir); | ||
| } | ||
|
|
||
| // For personal skills, search deeper (category/skill structure) | ||
| if (sourceType === 'personal' && currentDepth < maxDepth) { | ||
| searchDir(skillDir, currentDepth + 1); | ||
| } | ||
| } | ||
| } | ||
| } catch (error) { | ||
| // Ignore permission errors or other issues | ||
| } | ||
| } | ||
|
|
||
| searchDir(dir, 0); | ||
| return skills; | ||
| } | ||
|
|
||
| // Commands | ||
| function runFindSkills() { | ||
| console.log('Available skills:'); | ||
| console.log('=================='); | ||
| console.log(''); | ||
|
|
||
| const foundSkills = new Set(); | ||
|
|
||
| // Find personal skills first (these take precedence) | ||
| const personalSkills = findSkillsInDir(personalSkillsDir, 'personal', 2); | ||
| for (const skillPath of personalSkills) { | ||
| const relPath = path.relative(personalSkillsDir, skillPath); | ||
| foundSkills.add(relPath); | ||
| printSkill(skillPath, 'personal'); | ||
| } | ||
|
|
||
| // Find superpowers skills (only if not already found in personal) | ||
| const superpowersSkills = findSkillsInDir(superpowersSkillsDir, 'superpowers', 1); | ||
| for (const skillPath of superpowersSkills) { | ||
| const relPath = path.relative(superpowersSkillsDir, skillPath); | ||
| if (!foundSkills.has(relPath)) { | ||
| printSkill(skillPath, 'superpowers'); | ||
| } | ||
| } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Skill discovery breaks for nested Superpowers directories
Most Superpowers skills live under category folders such as skills/collaboration/brainstorming/SKILL.md. The repository’s own authoring guidance calls out that structure explicitly (“Skill should be in skills/category/skill-name/SKILL.md”). Because findSkillsInDir only recurses for sourceType === 'personal', all of those category-scoped Superpowers skills are invisible. As a result, commands like superpowers-copilot use-skill superpowers:brainstorming (and even the bootstrap’s auto-load of superpowers:using-superpowers) fail—they look for ~/.copilot/superpowers/skills/brainstorming/SKILL.md, which never exists, so runUseSkill bails out and runFindSkills lists almost nothing.(prpm.dev)
Please make the directory walk symmetric for Superpowers skills and add a fallback in runUseSkill so it can resolve names within nested categories. For example:
- if (sourceType === 'personal' && currentDepth < maxDepth) {
- searchDir(skillDir, currentDepth + 1);
- }
+ if (currentDepth < maxDepth) {
+ searchDir(skillDir, currentDepth + 1);
+ }…and bump the maxDepth used for Superpowers when calling findSkillsInDir. In runUseSkill, if the initial lookup misses, search the discovered skill map (or reuse findSkillsInDir) to locate the first path whose trailing component matches the requested skill name before giving up. Without those fixes the CLI can’t load the very skills it’s supposed to expose.
Committable suggestion skipped: line range outside the PR's diff.
🤖 Prompt for AI Agents
In .copilot/superpowers-copilot around lines 97-155, the skill discovery only
recurses for 'personal' sources and uses maxDepth=1 for superpowers which
prevents finding category/skill-name/SKILL.md paths; update findSkillsInDir to
recurse for superpowers the same way it does for personal (or remove the
sourceType restriction) and when calling it for superpowers increase maxDepth to
2 (or a configurable depth) so category folders are scanned; additionally modify
runUseSkill so that if the direct lookup fails it falls back to searching the
discovered skills (or re-running findSkillsInDir) to find the first skill path
whose trailing directory name matches the requested skill name before giving up.
Extends Superpowers skills library to GitHub Copilot, following the successful pattern established by the .codex integration. Makes all 20 core skills available to GitHub Copilot users across VS Code, IntelliJ, Visual Studio, and other supported IDEs.
New .copilot/ directory includes:
Key features:
Also updated:
Status: Experimental - requires user feedback and testing
Motivation and Context
How Has This Been Tested?
Breaking Changes
Types of changes
Checklist
Additional context
Summary by CodeRabbit
Release Notes
New Features
Documentation