Custom agents not appearing in dropdown unless agent files are open in editor
還沒有人認領這個 Issue。
評估
- 難度
- 4/5
- 預估耗時
- 3-5 天
- 新手友好度
- 38/100
- Issue 類型
- 缺陷
- 描述清晰度
- 描述清楚
- 活躍度
- 停滯
- 技術堆疊
- swift
- 領域
- desktop-dev, tooling
研究方向
Reproduce the issue with a valid .github/agents/my-custom-agent.agent.md file, then compare the agent dropdown before and after opening the file in Xcode. Trace how custom agents are discovered and loaded when Copilot Chat opens, and consider the reported expected behavior complete when agents remain available after the file is closed.
由索引模型根據 Issue 內容生成。
描述
Description
Custom agents defined in .github/agents/ are not appearing in the Copilot chat agent dropdown in Xcode unless the agent file itself is currently open in a window/editor tab.
Expected Behavior
Custom agents should be automatically discovered and loaded from the .github/agents/ directory when:
Opening Xcode with a project
Opening Copilot Chat
Creating a new custom agent file
This is how custom agents work in VS Code - they appear in the dropdown automatically without requiring the files to be open.
Actual Behavior
Custom agents only appear in the Copilot chat dropdown when their corresponding .agent.md files are open in the Xcode editor. Once the file is closed, the agent disappears from the dropdown.
Steps to Reproduce
Create a custom agent file in .github/agents/ (e.g., my-custom-agent.agent.md)
Add valid YAML frontmatter and agent content:
---
name: my-custom-agent
description: Test custom agent
---
You are a helpful assistant.
Save the file and close it
Open Copilot Chat in Xcode
Click the agent dropdown at the bottom of the chat view
Result: The custom agent does NOT appear in the list
Now open the my-custom-agent.agent.md file in Xcode (in any window/tab)
Check the agent dropdown again
Result: The custom agent NOW appears in the dropdown
Environment
Copilot for Xcode version: [latest as of January 2026] (0.46.159)
Xcode version: 26.2 (17C52)
macOS version: 26.2 (25C56)
GitHub Copilot subscription: [Pro/Business/Enterprise]
Additional Context
The custom agent files are in the correct location (.github/agents/)
Files use the correct .agent.md extension
The .github folder is NOT ignored by .gitignore
The same custom agents work perfectly in VS Code without needing to open the files
No target property is set (or it's set to allow all IDEs)
This behavior is consistent across multiple custom agents
Verification Checklist
I have verified the following:
✅ Agent files are in .github/agents/ directory
✅ Files use .agent.md extension
✅ YAML frontmatter is valid
✅ .github folder is not git-ignored
✅ Latest version of Copilot for Xcode is installed
✅ Same agents work in VS Code
✅ No target: vscode property restricting the agent to VS Code only
Impact
This bug requires developers to keep all custom agent files open in editor tabs to use them, which:
Clutters the workspace
Defeats the purpose of having reusable, discoverable agents
Creates inconsistent behavior compared to VS Code
Makes custom agents essentially unusable in Xcode workflows
Suggested Fix
Copilot for Xcode should implement proper file system watching/indexing to automatically discover and load custom agents from .github/agents/ without requiring the files to be open in the editor, matching the behavior in VS Code and other supported IDEs.
- 主要語言
- Swift
- 星號
- 6.3k
- 分支
- 2k
- 平均合併
- 3 天 21 小時
- 30 天內合併 PR
- 2
貢獻指南
從這裡開始
- 先讀完整個 Issue,再讀專案的貢獻指南。
- 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
- Fork 儲存庫,在一個分支上完成修改。
- 送出 Pull Request,並在描述裡引用這個 Issue 編號。
github/CopilotForXcode 的其他 Issue
-
難度 1/5 1 小時以內 新手友好度 85/100
github/CopilotForXcode#181 · 2 個 reaction ·
-
Add ability to attach Copilot window only to Xcode projects/workspaces, ignoring standalone files 未關閉
難度 3/5 1-2 天 新手友好度 68/100
github/CopilotForXcode#945 ·
-
難度 2/5 1-3 小時 新手友好度 35/100
github/CopilotForXcode#943 ·
-
難度 5/5 一週以上 新手友好度 10/100
github/CopilotForXcode#936 · 2 則留言 ·
-
難度 5/5 一週以上 新手友好度 10/100
github/CopilotForXcode#934 ·
查看 github/CopilotForXcode 的全部 Issue
相似的 Issue
-
難度 2/5 1-3 小時 新手友好度 75/100
-
難度 2/5 1-3 小時 新手友好度 75/100
-
難度 2/5 1-3 小時 新手友好度 75/100
maxgoedjen/secretive#840 ·
-
難度 2/5 1-3 小時 新手友好度 88/100
manaflow-ai/cmux#13763 ·
-
難度 2/5 1-3 小時 新手友好度 75/100
openwallet-foundation/multipaz#2028 ·