SKILL.md
$27
- User-level:
~/.copilot/lsp-config.json
- Repo-level:
lsp.json(repo root) or.github/lsp.json
The JSON structure:
{
"lspServers": {
"<server-key>": {
"command": "<binary>",
"args": ["--stdio"],
"fileExtensions": {
".<ext>": "<languageId>",
".<ext2>": "<languageId>"
}
}
}
}
Key rules
commandis the binary name (must be on$PATH) or an absolute path.
argsalmost always includes"--stdio"to use standard I/O transport.
fileExtensionsmaps each file extension (with leading dot) to a Language ID.
- Multiple servers can coexist in
lspServers.
- When merging into an existing file, never overwrite other server entries — only add or update the target language key.
Behavior
- Always use
ask_userwithchoiceswhen asking the user to pick a language or scope.
- If the language is not listed in
references/lsp-servers.md, search the web for " LSP server" and guide the user through manual configuration.
- If a package manager is not available (e.g. no Homebrew on macOS), suggest alternative install methods from the reference file.
- After installation, run
which <binary>(orwhere.exeon Windows) to confirm the binary is accessible.
- Show the user the final config JSON before writing it.
- If the config file already exists, read it first and merge — do not clobber.
Verification
After setup, tell the user:
- Type
/exitto quit Copilot CLI — this is required so the new LSP configuration is loaded on next launch
- Re-launch
copilotin a project with files of the configured language
- Run
/lspto check the server status
- Try code intelligence features like go-to-definition or hover