gh-auth-isolation

Detect the active GitHub identity and isolate tokens across EMU and personal accounts.

1|Updated Apr 17, 2026
One-click install
npx skills add https://github.com/sudhakrms/CalendarControl --skill gh-auth-isolation-sudhakrms
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: gh-auth-isolation
Source: https://github.com/sudhakrms/CalendarControl/tree/main/coffee/.copilot/skills/gh-auth-isolation
Command: npx skills add https://github.com/sudhakrms/CalendarControl --skill gh-auth-isolation-sudhakrms

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Active gh authentication often binds agents to the enterprise account, causing failures when operations must run under a personal GitHub identity or a different user. This disconnect leads to permission errors and accidental cross-account changes.

Core Features & Use Cases

  • Detect Current Identity: verify the active gh account and token scopes before performing any operation.
  • Token-based context switching: extract a specific account's token to perform a one-off operation without changing the default identity.
  • Config isolation and quick switching: use separate gh config directories and shell aliases to isolate EMU and personal accounts.
  • Use Case: push or create a PR from a personal fork while the default context remains EMU, without leaking credentials.

Quick Start

Configure a dedicated gh config for your personal account and verify the active identity before performing any operations.

Frequently Asked Questions about gh-auth-isolation

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

FAQPage Schema
How do I switch GitHub accounts in a workflow without leaking credentials?

Preventing cross-account GitHub operations involves isolating the active identity by using separate gh config directories and extracting specific account tokens for one-off tasks, ensuring the default context remains unchanged without persisting credentials.

How do I push to a personal fork when my default gh context is an enterprise account?

You can push to a personal fork by extracting the personal account's token to perform the operation without changing your default enterprise identity, utilizing config isolation and shell aliases for safe execution.

How does token extraction work for multi-account GitHub identity management?

Token extraction for multi-account identity management retrieves a specific GitHub account's token to execute a targeted operation, preventing cross-account changes while keeping the default gh authentication context intact.

Can I isolate EMU and personal GitHub accounts using separate gh config directories?

Yes, you can isolate EMU and personal GitHub accounts by configuring dedicated gh config directories and using shell aliases to quickly switch between contexts, preventing permission errors and accidental cross-account changes.

Why does my GitHub workflow fail with permission errors across different user identities?

GitHub workflows fail with permission errors when active gh authentication binds operations to an enterprise account, causing failures when actions must run under a personal GitHub identity or a different user without proper config isolation.