pontus-x_cli 1.0.2 → 1.1.4

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 (107) hide show
  1. package/README.md +124 -38
  2. package/bin/dev.js +5 -5
  3. package/bin/run.js +4 -5
  4. package/dist/commands/access.d.ts +1 -1
  5. package/dist/commands/access.js +3 -3
  6. package/dist/commands/access.js.map +1 -1
  7. package/dist/commands/change-price.d.ts +3 -3
  8. package/dist/commands/change-price.js +12 -11
  9. package/dist/commands/change-price.js.map +1 -1
  10. package/dist/commands/check-participant-compliance.d.ts +1 -1
  11. package/dist/commands/check-participant-compliance.js +13 -11
  12. package/dist/commands/check-participant-compliance.js.map +1 -1
  13. package/dist/commands/compute-results.d.ts +1 -1
  14. package/dist/commands/compute-results.js +7 -7
  15. package/dist/commands/compute-results.js.map +1 -1
  16. package/dist/commands/compute-status.d.ts +1 -1
  17. package/dist/commands/compute-status.js +7 -7
  18. package/dist/commands/compute-status.js.map +1 -1
  19. package/dist/commands/compute.d.ts +5 -4
  20. package/dist/commands/compute.js +60 -14
  21. package/dist/commands/compute.js.map +1 -1
  22. package/dist/commands/edit-additional-metadata.d.ts +13 -0
  23. package/dist/commands/edit-additional-metadata.js +88 -0
  24. package/dist/commands/edit-additional-metadata.js.map +1 -0
  25. package/dist/commands/edit-algo.d.ts +3 -3
  26. package/dist/commands/edit-algo.js +22 -13
  27. package/dist/commands/edit-algo.js.map +1 -1
  28. package/dist/commands/edit-asset-url.d.ts +3 -3
  29. package/dist/commands/edit-asset-url.js +12 -11
  30. package/dist/commands/edit-asset-url.js.map +1 -1
  31. package/dist/commands/edit-trusted-algos.d.ts +1 -1
  32. package/dist/commands/edit-trusted-algos.js +10 -6
  33. package/dist/commands/edit-trusted-algos.js.map +1 -1
  34. package/dist/commands/export-private-key.d.ts +2 -2
  35. package/dist/commands/export-private-key.js +27 -27
  36. package/dist/commands/export-private-key.js.map +1 -1
  37. package/dist/commands/generate-asset-credentials.d.ts +1 -1
  38. package/dist/commands/generate-asset-credentials.js +11 -11
  39. package/dist/commands/generate-asset-credentials.js.map +1 -1
  40. package/dist/commands/generate-did-web.d.ts +1 -1
  41. package/dist/commands/generate-did-web.js +11 -11
  42. package/dist/commands/generate-did-web.js.map +1 -1
  43. package/dist/commands/generate-participant-credentials.d.ts +1 -1
  44. package/dist/commands/generate-participant-credentials.js +10 -10
  45. package/dist/commands/generate-participant-credentials.js.map +1 -1
  46. package/dist/commands/get.d.ts +1 -1
  47. package/dist/commands/get.js +3 -3
  48. package/dist/commands/get.js.map +1 -1
  49. package/dist/commands/login.d.ts +2 -2
  50. package/dist/commands/login.js +16 -13
  51. package/dist/commands/login.js.map +1 -1
  52. package/dist/commands/logout.d.ts +1 -1
  53. package/dist/commands/logout.js +7 -7
  54. package/dist/commands/logout.js.map +1 -1
  55. package/dist/commands/publish.d.ts +5 -3
  56. package/dist/commands/publish.js +95 -27
  57. package/dist/commands/publish.js.map +1 -1
  58. package/dist/commands/render.d.ts +12 -0
  59. package/dist/commands/render.js +126 -0
  60. package/dist/commands/render.js.map +1 -0
  61. package/dist/commands/revoke.d.ts +7 -6
  62. package/dist/commands/revoke.js +92 -23
  63. package/dist/commands/revoke.js.map +1 -1
  64. package/dist/commands/self-description.d.ts +3 -3
  65. package/dist/commands/self-description.js +13 -8
  66. package/dist/commands/self-description.js.map +1 -1
  67. package/dist/config.d.ts +3 -6
  68. package/dist/config.js +55 -107
  69. package/dist/config.js.map +1 -1
  70. package/dist/index.d.ts +1 -1
  71. package/dist/index.js.map +1 -1
  72. package/dist/lib/aquarius.d.ts +7 -0
  73. package/dist/lib/aquarius.js +71 -0
  74. package/dist/lib/aquarius.js.map +1 -0
  75. package/dist/lib/gaia-x_compliance/generate-credentials/index.js +26 -25
  76. package/dist/lib/gaia-x_compliance/generate-credentials/index.js.map +1 -1
  77. package/dist/lib/manifest.d.ts +4 -0
  78. package/dist/lib/manifest.js +29 -0
  79. package/dist/lib/manifest.js.map +1 -0
  80. package/dist/lib/spec.d.ts +12 -0
  81. package/dist/lib/spec.js +266 -0
  82. package/dist/lib/spec.js.map +1 -0
  83. package/dist/lib/wallet.d.ts +1 -0
  84. package/dist/lib/wallet.js +14 -0
  85. package/dist/lib/wallet.js.map +1 -0
  86. package/dist/lib/yaml.d.ts +2 -0
  87. package/dist/lib/yaml.js +53 -0
  88. package/dist/lib/yaml.js.map +1 -0
  89. package/dist/scripts/json-schema.d.ts +1 -0
  90. package/dist/scripts/json-schema.js +24 -0
  91. package/dist/scripts/json-schema.js.map +1 -0
  92. package/dist/types/manifest-schema.json +52 -0
  93. package/dist/types/manifest.d.ts +17 -0
  94. package/dist/types/manifest.js +14 -0
  95. package/dist/types/manifest.js.map +1 -0
  96. package/dist/types/schema.d.ts +1 -2
  97. package/dist/types/schema.js +3 -2
  98. package/dist/types/schema.js.map +1 -1
  99. package/dist/types/schema.json +24 -72
  100. package/dist/utils/connection.d.ts +3 -3
  101. package/dist/utils/connection.js +2 -2
  102. package/dist/utils/connection.js.map +1 -1
  103. package/oclif.manifest.json +169 -19
  104. package/package.json +20 -18
  105. package/dist/lib/publishFromFile.d.ts +0 -2
  106. package/dist/lib/publishFromFile.js +0 -143
  107. package/dist/lib/publishFromFile.js.map +0 -1
@@ -31,12 +31,7 @@
31
31
  },
32
32
  "type": {
33
33
  "description": "Field type.",
34
- "enum": [
35
- "text",
36
- "number",
37
- "boolean",
38
- "select"
39
- ],
34
+ "enum": ["text", "number", "boolean", "select"],
40
35
  "type": "string"
41
36
  }
42
37
  },
@@ -84,12 +79,7 @@
84
79
  },
85
80
  "type": {
86
81
  "description": "Field type.",
87
- "enum": [
88
- "text",
89
- "number",
90
- "boolean",
91
- "select"
92
- ],
82
+ "enum": ["text", "number", "boolean", "select"],
93
83
  "type": "string"
94
84
  }
95
85
  },
@@ -104,13 +94,7 @@
104
94
  "type": "object"
105
95
  },
106
96
  "FileTypes": {
107
- "enum": [
108
- "url",
109
- "graphql",
110
- "arweave",
111
- "ipfs",
112
- "smartcontract"
113
- ],
97
+ "enum": ["url", "graphql", "arweave", "ipfs", "smartcontract"],
114
98
  "type": "string"
115
99
  },
116
100
  "MetadataConfig": {
@@ -157,12 +141,7 @@
157
141
  "type": "string"
158
142
  }
159
143
  },
160
- "required": [
161
- "entrypoint",
162
- "image",
163
- "tag",
164
- "checksum"
165
- ],
144
+ "required": ["entrypoint", "image", "tag", "checksum"],
166
145
  "type": "object"
167
146
  },
168
147
  "language": {
@@ -178,13 +157,10 @@
178
157
  "type": "string"
179
158
  }
180
159
  },
181
- "required": [
182
- "container"
183
- ],
160
+ "required": ["container"],
184
161
  "type": "object"
185
162
  },
186
163
  "author": {
187
- "description": "Name of the entity generating this data (e.g. Tfl, Disney Corp, etc.).",
188
164
  "type": "string"
189
165
  },
190
166
  "categories": {
@@ -206,6 +182,9 @@
206
182
  "description": "Details of what the resource is.",
207
183
  "type": "string"
208
184
  },
185
+ "did": {
186
+ "type": "string"
187
+ },
209
188
  "license": {
210
189
  "description": "Short name referencing the license of the asset. If it’s not specified, the following value will be added: “No License Specified”.",
211
190
  "type": "string"
@@ -221,6 +200,12 @@
221
200
  "description": "Descriptive name or title of the asset.",
222
201
  "type": "string"
223
202
  },
203
+ "network": {
204
+ "type": "string"
205
+ },
206
+ "owner": {
207
+ "type": "string"
208
+ },
224
209
  "tags": {
225
210
  "description": "Array of keywords or tags used to describe this content. Empty by default.",
226
211
  "items": {
@@ -230,20 +215,11 @@
230
215
  },
231
216
  "type": {
232
217
  "description": "Asset type. Includes \"dataset\" (e.g. csv file), \"algorithm\" (e.g. Python script). Each type needs a different subset of metadata attributes.",
233
- "enum": [
234
- "dataset",
235
- "algorithm"
236
- ],
218
+ "enum": ["dataset", "algorithm"],
237
219
  "type": "string"
238
220
  }
239
221
  },
240
- "required": [
241
- "author",
242
- "description",
243
- "license",
244
- "name",
245
- "type"
246
- ],
222
+ "required": ["description", "license", "name", "type"],
247
223
  "type": "object"
248
224
  },
249
225
  "NftCreateDataWithoutOwner": {
@@ -323,10 +299,7 @@
323
299
  "type": "string"
324
300
  }
325
301
  },
326
- "required": [
327
- "name",
328
- "symbol"
329
- ],
302
+ "required": ["name", "symbol"],
330
303
  "type": "object"
331
304
  },
332
305
  "fileType": {
@@ -345,23 +318,15 @@
345
318
  "type": "number"
346
319
  },
347
320
  "currency": {
348
- "enum": [
349
- "OCEAN",
350
- "EUROe"
351
- ],
321
+ "enum": ["OCEAN", "EUROe", "EURAU"],
352
322
  "type": "string"
353
323
  },
354
324
  "type": {
355
- "enum": [
356
- "free",
357
- "fixed"
358
- ],
325
+ "enum": ["free", "fixed"],
359
326
  "type": "string"
360
327
  }
361
328
  },
362
- "required": [
363
- "type"
364
- ],
329
+ "required": ["type"],
365
330
  "type": "object"
366
331
  },
367
332
  "serviceEndpoint": {
@@ -401,21 +366,14 @@
401
366
  "type": "array"
402
367
  }
403
368
  },
404
- "required": [
405
- "metadata",
406
- "nftData",
407
- "service"
408
- ],
369
+ "required": ["metadata", "nftData", "service"],
409
370
  "type": "object"
410
371
  },
411
372
  "ServiceFileType": {
412
373
  "$ref": "#/definitions/UrlFile"
413
374
  },
414
375
  "ServiceTypes": {
415
- "enum": [
416
- "access",
417
- "compute"
418
- ],
376
+ "enum": ["access", "compute"],
419
377
  "type": "string"
420
378
  },
421
379
  "TrustedAlgorithmAsset": {
@@ -431,9 +389,7 @@
431
389
  "type": "array"
432
390
  }
433
391
  },
434
- "required": [
435
- "did"
436
- ],
392
+ "required": ["did"],
437
393
  "type": "object"
438
394
  },
439
395
  "UrlFile": {
@@ -463,11 +419,7 @@
463
419
  "type": "string"
464
420
  }
465
421
  },
466
- "required": [
467
- "type",
468
- "url",
469
- "method"
470
- ],
422
+ "required": ["type", "url", "method"],
471
423
  "type": "object"
472
424
  }
473
425
  }
@@ -1,6 +1,6 @@
1
- import { Nautilus } from '@deltadao/nautilus';
2
- import { Wallet } from 'ethers';
3
- import { FixedRatePricingConfigGenerator, NetworkConfig } from '../config';
1
+ import { Nautilus } from "@deltadao/nautilus";
2
+ import { Wallet } from "ethers";
3
+ import { type FixedRatePricingConfigGenerator, type NetworkConfig } from "../config";
4
4
  export declare class Connection {
5
5
  wallet: Wallet;
6
6
  nautilus: Nautilus;
@@ -14,11 +14,11 @@ class Connection {
14
14
  static async connect(envOverrides) {
15
15
  const env = Object.assign(Object.assign({}, process.env), envOverrides);
16
16
  if (!env.NETWORK) {
17
- throw new Error(`Set your network in the .env file. Supported networks are ${Object.values(config_1.Network).join(', ')}.`);
17
+ throw new Error(`Set your network in the .env file. Supported networks are ${Object.values(config_1.Network).join(", ")}.`);
18
18
  }
19
19
  const selectedEnvNetwork = env.NETWORK.toUpperCase();
20
20
  if (!(selectedEnvNetwork in config_1.Network)) {
21
- throw new Error(`Invalid network selection: ${selectedEnvNetwork}. Supported networks are ${Object.values(config_1.Network).join(', ')}.`);
21
+ throw new Error(`Invalid network selection: ${selectedEnvNetwork}. Supported networks are ${Object.values(config_1.Network).join(", ")}.`);
22
22
  }
23
23
  console.log(`Your selected network is ${config_1.Network[selectedEnvNetwork]}`);
24
24
  const networkConfig = config_1.NETWORK_CONFIGS[selectedEnvNetwork];
@@ -1 +1 @@
1
- {"version":3,"file":"connection.js","sourceRoot":"","sources":["../../src/utils/connection.ts"],"names":[],"mappings":";;;AAAA,iDAA2C;AAC3C,mCAAwC;AAExC,sCAAmH;AAEnH,MAAa,UAAU;IACrB,YACS,MAAc,EACd,QAAkB,EAClB,aAA4B,EAC5B,aAA6D;QAH7D,WAAM,GAAN,MAAM,CAAQ;QACd,aAAQ,GAAR,QAAQ,CAAU;QAClB,kBAAa,GAAb,aAAa,CAAe;QAC5B,kBAAa,GAAb,aAAa,CAAgD;IACnE,CAAC;IAEG,MAAM,CAAC,KAAK,CAAC,OAAO,CAAC,YAAqC;QAC/D,MAAM,GAAG,mCAAO,OAAO,CAAC,GAAG,GAAK,YAAY,CAAC,CAAA;QAE7C,IAAI,CAAC,GAAG,CAAC,OAAO,EAAE,CAAC;YAC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S,CAAC,eAAe,CAAC,aAAa,CAAC,OAAO,CAAC,CAAC;QACtE,MAAM,MAAM,GAAG,IAAI,eAAM,CAAC,GAAG,CAAC,WAAW,EAAE,QAAQ,CAAC,CAAC;QACrD,MAAM,QAAQ,GAAG,MAAM,mBAAQ,CAAC,MAAM,CAAC,MAAM,EAAE,aAAa,CAAC,CAAC;QAC9D,OAAO,CAAC,GAAG,CAAC,gBAAgB,MAAM,CAAC,OAAO,EAAE,CAAC,CAAC;QAC9C,OAAO,IAAI,UAAU,CAAC,MAAM,EAAE,QAAQ,EAAE,aAAa,EAAE,aAAa,CAAC,CAAC;IACxE,CAAC;CACF;AA9CD,gCA8CC"}
@@ -204,14 +204,24 @@
204
204
  },
205
205
  "description": "Compute the algorithm on one or more datasets.",
206
206
  "examples": [
207
- "<%= config.bin %> <%= command.id %> did:op:34e2ff9baf030318b13ff3940ab0885bb11fee49a8597123392983f5a0db8a35 -d did:op:d8a36ff74d36e54ce245d27689330fc39debb2fdfeac09d4a08b24b68cf5053d"
207
+ "<%= config.bin %> <%= command.id %> did:op:34e2f... -d did:op:d8a36... -d did:op:12b45...",
208
+ "<%= config.bin %> <%= command.id %> did:op:34e2f... -t tag1 -t tag2"
208
209
  ],
209
210
  "flags": {
210
211
  "datasets": {
211
212
  "char": "d",
212
213
  "description": "Dataset DIDs",
213
214
  "name": "datasets",
214
- "required": true,
215
+ "required": false,
216
+ "hasDynamicHelp": false,
217
+ "multiple": true,
218
+ "type": "option"
219
+ },
220
+ "tags": {
221
+ "char": "t",
222
+ "description": "Tags to filter datasets (they must have all the provided tags)",
223
+ "name": "tags",
224
+ "required": false,
215
225
  "hasDynamicHelp": false,
216
226
  "multiple": true,
217
227
  "type": "option"
@@ -240,6 +250,49 @@
240
250
  "compute.js"
241
251
  ]
242
252
  },
253
+ "edit-additional-metadata": {
254
+ "aliases": [],
255
+ "args": {
256
+ "did": {
257
+ "description": "Algorithm DID",
258
+ "name": "did",
259
+ "required": true
260
+ },
261
+ "metadatafile": {
262
+ "description": "JSON metadata file path",
263
+ "name": "metadatafile",
264
+ "required": true
265
+ }
266
+ },
267
+ "description": "Change the container additional metadata for a given DID",
268
+ "examples": [
269
+ "<%= config.bin %> <%= command.id %> did:op:dcdb747f8feff3122c6d6c0f45a339a6e09415e721f98f61cc2c1d62ab35a21f ./metadata.json"
270
+ ],
271
+ "flags": {
272
+ "yes": {
273
+ "char": "y",
274
+ "description": "Skip confirmation prompt",
275
+ "name": "yes",
276
+ "required": false,
277
+ "allowNo": false,
278
+ "type": "boolean"
279
+ }
280
+ },
281
+ "hasDynamicHelp": false,
282
+ "hiddenAliases": [],
283
+ "id": "edit-additional-metadata",
284
+ "pluginAlias": "pontus-x_cli",
285
+ "pluginName": "pontus-x_cli",
286
+ "pluginType": "core",
287
+ "strict": true,
288
+ "enableJsonFlag": false,
289
+ "isESM": false,
290
+ "relativePath": [
291
+ "dist",
292
+ "commands",
293
+ "edit-additional-metadata.js"
294
+ ]
295
+ },
243
296
  "edit-algo": {
244
297
  "aliases": [],
245
298
  "args": {
@@ -394,6 +447,15 @@
394
447
  "<%= config.bin %> <%= command.id %>"
395
448
  ],
396
449
  "flags": {
450
+ "filepath": {
451
+ "char": "f",
452
+ "description": "File path to save the encrypted private key (default is <address>.json)",
453
+ "name": "filepath",
454
+ "required": false,
455
+ "hasDynamicHelp": false,
456
+ "multiple": false,
457
+ "type": "option"
458
+ },
397
459
  "password": {
398
460
  "char": "p",
399
461
  "description": "Password to encrypt the private key file",
@@ -411,15 +473,6 @@
411
473
  "hasDynamicHelp": false,
412
474
  "multiple": false,
413
475
  "type": "option"
414
- },
415
- "filepath": {
416
- "char": "f",
417
- "description": "File path to save the encrypted private key (default is <address>.json)",
418
- "name": "filepath",
419
- "required": false,
420
- "hasDynamicHelp": false,
421
- "multiple": false,
422
- "type": "option"
423
476
  }
424
477
  },
425
478
  "hasDynamicHelp": false,
@@ -701,13 +754,14 @@
701
754
  "aliases": [],
702
755
  "args": {
703
756
  "path": {
704
- "description": "Path to the JSON/YAML or TS file describing the asset to publish",
757
+ "description": "Path to find a JSON/YAML or TS file describing the asset to publish",
705
758
  "name": "path",
706
759
  "required": true
707
760
  }
708
761
  },
709
762
  "description": "Publish the asset as instructed in the provided script folder.",
710
763
  "examples": [
764
+ "<%= config.bin %> <%= command.id %> samples/publish/algo/",
711
765
  "<%= config.bin %> <%= command.id %> samples/publish/algo/spec.json",
712
766
  "<%= config.bin %> <%= command.id %> samples/publish/algo/spec.yaml",
713
767
  "<%= config.bin %> <%= command.id %> samples/publish/algo/index.ts"
@@ -719,15 +773,30 @@
719
773
  "allowNo": false,
720
774
  "type": "boolean"
721
775
  },
776
+ "manifest": {
777
+ "char": "m",
778
+ "description": "Path to the manifest file",
779
+ "name": "manifest",
780
+ "default": "./manifest.yaml",
781
+ "hasDynamicHelp": false,
782
+ "multiple": false,
783
+ "type": "option"
784
+ },
722
785
  "provider": {
723
786
  "char": "p",
724
787
  "description": "The Provider URL",
725
788
  "name": "provider",
726
- "required": true,
727
789
  "default": "https://provider.agrospai.udl.cat",
728
790
  "hasDynamicHelp": false,
729
791
  "multiple": false,
730
792
  "type": "option"
793
+ },
794
+ "recursive": {
795
+ "char": "r",
796
+ "description": "Recursively publish assets in a directory (only for JSON/YAML files)",
797
+ "name": "recursive",
798
+ "allowNo": false,
799
+ "type": "boolean"
731
800
  }
732
801
  },
733
802
  "hasDynamicHelp": false,
@@ -745,20 +814,101 @@
745
814
  "publish.js"
746
815
  ]
747
816
  },
748
- "revoke": {
817
+ "render": {
749
818
  "aliases": [],
750
819
  "args": {
751
- "dids": {
752
- "description": "DIDs to revoke",
753
- "name": "dids",
754
- "required": true
820
+ "did": {
821
+ "description": "Dataset DID",
822
+ "name": "did",
823
+ "required": false
824
+ }
825
+ },
826
+ "flags": {
827
+ "dst": {
828
+ "char": "d",
829
+ "description": "Destination folder to save the rendered specs",
830
+ "name": "dst",
831
+ "required": false,
832
+ "default": "rendered",
833
+ "hasDynamicHelp": false,
834
+ "multiple": false,
835
+ "type": "option"
836
+ },
837
+ "tags": {
838
+ "char": "t",
839
+ "description": "Tags to filter datasets (they must have all the provided tags)",
840
+ "name": "tags",
841
+ "required": false,
842
+ "hasDynamicHelp": false,
843
+ "multiple": true,
844
+ "type": "option"
845
+ },
846
+ "onlyAccess": {
847
+ "char": "a",
848
+ "description": "Only render datasets with an access service",
849
+ "name": "onlyAccess",
850
+ "required": false,
851
+ "allowNo": false,
852
+ "type": "boolean"
755
853
  }
756
854
  },
855
+ "hasDynamicHelp": false,
856
+ "hiddenAliases": [],
857
+ "id": "render",
858
+ "pluginAlias": "pontus-x_cli",
859
+ "pluginName": "pontus-x_cli",
860
+ "pluginType": "core",
861
+ "strict": true,
862
+ "enableJsonFlag": false,
863
+ "isESM": false,
864
+ "relativePath": [
865
+ "dist",
866
+ "commands",
867
+ "render.js"
868
+ ]
869
+ },
870
+ "revoke": {
871
+ "aliases": [],
872
+ "args": {},
757
873
  "description": "Publisher revocation of one or more owned DIDs",
758
874
  "examples": [
759
875
  "<%= config.bin %> <%= command.id %> did:op:ffeee8c8f19328985ef6743b08e61ef89d5141027fd47612e32e7900cacd2b7a did:op:abcee8c8f19328985ef6743b08e61ef89d5141027fd47612e32e7900cacd2b7b"
760
876
  ],
761
877
  "flags": {
878
+ "dids": {
879
+ "char": "d",
880
+ "description": "DID to revoke",
881
+ "name": "dids",
882
+ "required": false,
883
+ "hasDynamicHelp": false,
884
+ "multiple": true,
885
+ "type": "option"
886
+ },
887
+ "manifest": {
888
+ "char": "m",
889
+ "description": "Path to the manifest file",
890
+ "name": "manifest",
891
+ "default": "./manifest.yaml",
892
+ "hasDynamicHelp": false,
893
+ "multiple": false,
894
+ "type": "option"
895
+ },
896
+ "paths": {
897
+ "char": "p",
898
+ "description": "Path to find a JSON/YAML file describing the assets to revoke",
899
+ "name": "paths",
900
+ "required": false,
901
+ "hasDynamicHelp": false,
902
+ "multiple": true,
903
+ "type": "option"
904
+ },
905
+ "recursive": {
906
+ "char": "r",
907
+ "description": "Recursively revoke assets in a directory (only for JSON/YAML files)",
908
+ "name": "recursive",
909
+ "allowNo": false,
910
+ "type": "boolean"
911
+ },
762
912
  "yes": {
763
913
  "char": "y",
764
914
  "description": "Skip confirmation prompt",
@@ -826,5 +976,5 @@
826
976
  ]
827
977
  }
828
978
  },
829
- "version": "1.0.2"
979
+ "version": "1.1.4"
830
980
  }
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "pontus-x_cli",
3
3
  "description": "Command Line Interface for the Pontus-X Data Space Ecosystem",
4
- "version": "1.0.2",
4
+ "version": "1.1.4",
5
5
  "author": "AgrospAI",
6
6
  "bin": {
7
7
  "pontus-x_cli": "bin/run.js"
@@ -16,34 +16,35 @@
16
16
  "@oclif/core": "^4",
17
17
  "@oclif/plugin-autocomplete": "^3.2.34",
18
18
  "@oclif/plugin-help": "^6",
19
- "@types/js-yaml": "^4.0.9",
20
19
  "ajv": "^8.17.1",
21
20
  "axios": "^1.7.9",
21
+ "chalk": "^5.6.2",
22
22
  "dotenv": "^16.4.7",
23
23
  "ethereumjs-wallet": "^1.0.2",
24
24
  "ethers": "^5.7.2",
25
25
  "handlebars": "^4.7.8",
26
- "js-yaml": "^4.1.1",
27
26
  "oclif": "^4.22.14",
28
27
  "readline-sync": "^1.4.10",
29
- "ts-json-schema-generator": "^2.4.0"
28
+ "ts-json-schema-generator": "^2.4.0",
29
+ "yaml": "^2.8.2",
30
+ "zod": "^4.3.6"
30
31
  },
31
32
  "devDependencies": {
32
- "@eslint/compat": "^1",
33
- "@oclif/prettier-config": "^0.2.1",
33
+ "@biomejs/biome": "2.3.14",
34
34
  "@oclif/test": "^4",
35
35
  "@types/figlet": "^1.7.0",
36
36
  "@types/node": "^18",
37
37
  "@types/readline-sync": "^1.4.8",
38
38
  "@vitest/ui": "^3.2.4",
39
39
  "copyfiles": "^2.4.1",
40
- "eslint": "^9",
41
- "eslint-config-oclif": "^6",
42
- "eslint-config-prettier": "^10.1.8",
40
+ "jest-diff": "^30.2.0",
43
41
  "oclif": "^4",
44
42
  "prettier": "3.6.2",
43
+ "prettier-plugin-organize-imports": "^4.3.0",
45
44
  "shx": "^0.3.3",
46
45
  "ts-node": "^10.9.2",
46
+ "tsc-alias": "^1.8.16",
47
+ "tsconfig-paths": "^4.2.0",
47
48
  "typescript": "^5.9.2",
48
49
  "vitest": "^3.2.4"
49
50
  },
@@ -73,21 +74,22 @@
73
74
  "url": "git+https://github.com/AgrospAI/pontus-x_cli.git"
74
75
  },
75
76
  "scripts": {
76
- "dev": "ts-node ./bin/dev.js",
77
- "build": "shx rm -rf dist tsconfig.tsbuildinfo && tsc -b && shx cp -r src/lib/gaia-x_compliance/generate-credentials/templates dist/lib/gaia-x_compliance/generate-credentials/",
78
- "lint": "eslint",
79
- "lint:fix": "eslint --fix",
77
+ "dev": "npm run build && ts-node -r tsconfig-paths/register ./bin/dev.js",
78
+ "build": "shx rm -rf dist tsconfig.tsbuildinfo && tsc -b && tsc-alias -p tsconfig.json && shx cp -r src/lib/gaia-x_compliance/generate-credentials/templates dist/lib/gaia-x_compliance/generate-credentials/",
79
+ "format": "npx @biomejs/biome format --write",
80
+ "lint": "npx @biomejs/biome lint --write",
81
+ "fix": "npx @biomejs/biome check --write",
82
+ "check": "tsc --noEmit",
80
83
  "postpack": "shx rm -f oclif.manifest.json",
81
84
  "prepack": "oclif manifest && oclif readme",
82
85
  "version": "oclif readme && git add README.md",
83
- "format": "npx prettier . --write",
84
86
  "test": "vitest --run",
85
- "test:init": "ts-node test/helpers/assets.ts initializeAssets",
86
- "test:clean": "ts-node test/helpers/assets.ts revokeAssets",
87
+ "test:init": "ts-node -r tsconfig-paths/register test/helpers/assets.ts initializeAssets",
88
+ "test:clean": "ts-node -r tsconfig-paths/register test/helpers/assets.ts revokeAssets",
87
89
  "test:ui": "vitest --ui",
88
90
  "test:watch": "vitest --watch",
89
- "tsc": "tsc --noEmit",
90
- "schema": "ts-json-schema-generator --path 'src/types/publish.d.ts' --type 'PublishConfig' --expose 'export' --out 'src/types/schema.json'",
91
+ "schema:publish": "ts-json-schema-generator --path 'src/types/publish.d.ts' --type 'PublishConfig' --expose 'export' --out 'src/types/schema.json'",
92
+ "schema:manifest": "ts-node src/scripts/json-schema.ts generateManifestJsonSchema",
91
93
  "local-install": "npm install -g ."
92
94
  },
93
95
  "types": "dist/index.d.ts"
@@ -1,2 +0,0 @@
1
- import { Connection } from '../utils/connection';
2
- export declare const publishFromFile: (filePath: string, providerUrl: string, connection: Connection, dryRun: boolean) => Promise<string | undefined>;