@salesforce/plugin-command-reference 1.3.19 → 1.3.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/CHANGELOG.md CHANGED
@@ -2,6 +2,8 @@
2
2
 
3
3
  All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
4
4
 
5
+ ### [1.3.20](https://github.com/forcedotcom/plugin-command-reference/compare/v1.3.19...v1.3.20) (2022-05-24)
6
+
5
7
  ### [1.3.19](https://github.com/forcedotcom/plugin-command-reference/compare/v1.3.17...v1.3.19) (2022-05-17)
6
8
 
7
9
  ### Bug Fixes
package/README.md CHANGED
@@ -97,6 +97,6 @@ OPTIONS
97
97
  this command invocation
98
98
  ```
99
99
 
100
- _See code: [src/commands/commandreference/generate.ts](https://github.com/forcedotcom/plugin-command-reference/blob/v1.3.19/src/commands/commandreference/generate.ts)_
100
+ _See code: [src/commands/commandreference/generate.ts](https://github.com/forcedotcom/plugin-command-reference/blob/v1.3.20/src/commands/commandreference/generate.ts)_
101
101
 
102
102
  <!-- commandsstop -->
@@ -42,10 +42,17 @@ class Command extends ditamap_1.Ditamap {
42
42
  delete command.examples;
43
43
  }
44
44
  }
45
+ let examples;
46
+ const binary = 'sfdx';
47
+ if (command.examples) {
48
+ examples = Array.isArray(command.examples) ? command.examples : [command.examples];
49
+ examples = examples.map((example) => example.replace(/<%= config.bin %>/g, binary).replace(/<%= command.id %>/g, command.id));
50
+ }
45
51
  const state = command.state || commandMeta.state;
46
52
  this.data = Object.assign(command, {
47
- binary: 'sfdx',
53
+ binary,
48
54
  commandWithUnderscores,
55
+ examples,
49
56
  help,
50
57
  description,
51
58
  parameters,
@@ -1 +1 @@
1
- {"version":3,"file":"command.js","sourceRoot":"","sources":["../../src/ditamap/command.ts"],"names":[],"mappings":";AAAA;;;;;GAKG;;;AAEH,+BAA4B;AAC5B,mDAAgH;AAChH,oCAAkE;AAClE,uCAAoC;AAWpC,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I,iBAAS,CAAC,IAAI,CAAC,WAAW,CAAC,CAAC,CAAC;YAC/F,IAAI,CAAC,IAAI,CAAC,eAAe,EAAE;gBACzB,IAAI,CAAC,eAAe,GAAG,iBAAS,CAAC,IAAI,CAAC,WAAW,CAAC,CAAC;aACpD;YACD,OAAO,MAAM,CAAC,MAAM,CAAC,IAAI,EAAE;gBACzB,IAAI,EAAE,QAAQ;gBACd,WAAW;gBACX,QAAQ,EAAE,CAAC,IAAI,CAAC,QAAQ;gBACxB,IAAI,EAAE,IAAI,CAAC,IAAI,IAAI,IAAI,CAAC,IAAI;gBAC5B,QAAQ,EAAE,IAAI,CAAC,IAAI,KAAK,SAAS;aAClC,CAAC,CAAC;QACL,CAAC,CAAC,CAAC;IACP,CAAC;IAEM,mBAAmB;QACxB,OAAO,aAAa,CAAC;IACvB,CAAC;CACF;AAhGD,0BAgGC"}
@@ -1 +1 @@
1
- {"version":"1.3.19","commands":{"commandreference:generate":{"id":"commandreference:generate","description":"generate the command reference guide located","usage":"<%= command.id %> [-d <string>] [-p <array>] [--hidden] [--erroronwarnings] [--json] [--loglevel trace|debug|info|warn|error|fatal|TRACE|DEBUG|INFO|WARN|ERROR|FATAL]","pluginName":"@salesforce/plugin-command-reference","pluginType":"core","aliases":[],"flags":{"json":{"name":"json","type":"boolean","description":"format output as json","allowNo":false},"loglevel":{"name":"loglevel","type":"option","description":"logging level for this command invocation","required":false,"helpValue":"(trace|debug|info|warn|error|fatal|TRACE|DEBUG|INFO|WARN|ERROR|FATAL)","options":["trace","debug","info","warn","error","fatal","TRACE","DEBUG","INFO","WARN","ERROR","FATAL"],"default":"warn"},"outputdir":{"name":"outputdir","type":"option","char":"d","description":"output directory to put generated files","default":"./tmp/root"},"plugins":{"name":"plugins","type":"option","char":"p","description":"comma separated list of plugin names to be part of the generation. Defaults to the oclif plugin in the current working directory"},"hidden":{"name":"hidden","type":"boolean","description":"show hidden commands","allowNo":false},"erroronwarnings":{"name":"erroronwarnings","type":"boolean","description":"fail the command if there are any warnings","allowNo":false}},"args":[{"name":"file"}]}}}
1
+ {"version":"1.3.20","commands":{"commandreference:generate":{"id":"commandreference:generate","description":"generate the command reference guide located","usage":"<%= command.id %> [-d <string>] [-p <array>] [--hidden] [--erroronwarnings] [--json] [--loglevel trace|debug|info|warn|error|fatal|TRACE|DEBUG|INFO|WARN|ERROR|FATAL]","pluginName":"@salesforce/plugin-command-reference","pluginType":"core","aliases":[],"flags":{"json":{"name":"json","type":"boolean","description":"format output as json","allowNo":false},"loglevel":{"name":"loglevel","type":"option","description":"logging level for this command invocation","required":false,"helpValue":"(trace|debug|info|warn|error|fatal|TRACE|DEBUG|INFO|WARN|ERROR|FATAL)","options":["trace","debug","info","warn","error","fatal","TRACE","DEBUG","INFO","WARN","ERROR","FATAL"],"default":"warn"},"outputdir":{"name":"outputdir","type":"option","char":"d","description":"output directory to put generated files","default":"./tmp/root"},"plugins":{"name":"plugins","type":"option","char":"p","description":"comma separated list of plugin names to be part of the generation. Defaults to the oclif plugin in the current working directory"},"hidden":{"name":"hidden","type":"boolean","description":"show hidden commands","allowNo":false},"erroronwarnings":{"name":"erroronwarnings","type":"boolean","description":"fail the command if there are any warnings","allowNo":false}},"args":[{"name":"file"}]}}}
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@salesforce/plugin-command-reference",
3
3
  "description": "Generate the Salesforce CLI command reference guide",
4
- "version": "1.3.19",
4
+ "version": "1.3.20",
5
5
  "author": "Salesforce",
6
6
  "bugs": "https://github.com/forcedotcom/plugin-command-reference/issues",
7
7
  "dependencies": {