@teammy/server 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,22 @@
1
- # Temporary Holding Version
1
+ # Teammy server
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/server@0.0.2
7
+ teammy-server --help
8
+ teammy-server --version
9
+ teammy-server --host 127.0.0.1 --port 4317
10
+ ```
11
+
12
+ 默认监听 `127.0.0.1:4317`;内网部署时可指定 `--host 0.0.0.0` 或服务器的内网地址。收到 SIGINT 或 SIGTERM 时正常关闭。
13
+
14
+ 当前提供健康检查、协议能力发现、带认证的设备绑定和成员查询,以及工作区隔离的内容传输、幂等文件版本提交、历史清单和增量查询。支持规范化会话快照、历史版本读取、列表及中文/技术标识符正文搜索;服务地址同时提供 Web Wizard、ID 登录、文件只读浏览、成员管理与公共设置。AI 摘要尚未接入。
15
+
16
+ 成员设备使用独立的 `@teammy/cli` 包。服务器启动入口已从原有的 `teammy server` 迁移到 `teammy-server`。
17
+
18
+ 许可证随包附于 `dist/LICENSE`。
19
+
20
+ 管理员使用 `teammy-server member add --workspace ID --member ID` 签发成员令牌,令牌仅向标准输出显示一次;`member reset` 更换令牌并释放设备绑定,`member revoke` 撤销访问。管理和启动命令使用相同的 `--data-dir DIR`,默认 `~/.teammy/server`。
21
+
22
+ 首次启动后打开监听地址,在网页建立项目、管理员 ID 和预设成员,无需进入服务器签发令牌。页面及 API 使用同一端口。成员以 `teammy connect --url URL --member ID` 接入,配置版本和设备状态在设置页查看。生产 Web 资源随此包交付,无需另外构建前端。
@@ -0,0 +1,8 @@
1
+ #!/usr/bin/env node
2
+
3
+ import { readFileSync } from 'node:fs';
4
+ import { runServerCli } from '../dist/main.js';
5
+
6
+ const { version } = JSON.parse(readFileSync(new URL('../package.json', import.meta.url), 'utf8'));
7
+
8
+ process.exitCode = await runServerCli(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.