Read user instructions in ~/.github
Describe the feature or problem you'd like to solve
copilot read repository custom instructions. I'd like it to read local instructions about my local preferences too
Proposed solution
read ~/.github/instructions.md or something
Example prompts or workflows
No response
Additional context
No response
As far as I know (and I have also verified this), the Copilot CLI currently reads the $HOME/.copilot/copilot-instructions.md file. You can see this mentioned by running /help in the Copilot CLI (although I haven't found any other documentation that explains this).
Respects instructions sourced from various locations:
`.github/instructions/**/*.instructions.md` (in git root and cwd)
`.github/copilot-instructions.md`
`AGENTS.md` (in git root and cwd)
`CLAUDE.md`
`GEMINI.md`
`$HOME/.copilot/copilot-instructions.md`
Additional directories via `COPILOT_CUSTOM_INSTRUCTIONS_DIRS`
All the docs specify a hierarchy for how it reads instructions:
~/.github/{agents/prompts/instructions/skills}/*.md
And that it uses $HOME/.github/** for globally accessible instructions
<repository>/.github/* for repository instructions
It even says so if i ask it how i should configure my agents.
But, Copilot CLI doesnt find any global agents (only tested with ~/.github/agents/*.agent.md folder)
If i ask it to troubleshoot, it says it sees the file, but that its in the wrong format and should me YAML instead of MD. But even after it converts the .MD file to yaml file, it still doesnt show up as an available agent. (yes, restarts have been done)
Steps to reproduce:
Create a new agent at ~/.github/agents/my-agent.agent.md
Run copilot and type /agent to list available options:
Expected result: Agent "my-agent" is listed
Actual results:
No available custom agents
when I ask copilot-cli to write instructions, it writes them at the right place, but it often forget to read them at startup
the doc says ".github/..." and "~/.copilot/" (as stated by @imkuang). but still copilot writes down to "`~/.github/" and don't read from there, unless asked to