@cparra/apexdocs 3.8.0 → 3.10.0
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/README.md +12 -9
- package/dist/cli/generate.js +22 -1
- package/dist/index.d.ts +5 -2
- package/dist/index.js +1 -1
- package/dist/{logger-B0wNVQij.js → logger-D2kLvcfb.js} +606 -334
- package/package.json +40 -8
package/README.md
CHANGED
|
@@ -115,13 +115,15 @@ apexdocs changelog --previousVersionDir force-app-previous --currentVersionDir f
|
|
|
115
115
|
|----------------------------|-------|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|------------------|----------|
|
|
116
116
|
| `--sourceDir` | `-s` | The directory where the source files are located. | N/A | Yes |
|
|
117
117
|
| `--targetDir` | `-t` | The directory where the generated files will be placed. | `docs` | No |
|
|
118
|
-
| `--scope` | `-p` | A list of scopes to document. Values should be separated by a space, e.g --scope global public namespaceaccessible. | `global`
|
|
118
|
+
| `--scope` | `-p` | A list of scopes to document. Values should be separated by a space, e.g --scope global public namespaceaccessible. | `[global]` | No |
|
|
119
|
+
| `--customObjectVisibility` | `-v` | Controls which custom objects are documented. Values should be separated by a space. | `[public]` | No |
|
|
119
120
|
| `--defaultGroupName` | N/A | The default group name to use when a group is not specified. | `Miscellaneous` | No |
|
|
120
121
|
| `--namespace` | N/A | The package namespace, if any. If provided, it will be added to the generated files. | N/A | No |
|
|
121
122
|
| `--sortAlphabetically` | N/A | Sorts files appearing in the Reference Guide alphabetically, as well as the members of a class, interface or enum alphabetically. If false, the members will be displayed in the same order as the code. | `false` | No |
|
|
122
123
|
| `--includeMetadata ` | N/A | Whether to include the file's meta.xml information: Whether it is active and and the API version | `false` | No |
|
|
123
124
|
| `--linkingStrategy` | N/A | The strategy to use when linking to other classes. Possible values are `relative`, `no-link`, and `none` | `relative` | No |
|
|
124
125
|
| `--customObjectsGroupName` | N/A | The name under which custom objects will be grouped in the Reference Guide | `Custom Objects` | No |
|
|
126
|
+
| `--triggersGroupName` | N/A | The name under which triggers will be grouped in the Reference Guide | `Triggers` | No |
|
|
125
127
|
|
|
126
128
|
##### Linking Strategy
|
|
127
129
|
|
|
@@ -184,14 +186,15 @@ apexdocs openapi -s force-app -t docs -n MyNamespace --title "My Custom OpenApi
|
|
|
184
186
|
|
|
185
187
|
#### Flags
|
|
186
188
|
|
|
187
|
-
| Flag
|
|
188
|
-
|
|
189
|
-
| `--previousVersionDir`
|
|
190
|
-
| `--currentVersionDir`
|
|
191
|
-
| `--targetDir`
|
|
192
|
-
| `--fileName`
|
|
193
|
-
| `--scope`
|
|
194
|
-
| `--
|
|
189
|
+
| Flag | Alias | Description | Default | Required |
|
|
190
|
+
|----------------------------|-------|--------------------------------------------------------------------------------------|-------------|----------|
|
|
191
|
+
| `--previousVersionDir` | `-p` | The directory location of the previous version of the source code. | N/A | Yes |
|
|
192
|
+
| `--currentVersionDir` | `-t` | The directory location of the current version of the source code. | N/A | Yes |
|
|
193
|
+
| `--targetDir` | `-t` | The directory location where the changelog file will be generated. | `./docs/` | No |
|
|
194
|
+
| `--fileName` | N/A | The name of the changelog file to be generated. | `changelog` | No |
|
|
195
|
+
| `--scope` | N/A | The list of scope to respect when generating the changelog. | ['global'] | No |
|
|
196
|
+
| `--customObjectVisibility` | `-v` | Controls which custom objects are documented. Values should be separated by a space. | ['public'] | No |
|
|
197
|
+
| `--skipIfNoChanges` | N/A | Whether to skip generating the changelog if there are no changes. | `true` | No |
|
|
195
198
|
|
|
196
199
|
#### Sample Usage
|
|
197
200
|
|
package/dist/cli/generate.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
'use strict';
|
|
3
3
|
|
|
4
|
-
var logger$1 = require('../logger-
|
|
4
|
+
var logger$1 = require('../logger-D2kLvcfb.js');
|
|
5
5
|
var module$1 = require('module');
|
|
6
6
|
var cosmiconfig = require('cosmiconfig');
|
|
7
7
|
var E = require('fp-ts/Either');
|
|
@@ -70,6 +70,14 @@ const markdownOptions = {
|
|
|
70
70
|
default: logger$1.markdownDefaults.scope,
|
|
71
71
|
describe: "A list of scopes to document. Values should be separated by a space, e.g --scope global public namespaceaccessible. Annotations are supported and should be passed lowercased and without the @ symbol, e.g. namespaceaccessible auraenabled."
|
|
72
72
|
},
|
|
73
|
+
customObjectVisibility: {
|
|
74
|
+
type: "string",
|
|
75
|
+
array: true,
|
|
76
|
+
alias: "v",
|
|
77
|
+
default: logger$1.markdownDefaults.customObjectVisibility,
|
|
78
|
+
choices: ["public", "protected", "packageprotected"],
|
|
79
|
+
describe: "Controls which custom objects are documented. Values should be separated by a space."
|
|
80
|
+
},
|
|
73
81
|
defaultGroupName: {
|
|
74
82
|
type: "string",
|
|
75
83
|
default: logger$1.markdownDefaults.defaultGroupName,
|
|
@@ -80,6 +88,11 @@ const markdownOptions = {
|
|
|
80
88
|
default: logger$1.markdownDefaults.customObjectsGroupName,
|
|
81
89
|
describe: "The name under which custom objects will be grouped in the Reference Guide"
|
|
82
90
|
},
|
|
91
|
+
triggersGroupName: {
|
|
92
|
+
type: "string",
|
|
93
|
+
default: logger$1.markdownDefaults.triggersGroupName,
|
|
94
|
+
describe: "The name under which triggers will be grouped in the Reference Guide"
|
|
95
|
+
},
|
|
83
96
|
namespace: {
|
|
84
97
|
type: "string",
|
|
85
98
|
describe: "The package namespace, if any. If provided, it will be added to the generated files."
|
|
@@ -172,6 +185,14 @@ const changeLogOptions = {
|
|
|
172
185
|
default: logger$1.changeLogDefaults.scope,
|
|
173
186
|
describe: "The list of scope to respect when generating the changelog. Values should be separated by a space, e.g --scope global public namespaceaccessible. Annotations are supported and should be passed lowercased and without the @ symbol, e.g. namespaceaccessible auraenabled."
|
|
174
187
|
},
|
|
188
|
+
customObjectVisibility: {
|
|
189
|
+
type: "string",
|
|
190
|
+
array: true,
|
|
191
|
+
alias: "v",
|
|
192
|
+
default: logger$1.changeLogDefaults.customObjectVisibility,
|
|
193
|
+
choices: ["public", "protected", "packageprotected"],
|
|
194
|
+
describe: "Controls which custom objects are documented. Values should be separated by a space."
|
|
195
|
+
},
|
|
175
196
|
skipIfNoChanges: {
|
|
176
197
|
type: "boolean",
|
|
177
198
|
default: logger$1.changeLogDefaults.skipIfNoChanges,
|
package/dist/index.d.ts
CHANGED
|
@@ -15,9 +15,11 @@ type CliConfigurableMarkdownConfig = {
|
|
|
15
15
|
sourceDir: string;
|
|
16
16
|
targetDir: string;
|
|
17
17
|
scope: string[];
|
|
18
|
+
customObjectVisibility: string[];
|
|
18
19
|
namespace?: string;
|
|
19
20
|
defaultGroupName: string;
|
|
20
21
|
customObjectsGroupName: string;
|
|
22
|
+
triggersGroupName: string;
|
|
21
23
|
sortAlphabetically: boolean;
|
|
22
24
|
includeMetadata: boolean;
|
|
23
25
|
linkingStrategy: LinkingStrategy;
|
|
@@ -49,13 +51,14 @@ type UserDefinedChangelogConfig = {
|
|
|
49
51
|
targetDir: string;
|
|
50
52
|
fileName: string;
|
|
51
53
|
scope: string[];
|
|
54
|
+
customObjectVisibility: string[];
|
|
52
55
|
exclude: string[];
|
|
53
56
|
skipIfNoChanges: boolean;
|
|
54
57
|
} & Partial<ChangelogConfigurableHooks>;
|
|
55
58
|
|
|
56
59
|
type UserDefinedConfig = UserDefinedMarkdownConfig | UserDefinedOpenApiConfig | UserDefinedChangelogConfig;
|
|
57
60
|
|
|
58
|
-
type MetadataTypes = 'interface' | 'class' | 'enum' | 'customobject' | 'customfield' | 'custommetadata';
|
|
61
|
+
type MetadataTypes = 'interface' | 'class' | 'enum' | 'customobject' | 'customfield' | 'custommetadata' | 'trigger';
|
|
59
62
|
|
|
60
63
|
type SourceFileMetadata = {
|
|
61
64
|
filePath: string;
|
|
@@ -102,7 +105,7 @@ type DocPageData = {
|
|
|
102
105
|
outputDocPath: string;
|
|
103
106
|
frontmatter: Frontmatter;
|
|
104
107
|
content: string;
|
|
105
|
-
type: 'class' | 'interface' | 'enum' | 'customobject';
|
|
108
|
+
type: 'class' | 'interface' | 'enum' | 'customobject' | 'trigger';
|
|
106
109
|
};
|
|
107
110
|
|
|
108
111
|
type FileChange = {
|