用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
直接命令不会经过审查 Prompt;运行前请先检查来源。
npx skills add https://github.com/nathanvale/claude-code-config --skill lll-account-switch命令会保持在同一行。复制前请横向滚动并检查完整内容。
想先保存到本地?可下载 SkillsMP 当前能够提供的文件。
正在显示 SKILL.md
| name | lll-account-switch |
| description | Switch lll-account-switch personal/foundry Claude/Codex routing for local development. |
| role | tool-workflow |
Switch which account serves claude / codex through lll-account-switch.
Accounts: personal (Anthropic / Codex) and foundry (SMST Azure Foundry).
Local-development skill: works on this machine because the dotfiles owners below exist. Treat other machines as unsupported unless they have the same owner paths and account registry.
$HOME/code/dotfiles/bin/lll-account-switch status --json; read health[] before any switch.ok, global_account, global_accounts, profile_dirs, repos[], health[], next_action.$HOME/code/dotfiles/bin/lll-account-switch status --json | jq '.ok' after any switch.Landing Page. Never stop at the dashboard alone.lll-account-switch is unavailable, run bash skills/lll-account-switch/scripts/lll-account-switch-status.sh from this repo. Treat fallback output as read-only diagnostics; it does not own switching, repo init, JSON envelopes, health codes, or next-action state.After rendering the routing table, always present a status-driven menu. Pick the branch that matches the current status JSON:
When health[] is non-empty:
Health issue:
<code>-<message>
- Fix:
<repair_hint>(human action required)- Explain why routing chose this provider
- Switch account anyway (risky while unhealthy)
When ok: true and user gave no specific ask:
- All healthy - nothing to do
- Explain why routing chose a provider for this repo
- Switch global account (personal <-> foundry)
- Switch repo override for this repo
DX lens: present choices as a short numbered list so the user can reply by number. Bold the recommended default. Never present more than 4 options. When status makes the next step obvious, state what you are doing and proceed unless the user redirects.
repair_hint.
For REPO_NO_ENVRC: run $HOME/code/dotfiles/bin/lll-account-switch repo init --repo <path>.
For auth codes (AZURE_SESSION_INVALID, OP_NOT_*): surface hint; do not run.$HOME/code/dotfiles/bin/lll-account-switch explain --repo <path> --tool <claude|codex|both>.$HOME/code/dotfiles/bin/lll-account-switch use <personal|foundry> [--tool <claude|codex|both>].
Dry-run first when target state is unclear: add --dry-run.$HOME/code/dotfiles/bin/lll-account-switch repo use <personal|foundry> --repo <path> --tool <claude|codex|both>.
Dry-run first when target state is unclear: add --dry-run.| Code | Human action | Agent action |
|---|---|---|
AZURE_SESSION_INVALID | Run az login | Surface hint; do not run |
OP_NOT_AVAILABLE / OP_NOT_AUTHENTICATED | Install / sign in to 1Password CLI | Surface hint; do not run |
STALE_SNAPSHOTS | Run purge command from repair_hint | Surface hint; do not run |
REPO_NO_ENVRC | Create/restore the repo .envrc | Run $HOME/code/dotfiles/bin/lll-account-switch repo init --repo <path> |
After any switch: tell the human to restart affected claude / codex sessions (routing resolves at process launch).
CLI and state:
$HOME/code/dotfiles/bin/lll-account-switchskills/lll-account-switch/scripts/lll-account-switch-status.shGenerated routing state (read-only for agents):
~/.config/lll-account-switch/account, claude-account, codex-account~/.config/lll-account-switch/env, secrets.envAccount and repo config:
$HOME/code/dotfiles/.envrc.monash-foundry (do not edit).envrc~/.codex-monash/config.tomlAZURE_OPENAI_API_KEY / AZURE_OPENAI_API_KEY_MONASH values.az login, op signin, or snapshot purge commands.$HOME/code/dotfiles/.envrc.monash-foundry.health[] is non-empty, report codes and repair hints before continuing.$HOME/code/dotfiles/bin/lll-account-switch status --json | jq '.ok' - agent-readable surface works.$HOME/code/dotfiles/bin/lll-account-switch status - human-readable summary.$HOME/code/dotfiles/bin/lll-account-switch explain --json - effective-provider reasons are machine-readable.$HOME/code/dotfiles/bin/lll-account-switch repo list --json - repo override discovery is machine-readable.bash skills/lll-account-switch/scripts/lll-account-switch-status.sh - fallback script path works.$HOME/code/dotfiles/bin/test/lll-account-switch-test.sh - repo tool targeting, help, parser acceptance, and status semantics.