@tkpdx01/ccc 1.6.0 → 1.6.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -1,129 +1,105 @@
1
- # claude-code-launcher (ccc)
1
+ # ccc — Claude Code / Codex Launcher
2
2
 
3
- Claude Code Settings Launcher - Launch Claude Code with different settings profiles. Run multiple Claude instances with different API configurations simultaneously.
3
+ Manage multiple API profiles for **Claude Code** and **OpenAI Codex**. Switch between providers, keys, and endpoints instantly.
4
4
 
5
- Claude Code 设置启动器 - 使用不同的 settings profile 文件启动 Claude Code,可同时运行多个使用不同 API 配置的 Claude 实例。
5
+ 管理 **Claude Code** **OpenAI Codex** 的多套 API 配置,一键切换 Provider、Key Endpoint。
6
6
 
7
- ## Installation / 安装
7
+ ## Install
8
8
 
9
9
  ```bash
10
10
  npm install -g @tkpdx01/ccc
11
11
  ```
12
12
 
13
- ## Usage / 使用
14
-
15
- ### Launch / 启动
13
+ ## Quick Start
16
14
 
17
15
  ```bash
18
- ccc # Default profile or select / 使用默认或交互选择
19
- ccc <profile> # Specific profile / 指定配置
20
- ccc -d # With --dangerously-skip-permissions
21
- ccc <profile> -d # Combine both / 组合使用
16
+ ccc new # Create a profile (Claude or Codex)
17
+ ccc list # List all profiles
18
+ ccc <profile> # Launch with profile (by name or index)
19
+ ccc # Launch default, or select interactively
22
20
  ```
23
21
 
24
- ### Manage Profiles / 管理配置
22
+ ## Commands
23
+
24
+ ### Launch
25
25
 
26
26
  ```bash
27
- ccc list # List profiles / 列出配置
28
- ccc list -v # List with URLs / 显示 API URLs
29
- ccc show [profile] # Show config / 显示完整配置
30
- ccc use <profile> # Set default / 设置默认
31
- ccc new [name] # Create from template / 从模板创建
32
- ccc sync [profile] # Sync from template / 从模板同步
33
- ccc sync -a # Sync all / 同步所有
34
- ccc edit [profile] # Edit profile / 编辑配置
35
- ccc delete [profile] # Delete profile / 删除配置
27
+ ccc <profile> # Auto-detect type and launch
28
+ ccc <index> # Launch by index number (e.g. ccc 3)
29
+ ccc -d # Claude: --dangerously-skip-permissions / Codex: --full-auto
36
30
  ```
37
31
 
38
- ### WebDAV Cloud Sync / WebDAV 云同步
32
+ ### Profile Management
39
33
 
40
34
  ```bash
41
- ccc webdav setup # Configure WebDAV and sync password / 配置 WebDAV 和同步密码
42
- ccc webdav push # Push profiles to cloud / 推送到云端
43
- ccc webdav pull # Pull profiles from cloud / 从云端拉取
44
- ccc webdav status # View sync status / 查看同步状态
35
+ ccc new [name] # Create profile (choose Claude or Codex)
36
+ ccc edit [profile] # Edit API credentials
37
+ ccc use <profile> # Set default profile
38
+ ccc show [profile] # Show full config
39
+ ccc delete [profile] # Delete profile
40
+ ccc sync [profile] # Sync from template, preserve credentials
41
+ ccc sync --all # Sync all profiles
42
+ ccc apply [profile] # Write profile config to ~/.claude or ~/.codex
45
43
  ```
46
44
 
47
- ## Features / 功能
48
-
49
- - **Multiple Profiles / 多配置**: Manage different API configurations
50
- - **Template Support / 模板**: Based on `~/.claude/settings.json`
51
- - **Sync Settings / 同步**: Update from template, preserve credentials
52
- - **Claude Env Defaults / Claude 环境变量默认值**: Auto-ensure these values in the `env` section of both `~/.claude/settings.json` and each profile: `CLAUDE_CODE_DISABLE_NONESSENTIAL_TRAFFIC=1`, `CLAUDE_CODE_ATTRIBUTION_HEADER=0`, `DISABLE_INSTALLATION_CHECKS=1`, `CLAUDE_CODE_EXPERIMENTAL_AGENT_TEAMS=1`
53
- - **WebDAV Cloud Sync / 云同步**: Encrypted sync across devices
54
-
55
- ## Sync Command / 同步命令
56
-
57
- The `sync` command updates profiles with the latest settings from `~/.claude/settings.json` while preserving each profile's API credentials (`ANTHROPIC_AUTH_TOKEN` and `ANTHROPIC_BASE_URL`).
58
-
59
- `sync` 命令从 `~/.claude/settings.json` 同步最新设置到 profiles,同时保留每个 profile 的 API 凭证(`ANTHROPIC_AUTH_TOKEN` 和 `ANTHROPIC_BASE_URL`)。
45
+ ### WebDAV Cloud Sync
60
46
 
61
47
  ```bash
62
- ccc sync [profile] # Sync single profile / 同步单个配置
63
- ccc sync --all # Sync all profiles / 同步所有配置
48
+ ccc webdav setup # Configure WebDAV + encryption password
49
+ ccc webdav push # Upload (AES-256-GCM encrypted)
50
+ ccc webdav pull # Download and decrypt
51
+ ccc webdav status # Check sync status
64
52
  ```
65
53
 
66
- Use this when you've updated your main Claude settings (plugins, model, etc.) and want to apply those changes to all profiles.
54
+ ## How It Works
67
55
 
68
- 当你更新了主 Claude 设置(插件、模型等)并想将这些更改应用到所有 profiles 时使用此命令。
56
+ ### Claude Profiles
69
57
 
70
- ## WebDAV Cloud Sync / WebDAV 云同步
58
+ Each profile is a copy of `~/.claude/settings.json` with its own API credentials. Launched via:
71
59
 
72
- Sync your profiles across multiple devices using any WebDAV service (Nutstore, Nextcloud, etc.).
73
-
74
- 使用任意 WebDAV 服务(坚果云、Nextcloud 等)在多设备间同步配置。
75
-
76
- ### Setup / 配置
77
-
78
- ```bash
79
- ccc webdav setup
80
60
  ```
81
-
82
- This will prompt for:
83
- - WebDAV server URL
84
- - Username / Password
85
- - Remote storage path
86
- - Sync password (for encryption)
87
-
88
- ### Commands / 命令
89
-
90
- ```bash
91
- ccc webdav push # Upload encrypted profiles / 上传加密配置
92
- ccc webdav pull # Download and decrypt / 下载并解密
93
- ccc webdav status # View sync status / 查看同步状态
94
- ccc webdav push -f # Force push (skip conflict prompts) / 强制推送
95
- ccc webdav pull -f # Force pull (skip conflict prompts) / 强制拉取
61
+ claude --settings ~/.ccc/profiles/<name>.json
96
62
  ```
97
63
 
98
- ### Security / 安全设计
99
-
100
- - **End-to-end encryption**: All data is encrypted locally with AES-256-GCM before upload. Even if someone gains access to your WebDAV storage, they cannot read your API keys without the sync password.
101
-
102
- - **Password-based protection**: Your sync password is never transmitted. It derives the encryption key using PBKDF2 (100,000 iterations).
103
-
104
- - **Local password caching**: On trusted devices, the password is cached locally (encrypted with machine fingerprint), so you don't need to enter it every time.
64
+ ### Codex Profiles
105
65
 
106
- - **Manual sync only**: Synchronization only happens when you explicitly run `push` or `pull`. No background processes, no automatic uploads. You always know when your data leaves your machine.
66
+ Each profile is a directory containing `auth.json` + `config.toml`. Launched via:
107
67
 
108
- - **Non-destructive merge**: By default, conflicts preserve both versions instead of overwriting. Use `--force` only when you're certain.
109
-
110
- **安全设计**:
68
+ ```
69
+ CODEX_HOME=~/.ccc/codex-profiles/<name>/ codex
70
+ ```
111
71
 
112
- - **端到端加密**:所有数据在上传前使用 AES-256-GCM 本地加密。即使他人获取了你的 WebDAV 存储访问权限,没有同步密码也无法读取你的 API Key。
72
+ No global environment variables are modified everything is process-scoped.
113
73
 
114
- - **密码保护**:同步密码永不传输,使用 PBKDF2(10万次迭代)派生加密密钥。
74
+ ### Storage
115
75
 
116
- - **本机免密**:在可信设备上,密码使用机器指纹加密缓存在本地,无需每次输入。
76
+ ```
77
+ ~/.ccc/
78
+ ├── profiles/ # Claude profiles (*.json)
79
+ ├── codex-profiles/ # Codex profiles
80
+ │ └── <name>/
81
+ │ ├── auth.json # API key
82
+ │ └── config.toml # Model & endpoint config
83
+ ├── default # Default profile name
84
+ └── webdav.json # Cloud sync config
85
+ ```
117
86
 
118
- - **手动同步**:同步仅在你显式执行 `push` 或 `pull` 时发生。无后台进程,无自动上传。你始终清楚数据何时离开本机。
87
+ ## Key Features
119
88
 
120
- - **无损合并**:默认情况下,冲突时保留两个版本而非覆盖。仅在确定时使用 `--force`。
89
+ - **Dual CLI support** — Claude Code + OpenAI Codex in one tool
90
+ - **Unified index** — All profiles sorted together, launch by number
91
+ - **Apply command** — Push a profile's config to `~/.claude` or `~/.codex`
92
+ - **Template sync** — Update from main settings, keep credentials
93
+ - **Cloud sync** — E2E encrypted WebDAV sync across devices
94
+ - **Zero env pollution** — API keys stored in config files, not shell env
121
95
 
122
- ## Storage / 存储
96
+ ## Security
123
97
 
124
- - Profiles: `~/.ccc/profiles/*.json`
125
- - Template: `~/.claude/settings.json`
98
+ - **AES-256-GCM** encryption for cloud sync
99
+ - **PBKDF2** key derivation (100K iterations)
100
+ - **Manual sync only** — no background processes
101
+ - **Non-destructive merge** — conflicts preserve both versions
126
102
 
127
- ## License / 许可证
103
+ ## License
128
104
 
129
105
  MIT
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tkpdx01/ccc",
3
- "version": "1.6.0",
3
+ "version": "1.6.3",
4
4
  "description": "Claude Code / Codex Settings Launcher - Manage multiple Claude Code and Codex profiles",
5
5
  "main": "index.js",
6
6
  "bin": {
@@ -38,6 +38,13 @@ export function showHelp() {
38
38
  console.log(chalk.gray(' ~/.ccc/.sync_key ') + '本地密码缓存(机器指纹加密)');
39
39
  console.log();
40
40
 
41
+ console.log(chalk.yellow(' 创建配置:'));
42
+ console.log(chalk.gray(' ccc new ') + '交互式创建,选择 Claude 或 Codex 类型');
43
+ console.log(chalk.gray(' ccc new myprofile ') + '指定名称创建,随后选择类型并填写凭证');
44
+ console.log(chalk.gray(' ') + chalk.dim('Claude 需要: ANTHROPIC_BASE_URL + ANTHROPIC_AUTH_TOKEN'));
45
+ console.log(chalk.gray(' ') + chalk.dim('Codex 需要: OPENAI_API_KEY + Base URL + Model(可选)'));
46
+ console.log();
47
+
41
48
  console.log(chalk.yellow(' 示例:'));
42
49
  console.log(chalk.gray(' ccc ls ') + '查看配置列表和序号');
43
50
  console.log(chalk.gray(' ccc 3 ') + '启动第 3 个配置(自动识别 Claude/Codex)');