@teammy/cli 0.0.0-stage → 0.0.2

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,3 +1,24 @@
1
- # Temporary Holding Version
1
+ # Teammy client
2
2
 
3
- This version is a temporary placeholder for this package. An operational version to replace this has been submitted for review and is awaiting a staged release.
3
+ 成员设备上的 Teammy 命令行客户端,需要 Node.js 22.13 或更新版本。
4
+
5
+ ```sh
6
+ npm install -g @teammy/cli@0.0.2
7
+ teammy --help
8
+ teammy --version
9
+ teammy server-info --url http://127.0.0.1:4317
10
+ ```
11
+
12
+ `server-info` 查询服务器版本与协议能力,以 JSON 输出结果;协议不兼容或连接失败时返回非零退出码。此命令不保存配置或绑定工作区。
13
+
14
+ 管理员在网页建立成员 ID 后,运行 `connect --url URL --member ID`,再运行 `sync`。默认共享根为 `./workspaces`。支持旧 `--token-file FILE` 接入和 `status --root DIR`;绑定与设备身份保存在本地 SQLite。默认状态目录为 `~/.teammy/client`,可通过 `--state-dir DIR` 指定。
15
+
16
+ 连接后运行 `teammy sync --root DIR` 持续同步文件,默认约一分钟检查一次并逐文件等待一分钟稳定。`sync --once` 执行一轮,`--settle-ms 0` 显式允许立即处理已保存内容。上传自己的成员目录,下载其他成员目录;本地镜像冲突会保留并报告。运行 `teammy sync --help` 查看恢复与调度选项。会话来源可通过 `teammy session discover --agent AGENT --project-dir DIR` 或 `session track --agent AGENT --file PATH --project-dir DIR` 登记,之后由 sync 采集上传。支持 Claude Code、Codex、Cursor CLI SQLite、Pi v3、DSH v0;DSH 压缩日志需要 Node.js 22.15+ 或 24+。`session hook` 提供不等待网络的本地线索入口,不自动修改宿主配置。
17
+
18
+ 使用 `session list`、`session search --query TEXT`、`session read --owner MEMBER --key KEY` 查看团队会话,`session sources` 查看来源与错误,`sync --sessions-only` 只运行会话链路。所有命令支持 `--root DIR` 和 `--state-dir DIR`。`teammy session --help` 查看完整参数。
19
+
20
+ 服务器单独安装 `@teammy/server`,启动命令为 `teammy-server`。原有 `teammy server` 命令会提示迁移方式。
21
+
22
+ 许可证随包附于 `dist/LICENSE`。
23
+
24
+ 公共配置位于共享根 `.teammy.json`,凭证仅留在本机状态库。网页设置约每 30 秒热应用,显式 `--interval-ms` / `--settle-ms` 仍优先并显示为覆盖。网页重置设备后,使用原 connect 命令加 `--reconnect` 重新接入,保留已有同步基线。
package/bin/teammy.js ADDED
@@ -0,0 +1,8 @@
1
+ #!/usr/bin/env node
2
+
3
+ import { readFileSync } from 'node:fs';
4
+ import { runCli } from '../dist/main.js';
5
+
6
+ const { version } = JSON.parse(readFileSync(new URL('../package.json', import.meta.url), 'utf8'));
7
+
8
+ process.exitCode = await runCli(process.argv.slice(2), version);
package/dist/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 Teammy contributors
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.