sim 2.1.1-preview.42.1 → 2.1.1-preview.44.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 (2) hide show
  1. package/dist/index.js +12 -6
  2. package/package.json +1 -1
package/dist/index.js CHANGED
@@ -7659,7 +7659,7 @@ var V2_OPERATIONS = {
7659
7659
  method: "DELETE",
7660
7660
  path: "/api/v2/credentials/[credentialId]",
7661
7661
  pathParams: ["credentialId"],
7662
- pathParamDocs: { credentialId: "Credential to update or disconnect." },
7662
+ pathParamDocs: { credentialId: "Credential to disconnect." },
7663
7663
  responseMode: "json",
7664
7664
  summary: "Disconnect Credential",
7665
7665
  query: {
@@ -10788,7 +10788,7 @@ var V2_OPERATIONS = {
10788
10788
  method: "PATCH",
10789
10789
  path: "/api/v2/credentials/[credentialId]",
10790
10790
  pathParams: ["credentialId"],
10791
- pathParamDocs: { credentialId: "Credential to update or disconnect." },
10791
+ pathParamDocs: { credentialId: "Credential to update." },
10792
10792
  responseMode: "json",
10793
10793
  summary: "Update Credential",
10794
10794
  query: {
@@ -12267,7 +12267,7 @@ var CLI_CONTRACT = {
12267
12267
  listFiles: {
12268
12268
  flags: {
12269
12269
  folderPath: FOLDER_PATH_FLAG,
12270
- recursive: { boolean: true }
12270
+ recursive: { boolean: true, negatable: true }
12271
12271
  },
12272
12272
  columns: [
12273
12273
  { header: "id" },
@@ -14417,6 +14417,10 @@ function describeField(flag, descriptor, name, field) {
14417
14417
  function literalNullHint(documented, name) {
14418
14418
  return /\bnull\b/i.test(documented) ? ` (--${name} null sends the word, not JSON null)` : "";
14419
14419
  }
14420
+ var WIRE_VOCABULARY_SENTENCE = /\s*The listed spellings[^.]*\.\s*/g;
14421
+ function withoutWireVocabulary(documented) {
14422
+ return documented.replace(WIRE_VOCABULARY_SENTENCE, " ").trim();
14423
+ }
14420
14424
  function addFieldOption(command, operation, field, descriptor, slot) {
14421
14425
  if (field === PROFILE_INJECTED_FIELD || field === "cursor")
14422
14426
  return;
@@ -14431,13 +14435,15 @@ function addFieldOption(command, operation, field, descriptor, slot) {
14431
14435
  }
14432
14436
  const documented = describeField(flag, descriptor, name, field);
14433
14437
  if (descriptor.kind === "boolean" || flag.boolean) {
14438
+ const booleanDoc = withoutWireVocabulary(documented);
14434
14439
  if (descriptor.required) {
14435
- command.addOption(new Option(`${short}--${name} <true|false>`, `${documented} (required)`).choices(["true", "false"]).makeOptionMandatory());
14440
+ command.addOption(new Option(`${short}--${name} <true|false>`, `${booleanDoc} (required)`).choices(["true", "false"]).makeOptionMandatory());
14436
14441
  return;
14437
14442
  }
14438
- command.option(`${short}--${name}`, documented);
14439
- if (!flag.boolean)
14443
+ command.option(`${short}--${name}`, booleanDoc);
14444
+ if (!flag.boolean || flag.negatable) {
14440
14445
  command.option(`--no-${name}`, `Send --${name} as false`);
14446
+ }
14441
14447
  return;
14442
14448
  }
14443
14449
  const takesList = flag.list === true;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "sim",
3
- "version": "2.1.1-preview.42.1",
3
+ "version": "2.1.1-preview.44.1",
4
4
  "description": "Sim CLI - talk to the Sim API from your terminal",
5
5
  "type": "module",
6
6
  "bin": {