1. brindle
  2. Docs
  3. Connect GitHub

Connect GitHub

Give brindle its own GitHub sign-in for background fetches and agents' git commands.

Connect and check

On macOS, git's keychain helper can show a dialog when another tool saved the password. Connecting GitHub lets brindle answer git itself for github.com.

brindle github connect
brindle github connect --token
brindle github status
brindle github disconnect

The default copies your GitHub CLI sign-in if gh is signed in: the same repository access as gh, with no expiry. gh's keychain item is read once at your request; a locked keychain may ask to unlock then. A fine-grained token reaches only the repositories you choose until it expires. Give it Contents, Pull requests and Workflows read/write; Metadata read comes with them. An organization may need to approve it.

Where it applies

brindle's credential helper answers git for https://github.com in background fetches, clones, pushes, named-branch fetches and agents' panes. Other helpers are left out for that host. Other hosts, GitHub Enterprise Server and SSH remotes are untouched. No git config file is edited; gh itself keeps its own sign-in.

Where the token lives

With the desktop app's signed daemon, the token is in a keychain item created and read by that helper; other brindle processes ask the daemon. macOS asks before giving the item to another program. Reads raise no dialog: while the keychain is locked, brindle cannot sign in and fetches wait. A CLI install without that helper, or --file, uses a 0600 file under ~/.brindle, readable by anything running as you. brindle github status reports which storage is in use.

Expired or revoked access

If GitHub rejects the credential, brindle asks you to reconnect. Until then fetches and pushes to github.com fail plainly; it does not silently restore other helpers or switch accounts. Disconnecting restores your helpers and forgets brindle's copy. It revokes nothing on GitHub: delete the token there yourself.

Credential access boundary

Agents run as your OS user. Permission rules deny recognized credential-reading commands, but they are not a sandbox: an unrecognized command could read the file or ask the daemon as git does. A fine-grained token for selected repositories limits the value of a taken credential compared with a copy of gh's sign-in. Codex's sandbox denies its commands access to the file; git under it gets the credential from the daemon.