Skip to content

Comments

Fix #1658: --ai-skills flag not working for GitHub Copilot and other agents#1660

Merged
mnriem merged 1 commit intogithub:mainfrom
mnriem:fix/issue-1658-ai-skills-copilot
Feb 21, 2026
Merged

Fix #1658: --ai-skills flag not working for GitHub Copilot and other agents#1660
mnriem merged 1 commit intogithub:mainfrom
mnriem:fix/issue-1658-ai-skills-copilot

Conversation

@mnriem
Copy link
Collaborator

@mnriem mnriem commented Feb 21, 2026

Issue

Fixes #1658

Problem

When users ran specify init --ai copilot --ai-skills, the skills installation failed with "command templates not found" error. This affected multiple agents with non-standard directory structures.

Root Cause

The install_ai_skills() function hardcoded "commands" as the subdirectory name, but 7 agents use different names:

  • copilot: .github/agents/
  • opencode: .opencode/command/ (singular)
  • windsurf: .windsurf/workflows/
  • codex: .codex/prompts/
  • kilocode: .kilocode/workflows/
  • q (Amazon Q): .amazonq/prompts/
  • agy (Antigravity): .agent/workflows/

Solution

Added a commands_subdir field to AGENT_CONFIG that explicitly specifies the subdirectory name for each agent. The install_ai_skills() function now reads this field instead of assuming "commands".

Changes

  • ✅ Added commands_subdir field to all agents in AGENT_CONFIG
  • ✅ Updated install_ai_skills() to use the new field
  • ✅ Updated AGENTS.md documentation
  • ✅ Bumped version to 0.1.5
  • ✅ Added changelog entry

Testing

  • All 51 existing tests pass
  • Tested with all 18 configured agents
  • Skills directory resolution works correctly for all agents

Breaking Changes

None - this is a bug fix that makes existing functionality work as intended.

…ent directory structures

- Added commands_subdir field to AGENT_CONFIG for all agents
- Updated install_ai_skills() to use commands_subdir instead of hardcoded 'commands'
- Fixed --ai-skills flag for copilot, opencode, windsurf, codex, kilocode, q, and agy
- Bumped version to 0.1.5
- Updated AGENTS.md documentation with new field

Affected agents now correctly locate their command templates:
- copilot: .github/agents/
- opencode: .opencode/command/ (singular)
- windsurf: .windsurf/workflows/
- codex: .codex/prompts/
- kilocode: .kilocode/workflows/
- q: .amazonq/prompts/
- agy: .agent/workflows/

All 51 tests pass.
Copilot AI review requested due to automatic review settings February 21, 2026 14:01
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR fixes issue #1658 where the --ai-skills flag failed for GitHub Copilot and other agents with non-standard command directory structures. The root cause was that the install_ai_skills() function hardcoded "commands" as the subdirectory name, but 7 agents use different names (copilot uses "agents", opencode uses "command", windsurf/kilocode/agy use "workflows", and codex/q use "prompts").

The solution adds a commands_subdir field to the AGENT_CONFIG dictionary that explicitly specifies the subdirectory name for each agent, and updates install_ai_skills() to read this field instead of assuming "commands".

Changes:

  • Added commands_subdir field to all 19 agents in AGENT_CONFIG with agent-specific subdirectory names
  • Updated install_ai_skills() function to use the new commands_subdir field from agent configuration
  • Updated AGENTS.md documentation to explain the new field and its usage
  • Bumped version from 0.1.4 to 0.1.5 and added comprehensive changelog entry

Reviewed changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated no comments.

File Description
src/specify_cli/init.py Added commands_subdir field to all agents in AGENT_CONFIG; updated install_ai_skills() to use the field
pyproject.toml Bumped version from 0.1.4 to 0.1.5
CHANGELOG.md Added detailed changelog entry for version 0.1.5 describing the fix
AGENTS.md Updated documentation to explain the new commands_subdir field and its usage

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@mnriem mnriem merged commit 6f523ed into github:main Feb 21, 2026
12 checks passed
@mnriem mnriem deleted the fix/issue-1658-ai-skills-copilot branch February 21, 2026 14:06
@dhilipkumars
Copy link
Contributor

Thanks @mnriem for the quick fix.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug]: --ai-skills does not generate skill files with --ai copilot.

2 participants