@enactprotocol/cli 2.2.2 → 2.3.1

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 (68) hide show
  1. package/README.md +4 -37
  2. package/dist/commands/cache/index.js +5 -5
  3. package/dist/commands/cache/index.js.map +1 -1
  4. package/dist/commands/index.d.ts +1 -0
  5. package/dist/commands/index.d.ts.map +1 -1
  6. package/dist/commands/index.js +2 -0
  7. package/dist/commands/index.js.map +1 -1
  8. package/dist/commands/inspect/index.d.ts.map +1 -1
  9. package/dist/commands/inspect/index.js +3 -2
  10. package/dist/commands/inspect/index.js.map +1 -1
  11. package/dist/commands/install/index.d.ts +1 -1
  12. package/dist/commands/install/index.d.ts.map +1 -1
  13. package/dist/commands/install/index.js +64 -4
  14. package/dist/commands/install/index.js.map +1 -1
  15. package/dist/commands/learn/index.d.ts.map +1 -1
  16. package/dist/commands/learn/index.js +54 -0
  17. package/dist/commands/learn/index.js.map +1 -1
  18. package/dist/commands/list/index.d.ts +1 -1
  19. package/dist/commands/list/index.d.ts.map +1 -1
  20. package/dist/commands/list/index.js +7 -3
  21. package/dist/commands/list/index.js.map +1 -1
  22. package/dist/commands/run/index.d.ts.map +1 -1
  23. package/dist/commands/run/index.js +142 -41
  24. package/dist/commands/run/index.js.map +1 -1
  25. package/dist/commands/serve/index.d.ts +9 -0
  26. package/dist/commands/serve/index.d.ts.map +1 -0
  27. package/dist/commands/serve/index.js +24 -0
  28. package/dist/commands/serve/index.js.map +1 -0
  29. package/dist/commands/validate/index.d.ts.map +1 -1
  30. package/dist/commands/validate/index.js +7 -37
  31. package/dist/commands/validate/index.js.map +1 -1
  32. package/dist/index.d.ts +1 -1
  33. package/dist/index.d.ts.map +1 -1
  34. package/dist/index.js +4 -2
  35. package/dist/index.js.map +1 -1
  36. package/dist/utils/errors.js +2 -2
  37. package/package.json +7 -6
  38. package/src/commands/cache/index.ts +5 -5
  39. package/src/commands/env/README.md +1 -1
  40. package/src/commands/index.ts +3 -0
  41. package/src/commands/inspect/index.ts +3 -2
  42. package/src/commands/install/README.md +2 -2
  43. package/src/commands/install/index.ts +98 -4
  44. package/src/commands/learn/index.ts +67 -0
  45. package/src/commands/list/index.ts +12 -3
  46. package/src/commands/run/README.md +1 -1
  47. package/src/commands/run/index.ts +195 -48
  48. package/src/commands/serve/index.ts +26 -0
  49. package/src/commands/validate/index.ts +7 -42
  50. package/src/index.ts +5 -1
  51. package/src/utils/errors.ts +2 -2
  52. package/tests/commands/cache.test.ts +2 -2
  53. package/tests/commands/install-integration.test.ts +11 -12
  54. package/tests/commands/publish.test.ts +12 -2
  55. package/tests/commands/run.test.ts +3 -1
  56. package/tests/commands/serve.test.ts +82 -0
  57. package/tests/commands/sign.test.ts +1 -1
  58. package/tests/e2e.test.ts +56 -34
  59. package/tests/fixtures/calculator/skill.yaml +38 -0
  60. package/tests/fixtures/echo-tool/SKILL.md +3 -10
  61. package/tests/fixtures/env-tool/{enact.yaml → skill.yaml} +0 -6
  62. package/tests/fixtures/greeter/skill.yaml +22 -0
  63. package/tests/utils/ignore.test.ts +3 -1
  64. package/tsconfig.json +2 -1
  65. package/tsconfig.tsbuildinfo +1 -1
  66. package/tests/fixtures/calculator/enact.yaml +0 -34
  67. package/tests/fixtures/greeter/enact.yaml +0 -18
  68. /package/tests/fixtures/invalid-tool/{enact.yaml → skill.yaml} +0 -0
@@ -1,34 +0,0 @@
1
- enact: "2.0.0"
2
- name: test/calculator
3
- version: "2.0.0"
4
- description: A calculator tool that performs basic math operations
5
- from: python:3.12-alpine
6
- command: "python3 -c \"import json; print(json.dumps({'result': eval('${a} + ${b}' if '${operation}'=='add' else '${a} - ${b}' if '${operation}'=='subtract' else '${a} * ${b}' if '${operation}'=='multiply' else '${a} / ${b}'), 'operation': '${operation}'}))\""
7
- inputSchema:
8
- type: object
9
- properties:
10
- operation:
11
- type: string
12
- enum:
13
- - add
14
- - subtract
15
- - multiply
16
- - divide
17
- description: The math operation to perform
18
- a:
19
- type: number
20
- description: First operand
21
- b:
22
- type: number
23
- description: Second operand
24
- required:
25
- - operation
26
- - a
27
- - b
28
- outputSchema:
29
- type: object
30
- properties:
31
- result:
32
- type: number
33
- operation:
34
- type: string
@@ -1,18 +0,0 @@
1
- enact: "2.0.0"
2
- name: test/greeter
3
- version: "1.0.0"
4
- description: A simple greeting tool for testing
5
- from: alpine:latest
6
- command: echo '{"message":"Hello, ${name}!"}'
7
- inputSchema:
8
- type: object
9
- properties:
10
- name:
11
- type: string
12
- description: Name to greet
13
- default: World
14
- outputSchema:
15
- type: object
16
- properties:
17
- message:
18
- type: string