doc-detective-common 3.0.0-dev.1 → 3.0.0-dev.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.
package/package.json
CHANGED
|
@@ -32,8 +32,8 @@
|
|
|
32
32
|
}
|
|
33
33
|
]
|
|
34
34
|
},
|
|
35
|
-
"
|
|
36
|
-
"description": "Path of the
|
|
35
|
+
"output": {
|
|
36
|
+
"description": "Path of the directory in which to store the output of Doc Detective commands. If a file path is specified, Doc Detective attempts to honor the file name specified, but file path behavior is controlled by the configured reporters.",
|
|
37
37
|
"type": "string",
|
|
38
38
|
"default": "."
|
|
39
39
|
},
|
|
@@ -483,8 +483,7 @@
|
|
|
483
483
|
"default": [
|
|
484
484
|
"markdown",
|
|
485
485
|
"asciidoc",
|
|
486
|
-
"html"
|
|
487
|
-
"xml"
|
|
486
|
+
"html"
|
|
488
487
|
],
|
|
489
488
|
"anyOf": [
|
|
490
489
|
{
|
|
@@ -499,8 +498,7 @@
|
|
|
499
498
|
"enum": [
|
|
500
499
|
"markdown",
|
|
501
500
|
"asciidoc",
|
|
502
|
-
"html"
|
|
503
|
-
"xml"
|
|
501
|
+
"html"
|
|
504
502
|
]
|
|
505
503
|
},
|
|
506
504
|
{
|
|
@@ -516,13 +514,13 @@
|
|
|
516
514
|
"type": "string"
|
|
517
515
|
},
|
|
518
516
|
"extends": {
|
|
517
|
+
"$comment": "In development",
|
|
519
518
|
"description": "Base template to extend.",
|
|
520
519
|
"type": "string",
|
|
521
520
|
"enum": [
|
|
522
521
|
"markdown",
|
|
523
522
|
"asciidoc",
|
|
524
|
-
"html"
|
|
525
|
-
"xml"
|
|
523
|
+
"html"
|
|
526
524
|
]
|
|
527
525
|
},
|
|
528
526
|
"extensions": {
|
|
@@ -8749,7 +8747,7 @@
|
|
|
8749
8747
|
{},
|
|
8750
8748
|
{
|
|
8751
8749
|
"input": ".",
|
|
8752
|
-
"
|
|
8750
|
+
"output": ".",
|
|
8753
8751
|
"recursive": true,
|
|
8754
8752
|
"loadVariables": ".env",
|
|
8755
8753
|
"fileTypes": [
|
package/src/schemas/schemas.json
CHANGED
|
@@ -264,8 +264,8 @@
|
|
|
264
264
|
}
|
|
265
265
|
]
|
|
266
266
|
},
|
|
267
|
-
"
|
|
268
|
-
"description": "Path of the
|
|
267
|
+
"output": {
|
|
268
|
+
"description": "Path of the directory in which to store the output of Doc Detective commands. If a file path is specified, Doc Detective attempts to honor the file name specified, but file path behavior is controlled by the configured reporters.",
|
|
269
269
|
"type": "string",
|
|
270
270
|
"default": "."
|
|
271
271
|
},
|
|
@@ -715,8 +715,7 @@
|
|
|
715
715
|
"default": [
|
|
716
716
|
"markdown",
|
|
717
717
|
"asciidoc",
|
|
718
|
-
"html"
|
|
719
|
-
"xml"
|
|
718
|
+
"html"
|
|
720
719
|
],
|
|
721
720
|
"anyOf": [
|
|
722
721
|
{
|
|
@@ -731,8 +730,7 @@
|
|
|
731
730
|
"enum": [
|
|
732
731
|
"markdown",
|
|
733
732
|
"asciidoc",
|
|
734
|
-
"html"
|
|
735
|
-
"xml"
|
|
733
|
+
"html"
|
|
736
734
|
]
|
|
737
735
|
},
|
|
738
736
|
{
|
|
@@ -748,13 +746,13 @@
|
|
|
748
746
|
"type": "string"
|
|
749
747
|
},
|
|
750
748
|
"extends": {
|
|
749
|
+
"$comment": "In development",
|
|
751
750
|
"description": "Base template to extend.",
|
|
752
751
|
"type": "string",
|
|
753
752
|
"enum": [
|
|
754
753
|
"markdown",
|
|
755
754
|
"asciidoc",
|
|
756
|
-
"html"
|
|
757
|
-
"xml"
|
|
755
|
+
"html"
|
|
758
756
|
]
|
|
759
757
|
},
|
|
760
758
|
"extensions": {
|
|
@@ -8981,7 +8979,7 @@
|
|
|
8981
8979
|
{},
|
|
8982
8980
|
{
|
|
8983
8981
|
"input": ".",
|
|
8984
|
-
"
|
|
8982
|
+
"output": ".",
|
|
8985
8983
|
"recursive": true,
|
|
8986
8984
|
"loadVariables": ".env",
|
|
8987
8985
|
"fileTypes": [
|
|
@@ -21,8 +21,8 @@
|
|
|
21
21
|
}
|
|
22
22
|
]
|
|
23
23
|
},
|
|
24
|
-
"
|
|
25
|
-
"description": "Path of the
|
|
24
|
+
"output": {
|
|
25
|
+
"description": "Path of the directory in which to store the output of Doc Detective commands. If a file path is specified, Doc Detective attempts to honor the file name specified, but file path behavior is controlled by the configured reporters.",
|
|
26
26
|
"type": "string",
|
|
27
27
|
"default": "."
|
|
28
28
|
},
|
|
@@ -98,7 +98,7 @@
|
|
|
98
98
|
},
|
|
99
99
|
"fileTypes": {
|
|
100
100
|
"description": "Configuration for file types and their markup detection.",
|
|
101
|
-
"default": ["markdown", "asciidoc", "html"
|
|
101
|
+
"default": ["markdown", "asciidoc", "html"],
|
|
102
102
|
"anyOf": [
|
|
103
103
|
{
|
|
104
104
|
"type": "array",
|
|
@@ -109,7 +109,7 @@
|
|
|
109
109
|
"$comment": "Simple mode: Reference predefined templates by name.",
|
|
110
110
|
"title": "Predefined",
|
|
111
111
|
"type": "string",
|
|
112
|
-
"enum": ["markdown", "asciidoc", "html"
|
|
112
|
+
"enum": ["markdown", "asciidoc", "html"]
|
|
113
113
|
},
|
|
114
114
|
{
|
|
115
115
|
"$comment": "Custom mode: Extend predefined templates or write whole new ones.",
|
|
@@ -122,9 +122,10 @@
|
|
|
122
122
|
"type": "string"
|
|
123
123
|
},
|
|
124
124
|
"extends": {
|
|
125
|
+
"$comment": "In development",
|
|
125
126
|
"description": "Base template to extend.",
|
|
126
127
|
"type": "string",
|
|
127
|
-
"enum": ["markdown", "asciidoc", "html"
|
|
128
|
+
"enum": ["markdown", "asciidoc", "html"]
|
|
128
129
|
},
|
|
129
130
|
"extensions": {
|
|
130
131
|
"description": "File extensions to use with type.",
|
|
@@ -332,7 +333,7 @@
|
|
|
332
333
|
{},
|
|
333
334
|
{
|
|
334
335
|
"input": ".",
|
|
335
|
-
"
|
|
336
|
+
"output": ".",
|
|
336
337
|
"recursive": true,
|
|
337
338
|
"loadVariables": ".env",
|
|
338
339
|
"fileTypes": ["markdown"]
|
package/src/validate.js
CHANGED
|
@@ -321,7 +321,7 @@ function transformToSchemaKey({
|
|
|
321
321
|
const transformedObject = {
|
|
322
322
|
loadVariables: object.envVariables,
|
|
323
323
|
input: object?.runTests?.input || object.input,
|
|
324
|
-
|
|
324
|
+
output: object?.runTests?.output || object.output,
|
|
325
325
|
recursive: object?.runTests?.recursive || object.recursive,
|
|
326
326
|
relativePathBase: object.relativePathBase,
|
|
327
327
|
detectSteps: object?.runTests?.detectSteps,
|
|
@@ -340,15 +340,17 @@ function transformToSchemaKey({
|
|
|
340
340
|
})
|
|
341
341
|
);
|
|
342
342
|
// Handle openApi transformation
|
|
343
|
-
if (object?.integrations?.openApi)
|
|
344
|
-
|
|
345
|
-
(
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
|
|
343
|
+
if (object?.integrations?.openApi) {
|
|
344
|
+
transformedObject.integrations = {};
|
|
345
|
+
transformedObject.integrations.openApi = object.integrations.openApi.map(
|
|
346
|
+
(description) =>
|
|
347
|
+
transformToSchemaKey({
|
|
348
|
+
currentSchema: "openApi_v2",
|
|
349
|
+
targetSchema: "openApi_v3",
|
|
350
|
+
object: description,
|
|
351
|
+
})
|
|
352
|
+
);
|
|
353
|
+
}
|
|
352
354
|
// Handle fileTypes transformation
|
|
353
355
|
if (object?.fileTypes)
|
|
354
356
|
transformedObject.fileTypes = object.fileTypes.map((fileType) => {
|
|
@@ -389,7 +391,7 @@ function transformToSchemaKey({
|
|
|
389
391
|
const transformedAction = transformToSchemaKey({
|
|
390
392
|
currentSchema: `${action.action}_v2`,
|
|
391
393
|
targetSchema: "step_v3",
|
|
392
|
-
object:
|
|
394
|
+
object: action,
|
|
393
395
|
});
|
|
394
396
|
return transformedAction;
|
|
395
397
|
}
|