github-auth

Configure GitHub authentication using personal access tokens, SSH keys, or the gh CLI.

33|1|Updated Mar 4, 2026
One-click install
npx skills add https://github.com/infinition/LaRuche --skill github-auth-infinition
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: github-auth
Source: https://github.com/infinition/LaRuche/tree/main/laruche/skills/github-auth
Command: npx skills add https://github.com/infinition/LaRuche --skill github-auth-infinition

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) components.

What problem does it solve? GitHub authentication failures masquerade as unrelated errors: pushes that ask for passwords, gh commands returning 404 on existing repositories, and workflows that cannot be triggered. This Skill diagnoses the current authentication state and sets up the correct method without requiring installs or admin rights. ## Core Features & Use Cases - State Detection: Inspects existing git, gh CLI, and credential helper configuration before changing anything, via a sourceable shell helper that reports the active auth method. - Three Auth Paths: Configures HTTPS with a personal access token, SSH keys with ed25519, or the gh CLI, including headless token-based login and git credential setup. - Failure Diagnosis: Maps common errors like stale cached credentials, under-scoped tokens, blocked port 22, and multi-account SSH conflicts to concrete fixes. - Use Case: A push to a private repository keeps prompting for a password. The Skill detects no credential helper is configured, sets one up, stores the vault token, and verifies access against the private repo. ## Quick Start Check my GitHub authentication state and set up access so I can push to my private repository.

Frequently Asked Questions about github-auth

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I authenticate git push to GitHub without a password?▼

GitHub removed password authentication, so the password prompt expects a personal access token. Configure a credential helper with git config --global credential.helper store, then run git ls-remote and enter the token when prompted.

How to set up SSH keys for GitHub authentication?▼

Generate a key with ssh-keygen -t ed25519, add the public .pub file at github.com/settings/keys, then test with ssh -T git@github.com. The success message ends with 'GitHub does not provide shell access' and exits non-zero, which is normal.

Why does git push ask for a password when gh CLI is authenticated?▼

The gh CLI authentication does not automatically configure git. Run gh auth setup-git after gh auth login so plain git commands use the same credentials as gh.

Can I use GitHub API without installing the gh CLI?▼

Yes, any GitHub API call works with curl and a token: curl -H "Authorization: Bearer $GITHUB_TOKEN" https://api.github.com/user. Both the Bearer and older token authorization schemes are accepted.

Why does my GitHub token return 'Permission denied' on my own repository?▼

The token is valid but under-scoped. Classic tokens need the repo scope for code, pull requests, and issues. Fine-grained tokens must explicitly list each repository, and a missing repository produces a 404 rather than a permission error.

How do I fix SSH connection refused on port 22 for GitHub?▼

Networks that block port 22 can use SSH over port 443. Add a Host github.com entry to ~/.ssh/config with Hostname ssh.github.com and Port 443, then retry the connection.