Copilot: Difference between revisions

From Omnia
Jump to navigation Jump to search
 
(3 intermediate revisions by the same user not shown)
Line 1: Line 1:
== Copilot CLI ==
== Subpages ==


1. Install GitHub CLI
{{Special:PrefixIndex/{{PAGENAME}}/|hideredirects=1}}


Choose the command for your operating system:
== Copilot CLI ==


macOS:
See [[Copilot/CLI]]
brew install gh


Windows (Winget):
== ask_user tool ==
winget install GitHub.cli


Windows (Scoop):
: I'll note to use the '''ask_user tool''' for open-ended questions going forward...
scoop install gh


Linux (Ubuntu/Debian):
sudo apt install gh


Linux (Fedora/RHEL):
: "Can you save to my profile, or user setting to *always* use the 'ask_user tool' when you ask me a question, and to always provide a "open ended" option please
sudo dnf install gh
* "Good — I'll wire that in as a standing rule. Let me check where user-level (not repo-level) preferences belong for this CLI. "
* $HOME/.copilot/copilot-instructions.md  is the user-level (all-repos) instructions file — it doesn't exist yet, so I'll create it.


---
== profile copilot-instructions.md ==


2. Authenticate:
  $HOME/.copilot/copilot-instructions.md
gh auth login
 
---
 
3. Install the Copilot Extension:
  gh extension install github/gh-copilot
 
---
 
4. Update the Extension (Optional)
gh extension upgrade gh-copilot
 
---
 
5. Use the CLI
gh copilot explain "command"
 
gh copilot suggest "what you want to do"
 
If you want, I can help you set up aliases (like ?? or git?) to make triggering Copilot suggestions much faster in your shell. Let me know if you use Bash, Zsh, or PowerShell.
 
---
 
References
* https://docs.github.com/en/copilot/how-tos/copilot-cli/set-up-copilot-cli/install-copilot-cli
* https://www.linkedin.com/posts/github_have-you-tried-github-copilot-in-the-cli-activity-7179897577172074496-jw4T
* https://www.linkedin.com/posts/juliangoldieseo_new-github-copilot-cli-is-insane-activity-7377931244484964352-mr2Y
* https://itnext.io/getting-started-with-github-copilot-66fb63c88cbe
* https://apito.ai/en/blog/tools/github-copilot-claudeapi-byok-setup/
* https://www.promptfu.com/blog/github-copilot-cli-mastery-guide/
 
=== Set Model ===
 
Set Model:
/config model claude-opus-5


Common options:
== $HOME/.copilot/copilot-instructions.md ==
* claude-opus-5
* claude-sonnet-4.5
* claude-haiku-4.5


<pre>
# User Standing Instructions (Kenneth)


Set effort level: ("Reasoning effort for models that support it")
These are profile-wide preferences. They apply in every repository and every session,
/config effortLevel xhigh
and take precedence over default response habits. Repository-specific instructions
  options: none, minimal, low, medium, high, xhigh, max
still govern their own domain (coding standards, branch naming, project workflows).


Calude Opus 5 supports effort levels, but Claude Sonnet 4.5 and Claude Haiku 4.5 do not
## Asking Questions


=== Multi-Line ===
**Always use the `ask_user` tool to ask me a question.** Never ask a question in plain
response text and then stop, and never end a response with a bare question expecting me
to answer in chat. If you need input, a decision, a preference, or a clarification —
present it through `ask_user` so it renders as a structured form.


Use: Ctrl+g to bring up vim
This applies to every kind of question, including:


Or alt+enter
- Choosing between implementation approaches
- Confirming a destructive or hard-to-reverse action before taking it
- Resolving ambiguous requirements or unclear scope
- Asking where output should go, or what to do next
- Single yes/no confirmations (a one-field form is fine)


Note: shift+enter does not work
**Always include an open-ended option.** Every `ask_user` form must give me a way to
answer in my own words rather than forcing a pick from your list. Concretely:


== ask_user tool ==
- Add a final free-text field — typically `other`, titled something like
  "Something else / in my own words", with a description inviting a freeform answer
  and making clear it overrides the structured selections above.
- For a single-choice field, also include an escape-hatch option in the `enum`/`oneOf`
  list itself (for example "Something else — I'll explain") so the open-ended path is
  visible at the point of choosing, not only in a separate field.
- Never present a closed set of options as if it were exhaustive. Your options are
  suggestions, not a menu I am confined to.


: I'll note to use the '''ask_user tool''' for open-ended questions going forward...
**Recommend, don't just enumerate.** State which option you'd pick and why, then set it
as the `default`. I would rather correct a considered recommendation than arbitrate a
neutral list.


**Batch related questions.** If several decisions belong to the same topic, put them in
one form rather than asking serially. Keep unrelated topics in separate forms.


: "Can you save to my profile, or user setting to *always* use the 'ask_user tool' when you ask me a question, and to always provide a "open ended" option please
**Respect a declined or cancelled form.** If I decline, proceed with the stated defaults
* "Good — I'll wire that in as a standing rule. Let me check where user-level (not repo-level) preferences belong for this CLI. "
and say which ones you used. Do not immediately re-ask the same question.
* $HOME/.copilot/copilot-instructions.md  is the user-level (all-repos) instructions file — it doesn't exist yet, so I'll create it.
</pre>
 
== profile copilot-instructions.md ==
 
$HOME/.copilot/copilot-instructions.md


== keywords ==
== keywords ==

Latest revision as of 19:58, 14 September 2026

Subpages

Copilot CLI

See Copilot/CLI

ask_user tool

I'll note to use the ask_user tool for open-ended questions going forward...


"Can you save to my profile, or user setting to *always* use the 'ask_user tool' when you ask me a question, and to always provide a "open ended" option please
  • "Good — I'll wire that in as a standing rule. Let me check where user-level (not repo-level) preferences belong for this CLI. "
  • $HOME/.copilot/copilot-instructions.md  is the user-level (all-repos) instructions file — it doesn't exist yet, so I'll create it.

profile copilot-instructions.md

$HOME/.copilot/copilot-instructions.md

$HOME/.copilot/copilot-instructions.md

# User Standing Instructions (Kenneth)

These are profile-wide preferences. They apply in every repository and every session,
and take precedence over default response habits. Repository-specific instructions
still govern their own domain (coding standards, branch naming, project workflows).

## Asking Questions

**Always use the `ask_user` tool to ask me a question.** Never ask a question in plain
response text and then stop, and never end a response with a bare question expecting me
to answer in chat. If you need input, a decision, a preference, or a clarification —
present it through `ask_user` so it renders as a structured form.

This applies to every kind of question, including:

- Choosing between implementation approaches
- Confirming a destructive or hard-to-reverse action before taking it
- Resolving ambiguous requirements or unclear scope
- Asking where output should go, or what to do next
- Single yes/no confirmations (a one-field form is fine)

**Always include an open-ended option.** Every `ask_user` form must give me a way to
answer in my own words rather than forcing a pick from your list. Concretely:

- Add a final free-text field — typically `other`, titled something like
  "Something else / in my own words", with a description inviting a freeform answer
  and making clear it overrides the structured selections above.
- For a single-choice field, also include an escape-hatch option in the `enum`/`oneOf`
  list itself (for example "Something else — I'll explain") so the open-ended path is
  visible at the point of choosing, not only in a separate field.
- Never present a closed set of options as if it were exhaustive. Your options are
  suggestions, not a menu I am confined to.

**Recommend, don't just enumerate.** State which option you'd pick and why, then set it
as the `default`. I would rather correct a considered recommendation than arbitrate a
neutral list.

**Batch related questions.** If several decisions belong to the same topic, put them in
one form rather than asking serially. Keep unrelated topics in separate forms.

**Respect a declined or cancelled form.** If I decline, proceed with the stated defaults
and say which ones you used. Do not immediately re-ask the same question.

keywords