feat(cli): add /install-github-app for gh CLI setup#181
Merged
emal-avala merged 1 commit intomainfrom Apr 23, 2026
Merged
Conversation
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
0c59034 to
5c8ed26
Compare
Interactive walkthrough that checks gh install status, auth state, required scopes (repo / read:org / workflow), and whether the current directory has a GitHub remote. Surfaces a one-line summary with the next action the user must take. Rules baked in: - never install gh silently — point to instructions, user runs it - interactive login needs a TTY the agent doesn't own — instruct the user to run `gh auth login` themselves - never store tokens in this process - never exfiltrate `gh auth token` output - refuse if asked to write the token to a file Alias /gh-setup for people who don't remember the full command.
5c8ed26 to
7302820
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds
/install-github-app(alias/gh-setup) — walks the user through gh CLI installation, auth, scopes, and remote verification for the PR-related commands (/pr-comments,/autofix-pr,/issue).Checks performed:
gh --version— is it installed?gh auth status— logged in?repo,read:org,workflow?gh repo view— does cwd have a GitHub remote?Guardrails in the prompt:
gh auth loginfor the user (needs a TTY the agent doesn't own)Why
Running
/pr-commentsor/autofix-prwithout gh set up correctly is the most common first-run failure — and the error messages from gh aren't great at saying which scope is missing. This does the diagnosis in one invocation.Test plan
cargo fmt --allcleancargo checkpassescargo clippy --no-depsclean/install-github-app→ reports 'gh not installed', points to install docsgh auth refreshcommand