claude-notification-plugin 1.1.18 → 1.1.20
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/.claude-plugin/plugin.json +1 -1
- package/commit-sha +1 -1
- package/listener/listener.js +2 -2
- package/notifier/notifier.js +5 -4
- package/package.json +1 -1
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "claude-notification-plugin",
|
|
3
|
-
"version": "1.1.
|
|
3
|
+
"version": "1.1.20",
|
|
4
4
|
"description": "Claude Code task-completion notifications: Telegram, desktop notifications (Windows/macOS/Linux), sound, and voice",
|
|
5
5
|
"author": {
|
|
6
6
|
"name": "Viacheslav Makarov",
|
package/commit-sha
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
1c842063a9de04968f5523348e390194668a289b
|
package/listener/listener.js
CHANGED
|
@@ -137,8 +137,8 @@ runner.on('complete', async (workDir, task, output) => {
|
|
|
137
137
|
|
|
138
138
|
// Build result: try replying to user's original message without duplicating the task text.
|
|
139
139
|
// If reply fails (user deleted their message), resend with task text included.
|
|
140
|
-
const headerShort = `✅
|
|
141
|
-
const headerFull = `✅
|
|
140
|
+
const headerShort = `✅ <code>${label}</code> Done:`;
|
|
141
|
+
const headerFull = `✅ <code>${label}</code> Done: ${escapeHtml(task.text)}`;
|
|
142
142
|
let body = '';
|
|
143
143
|
if (output) {
|
|
144
144
|
if (output.length > 20000) {
|
package/notifier/notifier.js
CHANGED
|
@@ -280,6 +280,7 @@ async function sendTelegram (config, state) {
|
|
|
280
280
|
body: JSON.stringify(body),
|
|
281
281
|
});
|
|
282
282
|
const data = await res.json();
|
|
283
|
+
if (!data.ok) console.error('[telegram] HTML send failed:', JSON.stringify(data));
|
|
283
284
|
if (data.ok && data.result?.message_id) {
|
|
284
285
|
if (!state.sentMessages) {
|
|
285
286
|
state.sentMessages = [];
|
|
@@ -689,19 +690,19 @@ process.stdin.on('end', async () => {
|
|
|
689
690
|
|
|
690
691
|
const branch = getBranch(cwd);
|
|
691
692
|
let label = `/${project}`;
|
|
692
|
-
let labelHtml =
|
|
693
|
+
let labelHtml = `/${escapeHtml(project)}`;
|
|
693
694
|
if (branch) {
|
|
694
695
|
label += `/${branch}`;
|
|
695
|
-
labelHtml +=
|
|
696
|
+
labelHtml += `/${escapeHtml(branch)}`;
|
|
696
697
|
}
|
|
697
|
-
|
|
698
|
+
labelHtml = `<code>${labelHtml}</code>`
|
|
698
699
|
const triggerLine = config.debug ? `\nTrigger: ${eventType}` : '';
|
|
699
700
|
|
|
700
701
|
const desktopTitle = label;
|
|
701
702
|
const desktopMessage = desktopStatus;
|
|
702
703
|
|
|
703
704
|
let telegramMessage =
|
|
704
|
-
`${statusEmoji}
|
|
705
|
+
`${statusEmoji} ${labelHtml}\n(duration: ${duration}s)${triggerLine}`;
|
|
705
706
|
|
|
706
707
|
if (config.telegram.includeLastCcMessageInTelegram && event.last_assistant_message) {
|
|
707
708
|
const maxLen = 3500;
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "claude-notification-plugin",
|
|
3
3
|
"productName": "claude-notification-plugin",
|
|
4
|
-
"version": "1.1.
|
|
4
|
+
"version": "1.1.20",
|
|
5
5
|
"description": "Claude Code task-completion notifications: Telegram, desktop notifications (Windows/macOS/Linux), sound, and voice",
|
|
6
6
|
"type": "module",
|
|
7
7
|
"engines": {
|