← sources

Claude code tried to use my installed Github cli (gh) without asking permission...is this expected?

source: reddit (reddit:ClaudeCode)published 2026-11-01 03:20ingested 2026-11-02 02:41

retained text

I noticed Claude Code attempting to run the following command through my github cli (`gh`):

    gh issue list -R anthropics/claude-code --author u/me --state closed --search closed:>2026-09-20 --json number,title,closedAt,stateReason --limit 30

I hadn’t explicitly asked it to look up my Github issues... and I didn’t see a permission prompt before the attempt. I’m not sure whether the command actually completed.

Is this expected behavior? Can Claude Code use an existing `gh` authentication session automatically, and which permission settings control that?

Has anyone else seen this particular query or knows what might trigger it? I’d like to understand why it was checking my closed issues and whether this is normal behavior or something I should report.

**EDIT:** I’m editing this because I can see that some people haven’t understood. Claude isn’t doing this on autopilot, nor am I asking him to do anything, nor is he working with a sub-agent. I haven’t asked him to do anything at all, nor is there anything pending; he’s doing this entirely of his own accord.

document fetched 2026-11-02 00:36 · canonical https://reddit.com/r/ClaudeCode/comments/1xksutq/claude_code_tried_to_use_my_installed_github_cli