@salesforce/plugin-command-reference 2.0.4 → 2.0.8
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 +29 -0
- package/README.md +1 -1
- package/lib/ditamap/ditamap.js +8 -0
- package/lib/ditamap/ditamap.js.map +1 -1
- package/lib/ditamap/help-reference.d.ts +5 -0
- package/lib/ditamap/help-reference.js +24 -0
- package/lib/ditamap/help-reference.js.map +1 -0
- package/lib/docs.js +13 -13
- package/lib/docs.js.map +1 -1
- package/lib/utils.d.ts +0 -1
- package/lib/utils.js +1 -13
- package/lib/utils.js.map +1 -1
- package/oclif.manifest.json +1 -1
- package/package.json +1 -1
- package/templates/base_ditamap.hbs +2 -6
- package/templates/cli_reference_help.hbs +65 -0
- package/templates/cli_reference_topic.hbs +1 -1
- package/templates/cli_reference_topic_commands.hbs +1 -1
- package/templates/cli_reference_xml.hbs +8 -9
- package/templates/command.hbs +5 -4
- package/templates/main_topic_intro.hbs +1 -1
- package/templates/topic_ditamap.hbs +3 -3
- package/templates/cli_reference_help.xml +0 -78
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,35 @@
|
|
|
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
|
+
### [2.0.8](https://github.com/salesforcecli/plugin-command-reference/compare/v2.0.7...v2.0.8) (2021-09-15)
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
### Bug Fixes
|
|
9
|
+
|
|
10
|
+
* update template files for sf ([2a0ca0a](https://github.com/salesforcecli/plugin-command-reference/commit/2a0ca0acc1744b2b090d5c7b3d3a196d127061c9))
|
|
11
|
+
* update test with new title in command XML file ([b9b14ea](https://github.com/salesforcecli/plugin-command-reference/commit/b9b14ea2a8505d153a244ebc0d1e7759e2803a40))
|
|
12
|
+
|
|
13
|
+
### [2.0.7](https://github.com/salesforcecli/plugin-command-reference/compare/v2.0.6...v2.0.7) (2021-09-14)
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
### Bug Fixes
|
|
17
|
+
|
|
18
|
+
* improve error handling ([50a8f5a](https://github.com/salesforcecli/plugin-command-reference/commit/50a8f5a7c92307ac2a0b0d3e72cc98e3e679870d))
|
|
19
|
+
|
|
20
|
+
### [2.0.6](https://github.com/salesforcecli/plugin-command-reference/compare/v2.0.5...v2.0.6) (2021-09-09)
|
|
21
|
+
|
|
22
|
+
|
|
23
|
+
### Bug Fixes
|
|
24
|
+
|
|
25
|
+
* don't generate xml for topics ([60e0056](https://github.com/salesforcecli/plugin-command-reference/commit/60e00563698ce8db4a12077f7866cdbe15fbdf6a))
|
|
26
|
+
|
|
27
|
+
### [2.0.5](https://github.com/salesforcecli/plugin-command-reference/compare/v2.0.4...v2.0.5) (2021-09-08)
|
|
28
|
+
|
|
29
|
+
|
|
30
|
+
### Bug Fixes
|
|
31
|
+
|
|
32
|
+
* use unique id ([56c946e](https://github.com/salesforcecli/plugin-command-reference/commit/56c946eab0dcb8775bd538ddc80e824aee8b7273))
|
|
33
|
+
|
|
5
34
|
### [2.0.4](https://github.com/salesforcecli/plugin-command-reference/compare/v2.0.3...v2.0.4) (2021-09-08)
|
|
6
35
|
|
|
7
36
|
|
package/README.md
CHANGED
|
@@ -93,5 +93,5 @@ OPTIONS
|
|
|
93
93
|
--json Format output as json.
|
|
94
94
|
```
|
|
95
95
|
|
|
96
|
-
_See code: [src/commands/commandreference/generate.ts](https://github.com/salesforcecli/plugin-command-reference/blob/v2.0.
|
|
96
|
+
_See code: [src/commands/commandreference/generate.ts](https://github.com/salesforcecli/plugin-command-reference/blob/v2.0.7/src/commands/commandreference/generate.ts)_
|
|
97
97
|
<!-- commandsstop -->
|
package/lib/ditamap/ditamap.js
CHANGED
|
@@ -14,6 +14,14 @@ const hb = require("handlebars");
|
|
|
14
14
|
const debug = debugCreator('commandreference');
|
|
15
15
|
hb.registerHelper('toUpperCase', (str) => str.toUpperCase());
|
|
16
16
|
hb.registerHelper('join', (array) => array.join(', '));
|
|
17
|
+
hb.registerHelper('xmlFile', (...strings) => {
|
|
18
|
+
const parts = strings.filter((s) => typeof s === 'string');
|
|
19
|
+
return Ditamap.file(parts.join('_'), 'xml');
|
|
20
|
+
});
|
|
21
|
+
hb.registerHelper('uniqueId', (...strings) => {
|
|
22
|
+
const parts = strings.filter((s) => typeof s === 'string');
|
|
23
|
+
return Ditamap.file(parts.join('_'), 'xml').replace('.xml', '');
|
|
24
|
+
});
|
|
17
25
|
/*
|
|
18
26
|
* Returns true if the string should be formatted as code block in docs
|
|
19
27
|
*/
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ditamap.js","sourceRoot":"","sources":["../../src/ditamap/ditamap.ts"],"names":[],"mappings":";AAAA;;;;;GAKG;;;AAEH,+BAAqC;AACrC,2CAAsC;AAEtC,sCAAsC;AACtC,iCAAiC;AAEjC,MAAM,KAAK,GAAG,YAAY,CAAC,kBAAkB,CAAC,CAAC;AAE/C,EAAE,CAAC,cAAc,CAAC,aAAa,EAAE,CAAC,GAAG,EAAE,EAAE,CAAC,GAAG,CAAC,WAAW,EAAE,CAAC,CAAC;AAC7D,EAAE,CAAC,cAAc,CAAC,MAAM,EAAE,CAAC,KAAK,EAAE,EAAE,CAAC,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC;
|
|
1
|
+
{"version":3,"file":"ditamap.js","sourceRoot":"","sources":["../../src/ditamap/ditamap.ts"],"names":[],"mappings":";AAAA;;;;;GAKG;;;AAEH,+BAAqC;AACrC,2CAAsC;AAEtC,sCAAsC;AACtC,iCAAiC;AAEjC,MAAM,KAAK,GAAG,YAAY,CAAC,kBAAkB,CAAC,CAAC;AAE/C,EAAE,CAAC,cAAc,CAAC,aAAa,EAAE,CAAC,GAAG,EAAE,EAAE,CAAC,GAAG,CAAC,WAAW,EAAE,CAAC,CAAC;AAC7D,EAAE,CAAC,cAAc,CAAC,MAAM,EA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AC,YAAqB;QAC9C,OAAO,YAAY,CAAC,CAAC,CAAC,YAAY,CAAC,KAAK,CAAC,IAAI,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,KAAK,EAAE,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC;IAC9E,CAAC;IAED;;;;;;OAMG;IACK,KAAK,CAAC,kBAAkB;QAC9B,KAAK,CAAC,cAAc,IAAI,CAAC,WAAW,SAAS,IAAI,CAAC,mBAAmB,EAAE,EAAE,CAAC,CAAC;QAC3E,MAAM,GAAG,GAAG,MAAM,SAAE,CAAC,QAAQ,CAAC,IAAI,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;QACnD,MAAM,QAAQ,GAAG,EAAE,CAAC,OAAO,CAAC,GAAG,CAAC,CAAC;QACjC,OAAO,QAAQ,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;IAC7B,CAAC;;AAxEH,0BAyEC;AAxEe,cAAM,GAAG,SAAS,CAAC;AAEnB,oBAAY,GAAG,IAAA,WAAI,EAAC,SAAS,EAAE,IAAI,EAAE,IAAI,EAAE,WAAW,CAAC,CAAC"}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/*
|
|
3
|
+
* Copyright (c) 2018, salesforce.com, inc.
|
|
4
|
+
* All rights reserved.
|
|
5
|
+
* Licensed under the BSD 3-Clause license.
|
|
6
|
+
* For full license text, see LICENSE.txt file in the repo root or https://opensource.org/licenses/BSD-3-Clause
|
|
7
|
+
*/
|
|
8
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
9
|
+
exports.HelpReference = void 0;
|
|
10
|
+
const ditamap_1 = require("./ditamap");
|
|
11
|
+
class HelpReference extends ditamap_1.Ditamap {
|
|
12
|
+
constructor() {
|
|
13
|
+
// Set the data of topic and filenames
|
|
14
|
+
const filename = ditamap_1.Ditamap.file('cli_reference_help', 'xml');
|
|
15
|
+
super(filename, {
|
|
16
|
+
id: filename.replace('.xml', ''),
|
|
17
|
+
});
|
|
18
|
+
}
|
|
19
|
+
getTemplateFileName() {
|
|
20
|
+
return 'cli_reference_help.hbs';
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
exports.HelpReference = HelpReference;
|
|
24
|
+
//# sourceMappingURL=help-reference.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"help-reference.js","sourceRoot":"","sources":["../../src/ditamap/help-reference.ts"],"names":[],"mappings":";AAAA;;;;;GAKG;;;AAEH,uCAAoC;AAEpC,MAAa,aAAc,SAAQ,iBAAO;IACxC;QACE,sCAAsC;QACtC,MAAM,QAAQ,GAAG,iBAAO,CAAC,IAAI,CAAC,oBAAoB,EAAE,KAAK,CAAC,CAAC;QAC3D,KAAK,CAAC,QAAQ,EAAE;YACd,EAAE,EAAE,QAAQ,CAAC,OAAO,CAAC,MAAM,EAAE,EAAE,CAAC;SACjC,CAAC,CAAC;IACL,CAAC;IAEM,mBAAmB;QACxB,OAAO,wBAAwB,CAAC;IAClC,CAAC;CACF;AAZD,sCAYC"}
|
package/lib/docs.js
CHANGED
|
@@ -7,19 +7,20 @@
|
|
|
7
7
|
*/
|
|
8
8
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
9
9
|
exports.Docs = void 0;
|
|
10
|
-
const path_1 = require("path");
|
|
11
10
|
const core_1 = require("@salesforce/core");
|
|
12
11
|
const ts_types_1 = require("@salesforce/ts-types");
|
|
13
12
|
const chalk = require("chalk");
|
|
14
13
|
const base_ditamap_1 = require("./ditamap/base-ditamap");
|
|
15
14
|
const cli_reference_1 = require("./ditamap/cli-reference");
|
|
16
|
-
const cli_reference_topic_1 = require("./ditamap/cli-reference-topic");
|
|
17
15
|
const command_1 = require("./ditamap/command");
|
|
18
16
|
const main_topic_intro_1 = require("./ditamap/main-topic-intro");
|
|
19
17
|
const topic_commands_1 = require("./ditamap/topic-commands");
|
|
20
18
|
const topic_ditamap_1 = require("./ditamap/topic-ditamap");
|
|
21
19
|
const utils_1 = require("./utils");
|
|
22
|
-
const
|
|
20
|
+
const help_reference_1 = require("./ditamap/help-reference");
|
|
21
|
+
function emitNoTopicMetadataWarning(topic) {
|
|
22
|
+
utils_1.events.emit('warning', `No metadata for topic ${chalk.bold(topic)}. That topic owner must add topic metadata in the oclif section in the package.json file within their plugin.`);
|
|
23
|
+
}
|
|
23
24
|
class Docs {
|
|
24
25
|
constructor(outputDir, plugins, hidden, topicMeta, cliMeta) {
|
|
25
26
|
this.outputDir = outputDir;
|
|
@@ -37,16 +38,14 @@ class Docs {
|
|
|
37
38
|
const topicMeta = (0, ts_types_1.ensureJsonMap)(this.topicMeta[topic], `No topic meta for ${topic} - add this topic to the oclif section of the package.json.`);
|
|
38
39
|
let description = (0, ts_types_1.asString)(topicMeta.description);
|
|
39
40
|
if (!description && !topicMeta.external) {
|
|
40
|
-
// Punctuate the description in place of longDescription
|
|
41
41
|
description = (0, utils_1.punctuate)((0, ts_types_1.asString)(topicMeta.description));
|
|
42
42
|
if (!description) {
|
|
43
|
-
utils_1.events.emit('warning', `No description for topic ${chalk.bold(topic)}. Skipping until topic owner adds topic metadata
|
|
43
|
+
utils_1.events.emit('warning', `No description for topic ${chalk.bold(topic)}. Skipping until topic owner adds topic metadata in the oclif section in the package.json file within their plugin.`);
|
|
44
44
|
return;
|
|
45
45
|
}
|
|
46
46
|
}
|
|
47
47
|
const subTopicNames = [];
|
|
48
48
|
const commandIds = [];
|
|
49
|
-
// const commandFileNames = [];
|
|
50
49
|
for (const subtopic of Object.keys(subtopics)) {
|
|
51
50
|
const subtopicOrCommand = subtopics[subtopic];
|
|
52
51
|
try {
|
|
@@ -60,8 +59,7 @@ class Docs {
|
|
|
60
59
|
}
|
|
61
60
|
const subTopicsMeta = (0, ts_types_1.ensureJsonMap)(topicMeta.subtopics);
|
|
62
61
|
if (!subTopicsMeta[subtopic]) {
|
|
63
|
-
|
|
64
|
-
utils_1.events.emit('warning', `No metadata for topic ${chalk.bold(fullTopicPath)}. That topic owner must add topic metadata in the oclif section in the package.json file within their plugin.`);
|
|
62
|
+
emitNoTopicMetadataWarning(`${topic}:${subtopic}`);
|
|
65
63
|
continue;
|
|
66
64
|
}
|
|
67
65
|
const subtopicMeta = (0, ts_types_1.ensureJsonMap)(subTopicsMeta[subtopic]);
|
|
@@ -78,14 +76,16 @@ class Docs {
|
|
|
78
76
|
}
|
|
79
77
|
}
|
|
80
78
|
catch (error) {
|
|
81
|
-
|
|
79
|
+
if (error.name === 'UnexpectedValueTypeError') {
|
|
80
|
+
emitNoTopicMetadataWarning(`${topic}:${subtopic}`);
|
|
81
|
+
}
|
|
82
|
+
else {
|
|
83
|
+
utils_1.events.emit('warning', `Can't create topic for ${topic}:${subtopic}: ${error.message}\n`);
|
|
84
|
+
}
|
|
82
85
|
}
|
|
83
86
|
}
|
|
84
87
|
// The topic ditamap with all of the subtopic links.
|
|
85
88
|
utils_1.events.emit('subtopics', topic, subTopicNames);
|
|
86
|
-
if (!commandIds.includes(topic)) {
|
|
87
|
-
await new cli_reference_topic_1.CLIReferenceTopic(topic, description).write();
|
|
88
|
-
}
|
|
89
89
|
await new topic_commands_1.TopicCommands(topic, topicMeta).write();
|
|
90
90
|
await new topic_ditamap_1.TopicDitamap(topic, commandIds).write();
|
|
91
91
|
return subTopicNames;
|
|
@@ -146,7 +146,7 @@ class Docs {
|
|
|
146
146
|
async populateTemplate(commands) {
|
|
147
147
|
const topicsAndSubtopics = this.groupTopicsAndSubtopics(commands);
|
|
148
148
|
await new cli_reference_1.CLIReference().write();
|
|
149
|
-
await
|
|
149
|
+
await new help_reference_1.HelpReference().write();
|
|
150
150
|
const topics = Object.keys(topicsAndSubtopics);
|
|
151
151
|
// Generate one base file with all top-level topics.
|
|
152
152
|
await new base_ditamap_1.BaseDitamap(topics).write();
|
package/lib/docs.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"docs.js","sourceRoot":"","sources":["../src/docs.ts"],"names":[],"mappings":";AAAA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AAS,EAAC,OAAO,CAAC,WAAW,CAAC,CAAC;qBACzF;iBACF;aACF;SACF;QACD,OAAO,WAAW,CAAC;IACrB,CAAC;IAEO,KAAK,CAAC,eAAe,CAAC,KAAa,EAAE,QAAgB,EAAE,OAAmB,EAAE,WAAoB;QACtG,oCAAoC;QACpC,IAAI,OAAO,CAAC,MAAM,IAAI,CAAC,IAAI,CAAC,MAAM,EAAE;YAClC,OAAO,EAAE,CAAC;SACX;QAED,MAAM,cAAc,GAAG,IAAI,iBAAO,CAAC,KAAK,EAAE,QAAQ,EAAE,OAAO,EAAE,WAAW,CAAC,CAAC;QAC1E,MAAM,cAAc,CAAC,KAAK,EAAE,CAAC;QAC7B,OAAO,cAAc,CAAC,WAAW,EAAE,CAAC;IACtC,CAAC;CACF;AAtND,oBAsNC"}
|
package/lib/utils.d.ts
CHANGED
|
@@ -2,7 +2,6 @@
|
|
|
2
2
|
import { EventEmitter } from 'events';
|
|
3
3
|
import { Dictionary } from '@salesforce/ts-types';
|
|
4
4
|
export declare const events: EventEmitter;
|
|
5
|
-
export declare function copyStaticFile(outputDir: string, fileDir: string, fileName: string): Promise<void>;
|
|
6
5
|
export declare function mergeDeep(target: Dictionary, source: Dictionary): Dictionary;
|
|
7
6
|
export declare function punctuate(description: string): string;
|
|
8
7
|
export declare function helpFromDescription(description: string): string;
|
package/lib/utils.js
CHANGED
|
@@ -6,23 +6,11 @@
|
|
|
6
6
|
* For full license text, see LICENSE.txt file in the repo root or https://opensource.org/licenses/BSD-3-Clause
|
|
7
7
|
*/
|
|
8
8
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
9
|
-
exports.helpFromDescription = exports.punctuate = exports.mergeDeep = exports.
|
|
9
|
+
exports.helpFromDescription = exports.punctuate = exports.mergeDeep = exports.events = void 0;
|
|
10
10
|
const events_1 = require("events");
|
|
11
|
-
const fs_1 = require("fs");
|
|
12
11
|
const os_1 = require("os");
|
|
13
|
-
const path_1 = require("path");
|
|
14
12
|
const ts_types_1 = require("@salesforce/ts-types");
|
|
15
|
-
const core_1 = require("@salesforce/core");
|
|
16
|
-
const ditamap_1 = require("./ditamap/ditamap");
|
|
17
13
|
exports.events = new events_1.EventEmitter();
|
|
18
|
-
async function copyStaticFile(outputDir, fileDir, fileName) {
|
|
19
|
-
const source = (0, path_1.join)(fileDir, fileName);
|
|
20
|
-
const [name, ext] = fileName.split('.');
|
|
21
|
-
const dest = (0, path_1.join)(outputDir, ditamap_1.Ditamap.file(name, ext));
|
|
22
|
-
await core_1.fs.mkdirp(outputDir);
|
|
23
|
-
(0, fs_1.copyFileSync)(source, dest);
|
|
24
|
-
}
|
|
25
|
-
exports.copyStaticFile = copyStaticFile;
|
|
26
14
|
function mergeDeep(target, source) {
|
|
27
15
|
Object.keys(source).forEach((key) => {
|
|
28
16
|
if ((0, ts_types_1.isObject)(target[key]) && (0, ts_types_1.isObject)(source[key])) {
|
package/lib/utils.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"utils.js","sourceRoot":"","sources":["../src/utils.ts"],"names":[],"mappings":";AAAA;;;;;GAKG;;;AAEH,mCAAsC;AACtC,
|
|
1
|
+
{"version":3,"file":"utils.js","sourceRoot":"","sources":["../src/utils.ts"],"names":[],"mappings":";AAAA;;;;;GAKG;;;AAEH,mCAAsC;AACtC,2BAAyB;AACzB,mDAA4D;AAE/C,QAAA,MAAM,GAAG,IAAI,qBAAY,EAAE,CAAC;AAEzC,SAAgB,SAAS,CAAC,MAAkB,EAAE,MAAkB;IAC9D,MAAM,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC,OAAO,CAAC,CAAC,GAAG,EAAE,EAAE;QAClC,IAAI,IAAA,mBAAQ,EAAC,MAAM,CAAC,GAAG,CAAC,CAAC,IAAI,IAAA,mBAAQ,EAAC,MAAM,CAAC,GAAG,CAAC,CAAC,EAAE;YAClD,SAAS,CAAC,MAAM,CAAC,GAAG,CAAe,EAAE,MAAM,CAAC,GAAG,CAAe,CAAC,CAAC;SACjE;aAAM;YACL,MAAM,CAAC,GAAG,CAAC,GAAG,MAAM,CAAC,GAAG,CAAC,CAAC;SAC3B;IACH,CAAC,CAAC,CAAC;IACH,OAAO,MAAM,CAAC;AAChB,CAAC;AATD,8BASC;AAED,SAAgB,SAAS,CAAC,WAAmB;IAC3C,IAAI,CAAC,WAAW;QAAE,OAAO,WAAW,CAAC;IAErC,MAAM,KAAK,GAAG,WAAW,CAAC,KAAK,CAAC,QAAG,CAAC,CAAC;IACrC,IAAI,eAAe,GAAG,KAAK,CAAC,CAAC,CAAC,CAAC;IAE/B,eAAe,GAAG,eAAe,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,WAAW,EAAE,GAAG,eAAe,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC;IAEzF,IAAI,eAAe,CAAC,MAAM,CAAC,eAAe,CAAC,MAAM,GAAG,CAAC,CAAC,KAAK,GAAG,EAAE;QAC9D,eAAe,IAAI,GAAG,CAAC;KACxB;IAED,OAAO,eAAe,CAAC;AACzB,CAAC;AAbD,8BAaC;AAED,SAAgB,mBAAmB,CAAC,WAAmB;IACrD,OAAO,WAAW,CAAC,CAAC,CAAC,WAAW,CAAC,KAAK,CAAC,QAAG,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,QAAG,CAAC,CAAC,IAAI,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC;AAC7E,CAAC;AAFD,kDAEC"}
|
package/oclif.manifest.json
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":"2.0.
|
|
1
|
+
{"version":"2.0.8","commands":{"commandreference:generate":{"id":"commandreference:generate","description":"generate the command reference guide located","pluginName":"@salesforce/plugin-command-reference","pluginType":"core","aliases":[],"flags":{"json":{"name":"json","type":"boolean","description":"Format output as json.","allowNo":false},"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"},"ditamap-suffix":{"name":"ditamap-suffix","type":"option","char":"s","description":"unique suffix to append to generated ditamap","default":"unified"},"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":[]}}}
|
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": "2.0.
|
|
4
|
+
"version": "2.0.8",
|
|
5
5
|
"author": "Thomas @amphro",
|
|
6
6
|
"bugs": "https://github.com/salesforcecli/plugin-command-reference/issues",
|
|
7
7
|
"dependencies": {
|
|
@@ -14,14 +14,10 @@ IF YOU WANT TO CHANGE THIS CONTENT, CONTACT juliet.shackell@salesforce.com FOR D
|
|
|
14
14
|
<shortdesc>An alphabetized list of CLI commands that you use with Salesforce DX to create
|
|
15
15
|
and manage applications on the Lightning Platform.</shortdesc>
|
|
16
16
|
</topicmeta>
|
|
17
|
-
<topicref href="cli_reference
|
|
17
|
+
<topicref href="{{xmlFile 'cli_reference'}}" type="reference" format="dita" scope="local">
|
|
18
18
|
{{#each namespaceDitamapFiles}}
|
|
19
19
|
{{#if []}}<topicref href="{{[]}}" format="ditamap" scope="local"/>{{/if}}
|
|
20
20
|
{{/each}}
|
|
21
|
-
<topicref href="cli_reference_help
|
|
22
|
-
<topicref href="../../sfdx_dev/workspace_setup/sfdx_dev_cli_deprecation.xml" type="concept"
|
|
23
|
-
format="dita" scope="local"/>
|
|
24
|
-
<topicref href="../../sfdx_setup/sfdx_setup_other_plugins.xml" type="concept"
|
|
25
|
-
format="dita" scope="local"/>
|
|
21
|
+
<topicref href="{{xmlFile 'cli_reference_help'}}" type="concept" format="dita" scope="local"/>
|
|
26
22
|
</topicref>
|
|
27
23
|
</map>
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
<?xml version="1.0" encoding="UTF-8"?>
|
|
2
|
+
<!DOCTYPE concept PUBLIC "-//OASIS//DTD DITA Concept//EN"
|
|
3
|
+
"concept.dtd">
|
|
4
|
+
<concept id="{{id}}" xml:lang="en-us">
|
|
5
|
+
<!--
|
|
6
|
+
|
|
7
|
+
NOTE TO WRITERS:
|
|
8
|
+
THIS FILE IS AUTOGENERATED. DON’T MAKE CHANGES TO THIS FILE IN PERFORCE! YOUR CHANGES WILL BE OVERWRITTEN.
|
|
9
|
+
IF YOU WANT TO CHANGE THIS CONTENT, CONTACT juliet.shackell@salesforce.com FOR DETAILS.
|
|
10
|
+
|
|
11
|
+
-->
|
|
12
|
+
<title>Help for <codeph otherprops="nolang">sf</codeph> Commands</title>
|
|
13
|
+
<shortdesc>The <codeph otherprops="nolang">-h</codeph> and <codeph otherprops="nolang"
|
|
14
|
+
>--help</codeph> flags show details about <codeph otherprops="nolang">sf</codeph> topics and
|
|
15
|
+
their commands.</shortdesc>
|
|
16
|
+
<prolog>
|
|
17
|
+
<metadata>
|
|
18
|
+
<othermeta content="concept" name="topic_type"/>
|
|
19
|
+
<othermeta content="Developer_Tools" name="app_area"/>
|
|
20
|
+
<othermeta content="Developer Partner" name="role"/>
|
|
21
|
+
<othermeta content="EE UE DE PXE" name="edition"/>
|
|
22
|
+
<othermeta content="aloha mobile sfx" name="ui_platform"/>
|
|
23
|
+
</metadata>
|
|
24
|
+
</prolog>
|
|
25
|
+
<conbody>
|
|
26
|
+
<p>The short <codeph otherprops="nolang">-h</codeph> flag shows a subset of the command-line
|
|
27
|
+
help and is meant for quick reference. The long <codeph otherprops="nolang">--help</codeph>
|
|
28
|
+
flag shows the complete command-line help. </p>
|
|
29
|
+
<p>The short help (<codeph otherprops="nolang">-h</codeph>) for commands has these parts.<ol>
|
|
30
|
+
<li><b>Short Description of Command</b><p>At the top of the <codeph otherprops="nolang"
|
|
31
|
+
>-h</codeph> output (with no heading), a short description of the command is shown.
|
|
32
|
+
</p></li>
|
|
33
|
+
<li><b>Usage</b><p>The command signature on the Usage line uses the docopt format.<ul>
|
|
34
|
+
<li>All available flags are listed. Flags that have short names are listed using their
|
|
35
|
+
short names.</li>
|
|
36
|
+
<li>Flags that take a value show <codeph otherprops="nolang"><value></codeph>
|
|
37
|
+
immediately after the flag’s name.</li>
|
|
38
|
+
<li>Optional flags are in square brackets (<codeph otherprops="nolang">[ …
|
|
39
|
+
]</codeph>).</li>
|
|
40
|
+
<li>Required flags have no annotation.</li>
|
|
41
|
+
<li>For flags that accept a limited set of values, the values are shown after the flag
|
|
42
|
+
name, separated by pipes (<codeph otherprops="nolang">--flagname
|
|
43
|
+
value1|value2|value3</codeph>).</li>
|
|
44
|
+
</ul></p></li>
|
|
45
|
+
<li><b>Flags</b><p>The Flags section lists all the command’s flags, including their short
|
|
46
|
+
name, long name, and purpose. Flags are grouped for easier reading, such as global flags
|
|
47
|
+
and other groups relevant to a specific command. </p><p>For flags that take multiple
|
|
48
|
+
values, you have two ways to specify the values:<ul>
|
|
49
|
+
<li>Specify the flag multiple times, where each flag takes a different single
|
|
50
|
+
value.</li>
|
|
51
|
+
<li>Specify the flag one time, but separate all the values with a space.</li>
|
|
52
|
+
</ul></p><p>For example, the following commands are
|
|
53
|
+
equivalent:<codeblock otherprops="nolang">sf deploy metadata --metadata ApexClass --metadata CustomObject --metadata AnotherCustomObject
|
|
54
|
+
sf deploy metadata --metadata ApexClass CustomObject AnotherCustomObject</codeblock></p><p>Flags
|
|
55
|
+
that accept a limited list of values include the values in parentheses, with the default
|
|
56
|
+
value specified with the <codeph otherprops="nolang">default</codeph> keyword. </p></li>
|
|
57
|
+
</ol></p>
|
|
58
|
+
<p>The long help (<codeph otherprops="nolang">--help</codeph>) for commands has the same parts
|
|
59
|
+
as the preceding short help <codeph otherprops="nolang">-h</codeph>) and these additional parts.<ol>
|
|
60
|
+
<li><b>Description</b><p>Usage notes. </p></li>
|
|
61
|
+
<li><b>Examples</b><p>All examples include a brief description.</p></li>
|
|
62
|
+
<li><b>Flag Descriptions</b><p>Some flags have optional additional usage notes.</p></li>
|
|
63
|
+
</ol></p>
|
|
64
|
+
</conbody>
|
|
65
|
+
</concept>
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
<?xml version="1.0" encoding="UTF-8"?>
|
|
2
2
|
<!DOCTYPE concept PUBLIC "-//OASIS//DTD DITA Concept//EN"
|
|
3
3
|
"concept.dtd">
|
|
4
|
-
<concept id="
|
|
4
|
+
<concept id="{{uniqueId 'cli_reference' topic}}" xml:lang="en-us">
|
|
5
5
|
<!--
|
|
6
6
|
|
|
7
7
|
NOTE TO WRITERS:
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
<?xml version="1.0" encoding="UTF-8"?>
|
|
2
2
|
<!DOCTYPE concept PUBLIC "-//OASIS//DTD DITA Concept//EN"
|
|
3
3
|
"concept.dtd">
|
|
4
|
-
<concept id="
|
|
4
|
+
<concept id="{{uniqueId 'cli_reference' name 'commands'}}" xml:lang="en-us">
|
|
5
5
|
<!--
|
|
6
6
|
|
|
7
7
|
NOTE TO WRITERS:
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
<?xml version="1.0" encoding="UTF-8"?>
|
|
2
2
|
<!DOCTYPE reference PUBLIC "-//OASIS//DTD DITA Reference//EN"
|
|
3
3
|
"reference.dtd">
|
|
4
|
-
<reference id="cli_reference" xml:lang="en-us">
|
|
4
|
+
<reference id="{{uniqueId 'cli_reference'}}" xml:lang="en-us">
|
|
5
5
|
<!--
|
|
6
6
|
|
|
7
7
|
NOTE TO WRITERS:
|
|
@@ -10,9 +10,8 @@ IF YOU WANT TO CHANGE THIS CONTENT, CONTACT juliet.shackell@salesforce.com FOR D
|
|
|
10
10
|
|
|
11
11
|
-->
|
|
12
12
|
<!--This is a static file that should be passed as-is through the autogen process.-->
|
|
13
|
-
<title>
|
|
14
|
-
|
|
15
|
-
their parameters. </shortdesc>
|
|
13
|
+
<title>sf</title>
|
|
14
|
+
<shortdesc>This section contains information about the <codeph otherprops="nolang">sf</codeph> commands and their parameters. </shortdesc>
|
|
16
15
|
<prolog>
|
|
17
16
|
<metadata>
|
|
18
17
|
<othermeta content="reference" name="topic_type"/>
|
|
@@ -24,17 +23,17 @@ IF YOU WANT TO CHANGE THIS CONTENT, CONTACT juliet.shackell@salesforce.com FOR D
|
|
|
24
23
|
</prolog>
|
|
25
24
|
<refbody>
|
|
26
25
|
<section>
|
|
27
|
-
<p>This version of the command reference includes details about version
|
|
28
|
-
{{cliVersion}} of Salesforce CLI and the following plug-in versions:</p>
|
|
26
|
+
<p>This version of the <codeph otherprops="nolang">sf</codeph> command reference includes details about version
|
|
27
|
+
{{cliVersion}} of the <codeph otherprops="nolang">sf</codeph> executable of Salesforce CLI and the following plug-in versions:</p>
|
|
29
28
|
<ul>
|
|
30
29
|
{{#each pluginVersions}}
|
|
31
30
|
<li><codeph otherprops="nolang">{{name}}</codeph> version {{version}}</li>
|
|
32
31
|
{{/each}}
|
|
33
32
|
</ul>
|
|
34
|
-
<p>For information about installing Salesforce CLI, see the <cite><xref
|
|
35
|
-
href="https://developer.salesforce.com/docs/atlas.en-us.sfdx_setup.meta/sfdx_setup/sfdx_setup_install_cli.htm"
|
|
33
|
+
<p>For information about installing Salesforce CLI, see the <cite><xref
|
|
34
|
+
href="https://developer.salesforce.com/docs/atlas.en-us.sfdx_setup.meta/sfdx_setup/sfdx_setup_install_cli.htm"
|
|
36
35
|
type="new-window:HTML" format="html" scope="external">Salesforce CLI Setup Guide</xref></cite>.</p>
|
|
37
|
-
<p>For information about Salesforce CLI changes, see the <cite><xref
|
|
36
|
+
<p>For information about Salesforce CLI changes, see the <cite><xref
|
|
38
37
|
href="https://github.com/forcedotcom/cli/blob/main/releasenotes/README.md"
|
|
39
38
|
type="new-window:HTML" format="html" scope="external">Salesforce CLI Release Notes</xref></cite>.</p>
|
|
40
39
|
</section>
|
package/templates/command.hbs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
<?xml version="1.0" encoding="UTF-8"?>
|
|
2
2
|
<!DOCTYPE reference PUBLIC "-//OASIS//DTD DITA Reference//EN" "reference.dtd">
|
|
3
|
-
<reference id="
|
|
3
|
+
<reference id="{{uniqueId 'cli_reference' commandWithUnderscores}}" xml:lang="en-us">
|
|
4
4
|
<!--
|
|
5
5
|
|
|
6
6
|
NOTE TO WRITERS:
|
|
@@ -39,6 +39,7 @@ IF YOU WANT TO CHANGE THIS CONTENT, CONTACT juliet.shackell@salesforce.com FOR D
|
|
|
39
39
|
format="html" scope="external" type="new-window:HTML">{{trailblazerCommunityName}}</xref> group in the
|
|
40
40
|
Trailblazer Community.</note>
|
|
41
41
|
</section>{{/if}}{{#if isOpenPilotCommand}}
|
|
42
|
+
</section>{{/if}}{{#if isOpenPilotCommand}}
|
|
42
43
|
<section>
|
|
43
44
|
<note>We provide the <codeph otherprops="nolang">{{name}}</codeph> command to selected customers through a pilot program
|
|
44
45
|
that requires agreement to specific terms and conditions. To be nominated to participate
|
|
@@ -58,7 +59,7 @@ IF YOU WANT TO CHANGE THIS CONTENT, CONTACT juliet.shackell@salesforce.com FOR D
|
|
|
58
59
|
</section>{{/if}}
|
|
59
60
|
{{#if help}}
|
|
60
61
|
<section>
|
|
61
|
-
<title><ph>
|
|
62
|
+
<title><ph>Description for <codeph otherprops="nolang">{{name}}</codeph></ph></title>
|
|
62
63
|
{{#each help}}
|
|
63
64
|
{{#isCodeBlock this}}<codeblock otherprops="nolang">{{this}}</codeblock>{{else}}<p>{{this}}</p>{{/isCodeBlock}}
|
|
64
65
|
{{/each}}
|
|
@@ -78,7 +79,7 @@ IF YOU WANT TO CHANGE THIS CONTENT, CONTACT juliet.shackell@salesforce.com FOR D
|
|
|
78
79
|
</section>
|
|
79
80
|
{{/if}}
|
|
80
81
|
<section>
|
|
81
|
-
<title><ph>
|
|
82
|
+
<title><ph>Usage</ph></title>
|
|
82
83
|
<dl>
|
|
83
84
|
<dlentry>
|
|
84
85
|
<dt><codeph otherprops="nolang">{{binary}} {{name}}</codeph></dt>
|
|
@@ -90,7 +91,7 @@ IF YOU WANT TO CHANGE THIS CONTENT, CONTACT juliet.shackell@salesforce.com FOR D
|
|
|
90
91
|
</section>
|
|
91
92
|
{{#if parameters}}
|
|
92
93
|
<section>
|
|
93
|
-
<title><ph>
|
|
94
|
+
<title><ph>Flags</ph></title>
|
|
94
95
|
<dl>
|
|
95
96
|
{{#each parameters}}
|
|
96
97
|
<dlentry>
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
<?xml version="1.0" encoding="UTF-8"?>
|
|
2
2
|
<!DOCTYPE concept PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
|
|
3
|
-
<concept id="
|
|
3
|
+
<concept id="{{uniqueId 'cli_reference' topic}}" xml:lang="en-us">
|
|
4
4
|
<!--
|
|
5
5
|
|
|
6
6
|
NOTE TO WRITERS:
|
|
@@ -8,10 +8,10 @@ THIS FILE IS AUTOGENERATED. DON’T MAKE CHANGES TO THIS FILE IN PERFORCE! YOUR
|
|
|
8
8
|
IF YOU WANT TO CHANGE THIS CONTENT, CONTACT juliet.shackell@salesforce.com FOR DETAILS.
|
|
9
9
|
|
|
10
10
|
-->
|
|
11
|
-
<title><codeph otherprops="nolang">{{topic}}</codeph>
|
|
12
|
-
<topicref href="
|
|
11
|
+
<title><codeph otherprops="nolang">{{topic}}</codeph> Commands</title>
|
|
12
|
+
<topicref href="{{xmlFile 'cli_reference' topic 'commands'}}" type="concept" format="dita" scope="local" chunk="to-content" collection-type="unordered">
|
|
13
13
|
{{#each commands}}
|
|
14
|
-
<topicref href="
|
|
14
|
+
<topicref href="{{xmlFile 'cli_reference' command}}" type="reference" format="dita" scope="local"/>
|
|
15
15
|
{{/each}}
|
|
16
16
|
</topicref>
|
|
17
17
|
</map>
|
|
@@ -1,78 +0,0 @@
|
|
|
1
|
-
<?xml version="1.0" encoding="UTF-8"?>
|
|
2
|
-
<!DOCTYPE concept PUBLIC "-//OASIS//DTD DITA Concept//EN"
|
|
3
|
-
"concept.dtd">
|
|
4
|
-
<concept id="cli_reference_help" xml:lang="en-us">
|
|
5
|
-
<!--
|
|
6
|
-
|
|
7
|
-
NOTE TO WRITERS:
|
|
8
|
-
THIS FILE IS AUTOGENERATED. DON’T MAKE CHANGES TO THIS FILE IN PERFORCE! YOUR CHANGES WILL BE OVERWRITTEN.
|
|
9
|
-
IF YOU WANT TO CHANGE THIS CONTENT, CONTACT juliet.shackell@salesforce.com FOR DETAILS.
|
|
10
|
-
|
|
11
|
-
-->
|
|
12
|
-
<title>Help for Salesforce CLI Commands</title>
|
|
13
|
-
<shortdesc>The <codeph otherprops="nolang">-h</codeph> | <codeph otherprops="nolang"
|
|
14
|
-
>--help</codeph> parameter shows details about Salesforce CLI topics and their
|
|
15
|
-
commands.</shortdesc>
|
|
16
|
-
<prolog>
|
|
17
|
-
<metadata>
|
|
18
|
-
<othermeta content="concept" name="topic_type"/>
|
|
19
|
-
<othermeta content="Developer_Tools" name="app_area"/>
|
|
20
|
-
<othermeta content="Developer Partner" name="role"/>
|
|
21
|
-
<othermeta content="EE UE DE PXE" name="edition"/>
|
|
22
|
-
<othermeta content="aloha mobile sfx" name="ui_platform"/>
|
|
23
|
-
</metadata>
|
|
24
|
-
</prolog>
|
|
25
|
-
<conbody>
|
|
26
|
-
<p>For namespaces, the <codeph otherprops="nolang">-h</codeph> | <codeph otherprops="nolang"
|
|
27
|
-
>--help</codeph> parameter lists all topics in the namespace. For example, to see names and
|
|
28
|
-
descriptions of all topics in the <codeph otherprops="nolang">force</codeph> namespace, run
|
|
29
|
-
<codeph otherprops="nolang">sfdx force -h</codeph>.</p>
|
|
30
|
-
<p>For topics, the <codeph otherprops="nolang">-h</codeph> | <codeph otherprops="nolang"
|
|
31
|
-
>--help</codeph> parameter lists the commands and their descriptions. For example, to see
|
|
32
|
-
all commands in the <codeph otherprops="nolang">org</codeph> topic, run <codeph
|
|
33
|
-
otherprops="nolang">sfdx force:org -h</codeph>.</p>
|
|
34
|
-
<p>For commands, adding the <codeph otherprops="nolang">-h</codeph> | <codeph otherprops="nolang"
|
|
35
|
-
>--help</codeph> parameter shows parameters and usage information. For example, to see help for
|
|
36
|
-
the <codeph otherprops="nolang">org:create</codeph> command, run <codeph otherprops="nolang">sfdx
|
|
37
|
-
force:org:create -h</codeph>.</p>
|
|
38
|
-
<p>Help for commands has four parts.<ol>
|
|
39
|
-
<li><b>Short Description of Command</b><p>At the top of the <codeph otherprops="nolang"
|
|
40
|
-
>--help</codeph> output (with no heading), a short description of the command is
|
|
41
|
-
shown. For longer descriptions, see the <cite>Salesforce CLI Command
|
|
42
|
-
Reference</cite>.</p></li>
|
|
43
|
-
<li><b>Usage</b><p>The command signature on the Usage line uses the docopt format.<ul>
|
|
44
|
-
<li>All available parameters are listed. Parameters that have short names are listed
|
|
45
|
-
using their short names.</li>
|
|
46
|
-
<li>Parameters that take a value show the value’s type (for example, <codeph
|
|
47
|
-
otherprops="nolang"><string></codeph>) in angle brackets immediately after the
|
|
48
|
-
parameter’s name.</li>
|
|
49
|
-
<li>Optional parameters are in square brackets (<codeph otherprops="nolang">[ …
|
|
50
|
-
]</codeph>).</li>
|
|
51
|
-
<li>Required parameters have no annotation.</li>
|
|
52
|
-
<li>For parameters that accept a limited set of values, the values are shown after the
|
|
53
|
-
parameter name, separated by pipes (<codeph otherprops="nolang">--parametername
|
|
54
|
-
value1|value2|value3</codeph>).</li>
|
|
55
|
-
<li>Mutually exclusive options are shown in parentheses, separated by a pipe (<codeph
|
|
56
|
-
otherprops="nolang">( … | … )</codeph>).</li>
|
|
57
|
-
</ul></p><p>If the command takes varargs (name-value pairs that aren’t parameters), the
|
|
58
|
-
usage signature includes <codeph otherprops="nolang">name=value...</codeph>.</p><note
|
|
59
|
-
type="tip">To see all Salesforce CLI commands, run <codeph otherprops="nolang">sfdx
|
|
60
|
-
commands</codeph>.</note></li>
|
|
61
|
-
<li><b>Options</b><p>The Options section lists all the command’s parameters, including their
|
|
62
|
-
short name, long name, and purpose. For parameters that accept a value, the value name
|
|
63
|
-
is written after an equals sign (<codeph otherprops="nolang">=</codeph>). The equals
|
|
64
|
-
sign is optional when you run the command—for example, you could run <codeph
|
|
65
|
-
otherprops="nolang">sfdx force:org:create
|
|
66
|
-
<varname>-f=config/enterprise-scratch-def.json</varname> -a TestOrg1</codeph> or
|
|
67
|
-
<codeph otherprops="nolang">sfdx force:org:create <varname>-f
|
|
68
|
-
config/enterprise-scratch-def.json</varname> -a TestOrg1</codeph> with the same
|
|
69
|
-
results.</p><p>Parameters that accept a limited list of values include the values in
|
|
70
|
-
parentheses, with the default value indicated by an asterisk (<codeph
|
|
71
|
-
otherprops="nolang">*</codeph>).</p><p>For more information about the parameters, see
|
|
72
|
-
the <cite>Salesforce CLI Command Reference</cite>.</p></li>
|
|
73
|
-
<li><b>Description</b><p>Usage notes and examples are below the list of parameters, in the
|
|
74
|
-
Description section. This information is also available in the <cite>Salesforce CLI
|
|
75
|
-
Command Reference</cite>.</p></li>
|
|
76
|
-
</ol></p>
|
|
77
|
-
</conbody>
|
|
78
|
-
</concept>
|