tmux-ai-coder-panel 1.0.1__tar.gz

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.
Files changed (35) hide show
  1. tmux_ai_coder_panel-1.0.1/.env.example +8 -0
  2. tmux_ai_coder_panel-1.0.1/.gitignore +166 -0
  3. tmux_ai_coder_panel-1.0.1/.vscode/settings.json +3 -0
  4. tmux_ai_coder_panel-1.0.1/CHANGELOG.md +252 -0
  5. tmux_ai_coder_panel-1.0.1/COMMAND_AND_DELETE_GUIDE.md +339 -0
  6. tmux_ai_coder_panel-1.0.1/PKG-INFO +152 -0
  7. tmux_ai_coder_panel-1.0.1/README.md +142 -0
  8. tmux_ai_coder_panel-1.0.1/TERMINAL_LOGS_GUIDE.md +205 -0
  9. tmux_ai_coder_panel-1.0.1/TMUX_GUIDE.md +216 -0
  10. tmux_ai_coder_panel-1.0.1/USAGE.md +316 -0
  11. tmux_ai_coder_panel-1.0.1/claude-panel-frontend.service +18 -0
  12. tmux_ai_coder_panel-1.0.1/claude-panel.service +15 -0
  13. tmux_ai_coder_panel-1.0.1/frontend/README.md +111 -0
  14. tmux_ai_coder_panel-1.0.1/frontend/index.html +13 -0
  15. tmux_ai_coder_panel-1.0.1/frontend/package-lock.json +1938 -0
  16. tmux_ai_coder_panel-1.0.1/frontend/package.json +25 -0
  17. tmux_ai_coder_panel-1.0.1/frontend/src/App.vue +166 -0
  18. tmux_ai_coder_panel-1.0.1/frontend/src/assets/style.css +382 -0
  19. tmux_ai_coder_panel-1.0.1/frontend/src/auth.js +69 -0
  20. tmux_ai_coder_panel-1.0.1/frontend/src/components/VirtualKeyboard.vue +357 -0
  21. tmux_ai_coder_panel-1.0.1/frontend/src/main.js +6 -0
  22. tmux_ai_coder_panel-1.0.1/frontend/src/router/index.js +44 -0
  23. tmux_ai_coder_panel-1.0.1/frontend/src/views/ControlPanel.vue +1930 -0
  24. tmux_ai_coder_panel-1.0.1/frontend/src/views/Login.vue +168 -0
  25. tmux_ai_coder_panel-1.0.1/frontend/vite.config.js +37 -0
  26. tmux_ai_coder_panel-1.0.1/main.py +8 -0
  27. tmux_ai_coder_panel-1.0.1/pyproject.toml +29 -0
  28. tmux_ai_coder_panel-1.0.1/requirements.txt +4 -0
  29. tmux_ai_coder_panel-1.0.1/tmux_ai_coder_panel/__init__.py +17 -0
  30. tmux_ai_coder_panel-1.0.1/tmux_ai_coder_panel/__main__.py +6 -0
  31. tmux_ai_coder_panel-1.0.1/tmux_ai_coder_panel/cli.py +202 -0
  32. tmux_ai_coder_panel-1.0.1/tmux_ai_coder_panel/frontend_dist/assets/index-B1u0vcZ9.js +26 -0
  33. tmux_ai_coder_panel-1.0.1/tmux_ai_coder_panel/frontend_dist/assets/index-CAF0vsD4.css +1 -0
  34. tmux_ai_coder_panel-1.0.1/tmux_ai_coder_panel/frontend_dist/index.html +14 -0
  35. tmux_ai_coder_panel-1.0.1/tmux_ai_coder_panel/main.py +1019 -0
@@ -0,0 +1,8 @@
1
+ # Claude Panel 环境变量配置模板
2
+ # 复制此文件为 .env 并修改为实际值
3
+
4
+ # 面板登录账号
5
+ PANEL_ACCOUNT=root
6
+
7
+ # 面板登录密码
8
+ PANEL_SECERT=12345678
@@ -0,0 +1,166 @@
1
+ # Claude Panel .gitignore
2
+
3
+ # ====================
4
+ # Python 相关
5
+ # ====================
6
+ # Byte-compiled / optimized / distributed files
7
+ __pycache__/
8
+ *.py[cod]
9
+ *$py.class
10
+ *.so
11
+
12
+ # Distribution / packaging
13
+ .Python
14
+ build/
15
+ develop-eggs/
16
+ dist/
17
+ downloads/
18
+ eggs/
19
+ .eggs/
20
+ lib/
21
+ lib64/
22
+ parts/
23
+ sdist/
24
+ var/
25
+ wheels/
26
+ *.egg-info/
27
+ .installed.cfg
28
+ *.egg
29
+
30
+ # Virtual environments
31
+ .env
32
+ venv/
33
+ ENV/
34
+ env/
35
+ .venv
36
+
37
+ # IDE
38
+ .idea/
39
+ .vscode/*
40
+ !.vscode/settings.json
41
+ !.vscode/tasks.json
42
+ !.vscode/launch.json
43
+ *.swp
44
+ *.swo
45
+ *~
46
+
47
+ # Testing
48
+ .pytest_cache/
49
+ .coverage
50
+ htmlcov/
51
+ .tox/
52
+ .nox/
53
+
54
+ # Jupyter Notebook
55
+ .ipynb_checkpoints
56
+
57
+ # pyenv
58
+ .python-version
59
+
60
+ # pip
61
+ pip-log.txt
62
+ pip-delete-this-directory.txt
63
+
64
+ # ====================
65
+ # Vue/Node.js 相关
66
+ # ====================
67
+ # Dependencies
68
+ frontend/node_modules/
69
+ frontend/.pnp
70
+ frontend/.pnp.js
71
+
72
+ # Testing
73
+ frontend/coverage
74
+
75
+ # Production
76
+ frontend/dist
77
+ frontend/build
78
+ # vite 构建直接输出到包目录(wheel 打包用)
79
+ tmux_ai_coder_panel/frontend_dist/
80
+
81
+ # Misc
82
+ frontend/.DS_Store
83
+ frontend/.npm
84
+ frontend/.npm-debug.log*
85
+ frontend/.yarn-debug.log*
86
+ frontend/.yarn-error.log*
87
+
88
+ # Editor directories and files
89
+ frontend/.vscode/*
90
+ !frontend/.vscode/settings.json
91
+ frontend/.idea
92
+ frontend/*.suo
93
+ frontend/*.ntvs*
94
+ frontend/*.njsproj
95
+ frontend/*.sln
96
+ frontend *.sw?
97
+
98
+ # ====================
99
+ # Vibe Coding AI 工具
100
+ # ====================
101
+ # Claude
102
+ .claude/
103
+ .claude.json
104
+ .claude.json.backup
105
+
106
+ # Qoder
107
+ .qoder/
108
+ .qoder.json
109
+ .qoder.json.backup
110
+
111
+ # Cursor
112
+ .cursor/
113
+ .cursor.json
114
+ .cursorrules
115
+
116
+ # GitHub Copilot
117
+ .copilot/
118
+
119
+ # WindSurf
120
+ .windsurf/
121
+
122
+ # Other AI tools
123
+ .ai-code-tracker.json
124
+ .trae/
125
+ .roo/
126
+
127
+ # ====================
128
+ # 系统文件
129
+ # ====================
130
+ .DS_Store
131
+ .DS_Store?
132
+ ._*
133
+ .Spotlight-V100
134
+ .Trashes
135
+ ehthumbs.db
136
+ Thumbs.db
137
+
138
+ # Logs
139
+ *.log
140
+ npm-debug.log*
141
+ yarn-debug.log*
142
+ yarn-error.log*
143
+ lerna-debug.log*
144
+
145
+ # Runtime data
146
+ pids
147
+ *.pid
148
+ *.seed
149
+ *.pid.lock
150
+
151
+ # ====================
152
+ # 项目特定
153
+ # ====================
154
+ # 环境变量文件(包含敏感信息)
155
+ .env
156
+ .env.local
157
+ .env.*.local
158
+
159
+ # 不忽略示例文件
160
+ !.env.example
161
+
162
+ # 数据库
163
+ *.sqlite
164
+ *.sqlite3
165
+ *.db
166
+ .ai-code-tracker.json
@@ -0,0 +1,3 @@
1
+ {
2
+ "python.languageServer": "None"
3
+ }
@@ -0,0 +1,252 @@
1
+ # 更新日志
2
+
3
+ ## [1.3.0] - 2026-06-28
4
+
5
+ ### 更新
6
+
7
+ #### 1. 前端端口调整
8
+ - ✅ 前端开发服务器端口从 3000 改为 10016
9
+ - ✅ 避免与其他服务端口冲突
10
+ - ✅ 更贴近后端端口(10015),便于记忆
11
+
12
+ #### 2. 一键启动功能
13
+ - ✅ 添加 `npm run dev:all` 命令
14
+ - ✅ 使用 concurrently 同时启动后端和前端
15
+ - ✅ 添加 `npm run start:backend` 单独启动后端
16
+ - ✅ 简化开发流程,无需手动启动两个服务
17
+
18
+ ### 使用方式
19
+
20
+ #### 方式一:分别启动
21
+ ```bash
22
+ # 终端 1:启动后端
23
+ python main.py
24
+
25
+ # 终端 2:启动前端
26
+ cd frontend
27
+ npm run dev
28
+ ```
29
+
30
+ #### 方式二:一键启动(推荐)
31
+ ```bash
32
+ cd frontend
33
+ npm run dev:all
34
+ ```
35
+
36
+ ### 文件变更
37
+ - `frontend/vite.config.js` - 端口改为 10016
38
+ - `frontend/package.json` - 添加 dev:all 和 start:backend 脚本
39
+ - `README.md` - 更新端口说明
40
+ - `frontend/README.md` - 更新端口和启动方式
41
+
42
+ ## [1.2.0] - 2026-06-28
43
+
44
+ ### 新增功能
45
+
46
+ #### 1. Tmux 会话管理
47
+ - ✅ 添加 TmuxManager 类,实现 tmux 会话管理
48
+ - ✅ 新增 REST API 接口:
49
+ - `GET /api/tmux/sessions` - 列出所有活跃会话
50
+ - `POST /api/tmux/create` - 创建新会话
51
+ - `POST /api/tmux/attach` - 切换到指定会话
52
+ - ✅ 前端实现:
53
+ - 下拉菜单显示活跃会话列表(自动刷新)
54
+ - “新增”按钮创建新会话
55
+ - 弹窗表单输入项目路径
56
+ - 实时预览会话名称(反向域名格式)
57
+ - 路径验证(禁止 ~ 和根路径)
58
+ - ✅ 自动激活 Claude: 创建会话后自动 cd 到路径并启动 claude
59
+ - ✅ 会话命名规则: `/Users/mac/codes` → `codes.mac.Users`
60
+
61
+ ### 文件变更
62
+
63
+ #### 新增文件
64
+ ```
65
+ TMUX_GUIDE.md # Tmux 会话管理使用指南
66
+ ```
67
+
68
+ #### 修改文件
69
+ - `main.py` - 添加 TmuxManager 类和 tmux API 端点
70
+ - `frontend/src/views/ControlPanel.vue` - 添加 tmux 会话管理和创建功能
71
+ - `README.md` - 添加 tmux 会话管理说明
72
+ - `CHANGELOG.md` - 添加本版本更新记录
73
+
74
+ ### 使用方式
75
+
76
+ #### 创建新会话
77
+ 1. 点击顶部右侧“新增”按钮
78
+ 2. 输入项目绝对路径(如 `/Users/mac/codes`)
79
+ 3. 系统自动预览会话名称
80
+ 4. 点击“创建”完成
81
+
82
+ #### 切换会话
83
+ - 从顶部的下拉菜单选择要切换的会话
84
+ - 会话列表每 5 秒自动刷新
85
+
86
+ ### 注意事项
87
+
88
+ 1. **tmux 必须安装**:
89
+ ```bash
90
+ brew install tmux # macOS
91
+ sudo apt-get install tmux # Ubuntu
92
+ ```
93
+
94
+ 2. **路径规则**:
95
+ - ✅ 必须使用绝对路径(以 / 开头)
96
+ - ❌ 不允许使用 ~ 符号
97
+ - ❌ 不允许使用根路径 /
98
+ - ✅ 路径必须存在且是目录
99
+
100
+ 3. **会话命名**:
101
+ - 自动转换为反向域名格式
102
+ - 示例: `/Users/mac/codes` → `codes.mac.Users`
103
+
104
+ ## [1.1.0] - 2026-06-28
105
+
106
+ ### 新增功能
107
+
108
+ #### 1. SSH 终端支持
109
+ - ✅ 添加 paramiko 依赖,实现 SSH 连接功能
110
+ - ✅ 新增 `/ws/ssh` WebSocket 端点,支持交互式 SSH 终端
111
+ - ✅ 新增 REST API 接口:
112
+ - `GET /api/ssh/status` - 获取 SSH 连接状态
113
+ - `POST /api/ssh/connect` - 建立 SSH 连接
114
+ - `POST /api/ssh/command` - 执行 SSH 命令
115
+ - `POST /api/ssh/disconnect` - 断开 SSH 连接
116
+ - ✅ 在原有 HTML 页面添加 SSH 终端入口按钮
117
+ - ✅ 创建 `/ssh` 路由页面
118
+
119
+ #### 2. Vue 3 前端项目
120
+ - ✅ 完整的 Vue 3 + Vite 项目结构
121
+ - ✅ 使用 Vue Router 实现路由管理
122
+ - `/` - 控制面板页面
123
+ - `/ssh` - SSH 终端页面
124
+ - ✅ 使用 xterm.js 实现专业终端仿真
125
+ - ✅ 现代化 UI 设计,支持响应式布局
126
+ - ✅ WebSocket 实时通信
127
+ - ✅ 自动代理配置(开发模式)
128
+
129
+ #### 3. 文档更新
130
+ - ✅ 完善 README.md
131
+ - 添加功能特性说明
132
+ - 添加 tmux 安装教程(macOS/Ubuntu/CentOS)
133
+ - 添加 tmux-logging 插件安装指南
134
+ - 添加 OpenLess 可选依赖说明
135
+ - 添加项目结构说明
136
+ - 添加 API 文档链接
137
+ - ✅ 添加前端项目 README.md
138
+
139
+ ### 技术栈更新
140
+
141
+ #### 后端
142
+ - FastAPI >= 0.111.0
143
+ - Uvicorn >= 0.29.0
144
+ - **paramiko >= 3.3.0** (新增)
145
+ - **websocket-client >= 1.6.0** (新增)
146
+
147
+ #### 前端
148
+ - Vue 3.4.0
149
+ - Vue Router 4.2.5
150
+ - Vite 5.0.0
151
+ - xterm.js 5.3.0
152
+ - Axios 1.6.0
153
+
154
+ ### 文件变更
155
+
156
+ #### 新增文件
157
+ ```
158
+ frontend/
159
+ ├── package.json
160
+ ├── vite.config.js
161
+ ├── index.html
162
+ ├── README.md
163
+ └── src/
164
+ ├── main.js
165
+ ├── App.vue
166
+ ├── router/index.js
167
+ ├── assets/style.css
168
+ └── views/
169
+ ├── ControlPanel.vue
170
+ └── SSHTerminal.vue
171
+
172
+ ssh_manager.py # SSH 连接管理模块
173
+ ```
174
+
175
+ #### 修改文件
176
+ - `main.py` - 添加 SSH 路由和 WebSocket 端点
177
+ - `requirements.txt` - 添加 paramiko 和 websocket-client
178
+ - `README.md` - 完善项目文档
179
+ - `static/index.html` - 添加 SSH 入口按钮
180
+ - `static/style.css` - 添加 SSH 按钮样式
181
+
182
+ ### 使用方式
183
+
184
+ #### 方式一:使用原有静态页面(推荐生产环境)
185
+
186
+ 1. 安装 Python 依赖:
187
+ ```bash
188
+ pip install -r requirements.txt
189
+ ```
190
+
191
+ 2. 启动后端服务:
192
+ ```bash
193
+ python main.py
194
+ ```
195
+
196
+ 3. 访问 `http://localhost:10015`
197
+
198
+ #### 方式二:使用 Vue 开发模式(推荐开发环境)
199
+
200
+ 1. 安装 Python 依赖并启动后端:
201
+ ```bash
202
+ pip install -r requirements.txt
203
+ python main.py
204
+ ```
205
+
206
+ 2. 在另一个终端安装前端依赖:
207
+ ```bash
208
+ cd frontend
209
+ npm install
210
+ ```
211
+
212
+ 3. 启动前端开发服务器:
213
+ ```bash
214
+ npm run dev
215
+ ```
216
+
217
+ 4. 访问 `http://localhost:3000`(自动代理到后端)
218
+
219
+ ### 兼容性
220
+
221
+ - ✅ 向后兼容:原有静态页面功能完全保留
222
+ - ✅ 渐进式迁移:Vue 前端可作为独立项目运行
223
+ - ✅ 可选依赖:SSH 功能为可选,不影响核心功能
224
+
225
+ ### 注意事项
226
+
227
+ 1. **SSH 安全**:
228
+ - 首次连接未知主机时会自动接受主机密钥
229
+ - 建议在生产环境配置 SSH 密钥认证
230
+ - 不要在生产环境使用弱密码
231
+
232
+ 2. **依赖安装**:
233
+ - paramiko 可能需要系统安装 libffi 和 OpenSSL
234
+ - macOS: `brew install libffi openssl`
235
+ - Ubuntu: `sudo apt-get install libffi-dev libssl-dev`
236
+
237
+ 3. **开发环境**:
238
+ - 需要 Node.js >= 16
239
+ - 推荐使用 npm >= 8 或 pnpm >= 8
240
+
241
+ ### 已知问题
242
+
243
+ - Vue 前端为开发版本,生产部署需要构建
244
+ - SSH 终端在大文件传输时可能需要优化缓冲区
245
+
246
+ ### 后续计划
247
+
248
+ - [ ] 添加 SSH 连接历史记录
249
+ - [ ] 支持多标签 SSH 会话
250
+ - [ ] 添加文件传输功能(SFTP)
251
+ - [ ] 完善 Vue 前端的生产构建配置
252
+ - [ ] 添加单元测试