@wu529778790/open-im 1.11.2-beta.24 → 1.11.2-beta.25
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/dist/index.js +13 -15
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -159,32 +159,30 @@ function getEnabledPlugins() {
|
|
|
159
159
|
/**
|
|
160
160
|
* 统一通知格式模板
|
|
161
161
|
* 所有发送给 IM 的通知都使用这个格式,保持一致性
|
|
162
|
+
* 注意:ClawBot/微信不支持 \n 换行,使用 | 分隔
|
|
162
163
|
*/
|
|
163
164
|
function buildNotification(opts) {
|
|
164
|
-
const
|
|
165
|
-
//
|
|
166
|
-
|
|
167
|
-
//
|
|
168
|
-
const details = [];
|
|
165
|
+
const parts = [];
|
|
166
|
+
// 标题
|
|
167
|
+
parts.push(`${opts.emoji} ${opts.title}`);
|
|
168
|
+
// 详情
|
|
169
169
|
if (opts.platform)
|
|
170
|
-
|
|
170
|
+
parts.push(`📱 ${opts.platform}`);
|
|
171
171
|
if (opts.aiCommand)
|
|
172
|
-
|
|
172
|
+
parts.push(`🤖 ${opts.aiCommand}`);
|
|
173
173
|
if (opts.dir)
|
|
174
|
-
|
|
174
|
+
parts.push(`📁 ${opts.dir}`);
|
|
175
175
|
const plugins = getEnabledPlugins();
|
|
176
176
|
if (plugins.length > 0)
|
|
177
|
-
|
|
177
|
+
parts.push(`🧩 ${plugins.join(", ")}`);
|
|
178
178
|
if (opts.uptime)
|
|
179
|
-
|
|
180
|
-
if (details.length > 0) {
|
|
181
|
-
lines.push("", ...details);
|
|
182
|
-
}
|
|
179
|
+
parts.push(`⏱️ ${opts.uptime}`);
|
|
183
180
|
// 额外信息
|
|
184
181
|
if (opts.extra?.length) {
|
|
185
|
-
|
|
182
|
+
parts.push(...opts.extra);
|
|
186
183
|
}
|
|
187
|
-
|
|
184
|
+
// 使用 | 分隔(ClawBot/微信不支持 \n)
|
|
185
|
+
return parts.join(" | ");
|
|
188
186
|
}
|
|
189
187
|
function buildStartupMessage(platform, appVersion, aiCommand, defaultWorkDir, sessionManager) {
|
|
190
188
|
let sessionDir;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@wu529778790/open-im",
|
|
3
|
-
"version": "1.11.2-beta.
|
|
3
|
+
"version": "1.11.2-beta.25",
|
|
4
4
|
"description": "Your AI coding assistant, in every chat app. Multi-platform IM bridge for Claude Code, Codex, and CodeBuddy.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "dist/index.js",
|