{"id":47302735,"url":"https://github.com/synth1s/cloak","last_synced_at":"2026-04-01T17:46:01.948Z","repository":{"id":344907274,"uuid":"1183651479","full_name":"synth1s/cloak","owner":"synth1s","description":"Cloak your Claude. Switch identities in seconds.","archived":false,"fork":false,"pushed_at":"2026-03-26T04:50:40.000Z","size":228,"stargazers_count":8,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"master","last_synced_at":"2026-03-27T01:10:26.042Z","etag":null,"topics":["anthropic","claude","claude-code","cli","cloak","multi-account"],"latest_commit_sha":null,"homepage":"https://www.npmjs.com/package/@synth1s/cloak","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/synth1s.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":"SECURITY.md","support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2026-03-16T20:28:04.000Z","updated_at":"2026-03-26T12:20:36.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/synth1s/cloak","commit_stats":null,"previous_names":["synth1s/cloak"],"tags_count":9,"template":false,"template_full_name":null,"purl":"pkg:github/synth1s/cloak","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/synth1s%2Fcloak","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/synth1s%2Fcloak/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/synth1s%2Fcloak/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/synth1s%2Fcloak/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/synth1s","download_url":"https://codeload.github.com/synth1s/cloak/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/synth1s%2Fcloak/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31290583,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-01T13:12:26.723Z","status":"ssl_error","status_checked_at":"2026-04-01T13:12:25.102Z","response_time":53,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["anthropic","claude","claude-code","cli","cloak","multi-account"],"created_at":"2026-03-17T05:29:17.006Z","updated_at":"2026-04-01T17:46:01.943Z","avatar_url":"https://github.com/synth1s.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# @synth1s/cloak\n\n[![CI](https://github.com/synth1s/cloak/actions/workflows/ci.yml/badge.svg)](https://github.com/synth1s/cloak/actions/workflows/ci.yml)\n[![npm](https://img.shields.io/npm/v/@synth1s/cloak)](https://www.npmjs.com/package/@synth1s/cloak)\n[![downloads](https://img.shields.io/npm/dw/@synth1s/cloak)](https://www.npmjs.com/package/@synth1s/cloak)\n[![license](https://img.shields.io/npm/l/@synth1s/cloak)](LICENSE)\n\n**Stop logging out. Start switching.**\n\nEvery developer wears a different cloak. One for work, one for personal projects, one for that freelance gig. **Cloak** lets you dress your Claude Code in the right identity — and switch between them without breaking a sweat.\n\nNo file swapping. No token juggling. Each account is a fully isolated directory — safe for concurrent sessions across terminals. [195+ developers asked for this.](https://github.com/anthropics/claude-code/issues/18435)\n\n![demo](cloak-demo.svg)\n\n## Before / After\n\n**Before Cloak:**\n```\nclaude → /logout → /login (lose session) → work on project\nclaude → /logout → /login (lose session) → personal use\n```\n\n**After Cloak:**\n```\nclaude -a work     # instant. sessions preserved.\nclaude -a home     # in another terminal. at the same time.\n```\n\n## Install\n\n```bash\nnpm install -g @synth1s/cloak\n```\n\n## 3 steps to get started\n\n```bash\n# 1. Save your current Claude session\ncloak create work\n\n# 2. Log out, log in with another account in Claude, then:\ncloak create home\n\n# 3. Set up shell integration\ncloak switch work    # follows the guided setup on first run\n```\n\nThat's it. From now on:\n\n```bash\nclaude -a work       # switch and launch\nclaude -a home       # in another terminal, at the same time\n```\n\n## Commands\n\n| Command | Description |\n|---------|-------------|\n| `cloak create [name]` | Save current session as a new cloak |\n| `cloak switch \u003cname\u003e` | Wear a different cloak |\n| `cloak list` | See all cloaks in your wardrobe |\n| `cloak whoami` | Which cloak are you wearing? |\n| `cloak delete \u003cname\u003e` | Discard a cloak |\n| `cloak rename \u003cold\u003e \u003cnew\u003e` | Rename a cloak |\n| `cloak bind \u003cname\u003e` | Bind this directory to a cloak |\n| `cloak unbind` | Remove directory binding |\n\nWith shell integration (`eval \"$(cloak init)\"`):\n\n| Command | Description |\n|---------|-------------|\n| `claude -a \u003cname\u003e` | Switch and launch Claude |\n| `claude account \u003ccmd\u003e` | All cloak commands via claude |\n\n## Concurrent sessions\n\nDifferent terminal, different identity. No conflicts.\n\n```bash\n# Terminal A:\nclaude -a work\n\n# Terminal B (at the same time):\nclaude -a home\n```\n\nEach account is a completely isolated directory. No file overlap, no token conflicts.\n\n## Auto-switch by directory\n\nBind a cloak to a project directory. Claude automatically uses the right account.\n\n```bash\ncd ~/projects/company\ncloak bind work\n\ncd ~/projects/personal\ncloak bind home\n```\n\nFrom now on, `claude` in those directories uses the bound account — no manual switch needed.\n\n## Context bar\n\nEvery command shows which identity is active:\n\n```\ncloak \u003e list . work \u003cfilipe@company.com\u003e ────────────────────────────\n\nYour Cloaks\n\n  \u003e work (active) — filipe@company.com\n    home — filipe@personal.com\n```\n\n## Why Cloak\n\n- **No file swapping** — each account is its own directory, not a copy of shared files\n- **Concurrent sessions** — different terminals, different accounts, at the same time\n- **Auto-switch by directory** — bind a project to a cloak, forget about it\n- **One command** — `claude -a work` switches and launches in one step\n- **Nothing is lost** — tokens, MCP servers, settings, all preserved per account\n- **Secure** — credentials stored with restrictive permissions (0o600), never transmitted\n\n## How it works\n\nCloak uses Claude Code's official [`CLAUDE_CONFIG_DIR`](https://code.claude.com/docs/en/env-vars) environment variable. Each account gets its own directory:\n\n```\n~/.cloak/\n└── profiles/\n    ├── work/                # complete, isolated config\n    │   ├── .claude.json\n    │   ├── settings.json\n    │   └── ...\n    └── home/\n        ├── .claude.json\n        └── ...\n```\n\nSwitching changes which directory Claude Code reads from. Nothing is copied, moved, or overwritten.\n\n## FAQ\n\n\u003cdetails\u003e\n\u003csummary\u003e\u003cstrong\u003eWill switching overwrite my settings?\u003c/strong\u003e\u003c/summary\u003e\n\nNo. Each account is a completely isolated directory. Switching only changes which directory Claude Code reads from. Your settings, MCP servers, and preferences for each account stay exactly where they are.\n\u003c/details\u003e\n\n\u003cdetails\u003e\n\u003csummary\u003e\u003cstrong\u003eAre token renewals preserved?\u003c/strong\u003e\u003c/summary\u003e\n\nYes. When Claude Code renews your OAuth token during a session, it writes to the active account's directory. When you switch away and back, the renewed token is still there.\n\u003c/details\u003e\n\n\u003cdetails\u003e\n\u003csummary\u003e\u003cstrong\u003eCan I lose data with multiple accounts running?\u003c/strong\u003e\u003c/summary\u003e\n\nNo, as long as each terminal uses a different account. Each has its own directory — no file overlap.\n\u003c/details\u003e\n\n\u003cdetails\u003e\n\u003csummary\u003e\u003cstrong\u003eIs my auth token safe?\u003c/strong\u003e\u003c/summary\u003e\n\nCloak never transmits, logs, or modifies your tokens. It only copies files during `cloak create` and changes an environment variable during `cloak switch`. All data stays local. Credential files are created with restrictive permissions (0o600).\n\u003c/details\u003e\n\n\u003cdetails\u003e\n\u003csummary\u003e\u003cstrong\u003eWhat if I uninstall Cloak?\u003c/strong\u003e\u003c/summary\u003e\n\nYour account directories remain in `~/.cloak/`. Claude Code works normally with its default config. To clean up: `rm -rf ~/.cloak`\n\u003c/details\u003e\n\n\u003cdetails\u003e\n\u003csummary\u003e\u003cstrong\u003eDoes it work with IDE extensions?\u003c/strong\u003e\u003c/summary\u003e\n\nIDE extensions may not respect `CLAUDE_CONFIG_DIR` ([known limitation](https://github.com/anthropics/claude-code/issues/4739)). Cloak is designed for terminal-based Claude Code.\n\u003c/details\u003e\n\n## Requirements\n\n- Node.js \u003e= 18\n- bash or zsh (for shell integration)\n\n## Contributing\n\nSee [CONTRIBUTING.md](CONTRIBUTING.md).\n\n## Security\n\nSee [SECURITY.md](SECURITY.md).\n\n## Documentation\n\n- [Requirements \u0026 use cases](docs/requirements.md)\n- [Technical specification](docs/technical-spec.md)\n\n## License\n\nMIT\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsynth1s%2Fcloak","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsynth1s%2Fcloak","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsynth1s%2Fcloak/lists"}