github-auth

github-auth is a skill for Claude Code, Codex from AmineDjeghri/personal-os-setup. It costs 24 tokens per session (1,345 once invoked), scanned D, a copy of github-auth, MIT.

A setup guide for authenticating with GitHub through Git or the GitHub command-line tool. Authentication proves your identity so an agent can access repositories, pull requests, issues, and continuous-integration jobs.

In plain words
What is it for?
Use it to check GitHub login status and configure Git or the gh command-line tool for repository, pull-request, issue, and CI work.
Why use it?
It checks what tools and credentials are already available, then guides setup with HTTPS tokens, SSH keys, or the GitHub CLI. This avoids failed repository operations caused by missing login configuration.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Use it to check GitHub login status and configure Git or the gh command-line tool for repository, pull-request, issue, and CI work.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/aminedjeghri/personal-os-setup/github-auth
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add AmineDjeghri/personal-os-setup --skill github-auth
Clone the repo
git clone --depth 1 https://github.com/AmineDjeghri/personal-os-setup

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for github-auth

README.md
[![agentmods](https://agentmods.dev/badge/skills/aminedjeghri/personal-os-setup/github-auth/github.svg)](https://agentmods.dev/skills/aminedjeghri/personal-os-setup/github-auth)
Your own site
<a href="https://agentmods.dev/skills/aminedjeghri/personal-os-setup/github-auth"><img src="https://agentmods.dev/badge/skills/aminedjeghri/personal-os-setup/github-auth/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for github-auth

Your own site · 80×15
<a href="https://agentmods.dev/skills/aminedjeghri/personal-os-setup/github-auth"><img src="https://agentmods.dev/badge/skills/aminedjeghri/personal-os-setup/github-auth.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 24 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,345 The whole file, excluding the scripts and references it only reads on demand.
Security scan D 3 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin 80% copy Near-identical to another mod in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00024 $0.01345
Opus 5.5 $0.00010 $0.00538
Sonnet 5.5 $0.00005 $0.00269
Haiku 4.5 $0.00002 $0.00135

Measured 1mo ago against content hash cb76b9406a76, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade D, and why

github-auth scanned grade D with 3 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 1mo ago.

The scan reads SKILL.md. This mod also ships 1 executable file (scripts/gh-env.sh), listed below but not scanned — reading those needs a real analyzer, not pattern matching.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Asks for rootmediumPrivilege escalation

A mod that escalates privileges can change anything on the machine, not only the project.

### Installing `gh` (no sudo needed on any platform)

Reaches for credential fileshighPrivilege escalation

SSH keys, cloud credentials, git-credentials, .npmrc, /etc/shadow: reading these is how a config file becomes a credential leak.

ssh-keygen -t ed25519 -C "[email protected]" -f ~/.ssh/id_ed25519 -N "" # then add ~/.ssh/id_ed25519.pub at https://github.com/settings/keys

Makes network callslowCapability

Not a fault in itself. Listed so you know the mod talks to something, and to what.

curl -fsSL https://github.com/cli/cli/releases/latest/download/gh_*_linux_amd64.tar.gz \
Origin

This is a copy

80% identical to github-auth — 243 lines differ, which has more behind it and is treated as the original. This page carries a canonical link to it rather than competing with it.

src/personal_os_setup/config/chezmoi/dot_claude/skills/github-auth/SKILL.md · 135 lines

How it starts

The opening of the file, as written. The whole thing — 135 lines — stays where its author put it; the contents beside it link to each section on GitHub.

GitHub Authentication Setup

gh CLI is the default path — ask to install it if it's missing, don't reach for a personal access token instead. A PAT/SSH key (Method 2) is only for when gh genuinely cannot be installed.

Detection Flow

When a user asks you to work with GitHub, run this check first:

# Check what's available
git --version
gh --version 2>/dev/null || echo "gh not installed"

# Check if already authenticated
gh auth status 2>/dev/null || echo "gh not authenticated"

Decision tree:

  1. gh auth status shows authenticated → use gh for everything.
  2. gh is installed but not authenticated → "Method 1: gh CLI" below.
  3. gh is not installed → ask to install it first, then go to step 2. Only fall through to "Method 2: Git-only" if installation genuinely isn't possible (no package manager, no network access to fetch the binary, no permission to execute a downloaded binary at all).

Installing gh (no sudo needed on any platform)

# Linux: prebuilt binary, no root — extract and add to PATH
curl -fsSL https://github.com/cli/cli/releases/latest/download/gh_*_linux_amd64.tar.gz \
  | tar -xz -C ~/.local --strip-components=1   # lands at ~/.local/bin/gh
gh --version
# Linux package managers — pick one (Debian/Ubuntu may need the cli.github.com apt repo):
sudo apt install gh
sudo dnf install gh
sudo pacman -S github-cli
brew install gh                  # macOS
winget install --id GitHub.cli   # Windows

Method 1: gh CLI Authentication

If gh is installed (see above if it isn't), it handles both API access and git credentials in one step — this is the default for every scenario, interactive or headless.

Login (browser or device code)

gh auth login   # GitHub.com -> HTTPS -> Login with a web browser; prints a one-time code for github.com/login/device
gh auth setup-git   # link the authentication to git

Agent Pattern: Since this is interactive, run it in the background and redirect output to a log file (e.g., gh auth login > /tmp/gh_auth.log 2>&1) using terminal(background=true). This allows the agent to retrieve and share the device code with the user without blocking the session.

Read the full file on GitHub · 135 lines

Files

What ships with it

2 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 1mo ago Changed cb76b9406a76
  2. 1mo ago Changed · -124 lines scan F → D 19c7432ee678
  3. 2mo ago Changed · +1 lines · +6 tokens per session ed7c1a1c5142
  4. 2mo ago First seen · 258 lines · 18 tokens per session scan F 1490efb2ed77

Subscribe to this mod's changes

github-auth is a skill published in the GitHub repository AmineDjeghri/personal-os-setup (687 stars, last pushed today), licensed MIT. It adds 24 tokens to every session and 1,345 once invoked, about $0.0001 per session on Opus 5.5. A static security scan graded it D with 3 findings (asks for root, reaches for credential files, makes network calls). It is 80% identical to github-auth, differing in 243 lines, and is treated as a copy.

Related

github-auth compared with skills from other repositories

github-auth next to 6 skills from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
github-authAmineDjeghri/personal-os-setupSkill687todayMITD24Claude Code, Codex
hula-skillHuLaSpark/HuLaSkill7.9k6d agoApache-2.0A86Claude Code, Codex
pr-monitorantropos17/AegisSkill1625d agoMITA25Claude Code, Codex
commit-and-trackantropos17/AegisSkill1625d agoMITA34Claude Code, Codex
shipantropos17/AegisSkill1625d agoMITA29Codex
flow-launcheralivirgo/Major-AI-SkillsSkill6yesterdayMITA26Claude Code
microsoft-powertoysalivirgo/Major-AI-SkillsSkill6yesterdayMITA30Claude Code