@spzhongwin/skill-logger-plugin 1.0.9 → 1.0.11

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 (54) hide show
  1. package/dist/index.js +73 -5
  2. package/openclaw.plugin.json +50 -50
  3. package/package.json +37 -37
  4. package/src/active-skills.test.ts +32 -32
  5. package/src/active-skills.ts +77 -77
  6. package/src/config-sync.test.ts +165 -165
  7. package/src/config-sync.ts +544 -544
  8. package/src/hooks.test.ts +251 -251
  9. package/src/hooks.ts +517 -517
  10. package/src/http.ts +61 -61
  11. package/src/identity.ts +64 -64
  12. package/src/index.test.ts +53 -53
  13. package/src/index.ts +226 -226
  14. package/src/integration.test.ts +119 -119
  15. package/src/matcher.test.ts +170 -170
  16. package/src/matcher.ts +393 -393
  17. package/src/paths.test.ts +57 -57
  18. package/src/paths.ts +84 -84
  19. package/src/reporter.test.ts +139 -139
  20. package/src/reporter.ts +298 -298
  21. package/src/sample-config.json +72 -72
  22. package/src/semver.test.ts +23 -23
  23. package/src/semver.ts +60 -60
  24. package/src/skill-version.ts +53 -53
  25. package/src/types.ts +198 -198
  26. package/src/updater.test.ts +237 -237
  27. package/src/updater.ts +433 -433
  28. package/src/ws-client.test.ts +37 -37
  29. package/src/ws-client.ts +642 -641
  30. package/test-ws.ts +17 -17
  31. package/tsconfig.json +14 -14
  32. package/dist/active-skills.js +0 -67
  33. package/dist/active-skills.test.js +0 -29
  34. package/dist/config-sync.js +0 -439
  35. package/dist/config-sync.test.js +0 -145
  36. package/dist/hooks.js +0 -337
  37. package/dist/hooks.test.js +0 -123
  38. package/dist/http.js +0 -54
  39. package/dist/identity.js +0 -56
  40. package/dist/index.test.js +0 -39
  41. package/dist/integration.test.js +0 -102
  42. package/dist/matcher.js +0 -362
  43. package/dist/matcher.test.js +0 -139
  44. package/dist/paths.js +0 -62
  45. package/dist/paths.test.js +0 -49
  46. package/dist/reporter.js +0 -267
  47. package/dist/reporter.test.js +0 -128
  48. package/dist/semver.js +0 -64
  49. package/dist/semver.test.js +0 -21
  50. package/dist/skill-version.js +0 -23
  51. package/dist/types.js +0 -9
  52. package/dist/updater.js +0 -352
  53. package/dist/updater.test.js +0 -212
  54. package/dist/ws-client.js +0 -484
@@ -1,37 +1,37 @@
1
- import { describe, it } from "node:test";
2
- import assert from "node:assert/strict";
3
- import {
4
- normalizeAssistantUserId,
5
- parseAssistantWorkspaceAgentId,
6
- } from "./ws-client.ts";
7
-
8
- describe("assistant workspace naming", () => {
9
- it("accepts workspace-assistant-* only when suffix is at least 5 digits", () => {
10
- assert.equal(parseAssistantWorkspaceAgentId("workspace-assistant-12345"), "assistant-12345");
11
- assert.equal(
12
- parseAssistantWorkspaceAgentId("workspace-assistant-12342325232333223223"),
13
- "assistant-12342325232333223223"
14
- );
15
- assert.equal(parseAssistantWorkspaceAgentId("workspace-assistant-000001"), "assistant-000001");
16
- });
17
-
18
- it("rejects short, non-numeric, and malformed workspace names", () => {
19
- assert.equal(parseAssistantWorkspaceAgentId("workspace-assistant-1234"), undefined);
20
- assert.equal(parseAssistantWorkspaceAgentId("workspace-assistant-1234a"), undefined);
21
- assert.equal(parseAssistantWorkspaceAgentId("workspace-assistant-abcde"), undefined);
22
- assert.equal(parseAssistantWorkspaceAgentId("workspace-coder-12345"), undefined);
23
- });
24
-
25
- it("normalizes command userId using the same numeric suffix rule", () => {
26
- assert.equal(normalizeAssistantUserId("12345"), "12345");
27
- assert.equal(normalizeAssistantUserId("assistant-12345"), "12345");
28
- assert.equal(normalizeAssistantUserId("assistant-000001"), "000001");
29
- });
30
-
31
- it("rejects unsafe or non-conforming command userId values", () => {
32
- assert.equal(normalizeAssistantUserId("1234"), undefined);
33
- assert.equal(normalizeAssistantUserId("assistant-1234"), undefined);
34
- assert.equal(normalizeAssistantUserId("assistant-1234a"), undefined);
35
- assert.equal(normalizeAssistantUserId("../assistant-12345"), undefined);
36
- });
37
- });
1
+ import { describe, it } from "node:test";
2
+ import assert from "node:assert/strict";
3
+ import {
4
+ normalizeAssistantUserId,
5
+ parseAssistantWorkspaceAgentId,
6
+ } from "./ws-client.ts";
7
+
8
+ describe("assistant workspace naming", () => {
9
+ it("accepts workspace-assistant-* only when suffix is at least 5 digits", () => {
10
+ assert.equal(parseAssistantWorkspaceAgentId("workspace-assistant-12345"), "assistant-12345");
11
+ assert.equal(
12
+ parseAssistantWorkspaceAgentId("workspace-assistant-12342325232333223223"),
13
+ "assistant-12342325232333223223"
14
+ );
15
+ assert.equal(parseAssistantWorkspaceAgentId("workspace-assistant-000001"), "assistant-000001");
16
+ });
17
+
18
+ it("rejects short, non-numeric, and malformed workspace names", () => {
19
+ assert.equal(parseAssistantWorkspaceAgentId("workspace-assistant-1234"), undefined);
20
+ assert.equal(parseAssistantWorkspaceAgentId("workspace-assistant-1234a"), undefined);
21
+ assert.equal(parseAssistantWorkspaceAgentId("workspace-assistant-abcde"), undefined);
22
+ assert.equal(parseAssistantWorkspaceAgentId("workspace-coder-12345"), undefined);
23
+ });
24
+
25
+ it("normalizes command userId using the same numeric suffix rule", () => {
26
+ assert.equal(normalizeAssistantUserId("12345"), "12345");
27
+ assert.equal(normalizeAssistantUserId("assistant-12345"), "12345");
28
+ assert.equal(normalizeAssistantUserId("assistant-000001"), "000001");
29
+ });
30
+
31
+ it("rejects unsafe or non-conforming command userId values", () => {
32
+ assert.equal(normalizeAssistantUserId("1234"), undefined);
33
+ assert.equal(normalizeAssistantUserId("assistant-1234"), undefined);
34
+ assert.equal(normalizeAssistantUserId("assistant-1234a"), undefined);
35
+ assert.equal(normalizeAssistantUserId("../assistant-12345"), undefined);
36
+ });
37
+ });