@code-pushup/models 0.77.0 → 0.79.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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@code-pushup/models",
3
- "version": "0.77.0",
3
+ "version": "0.79.0",
4
4
  "license": "MIT",
5
5
  "description": "Model definitions and validators for the Code PushUp CLI",
6
6
  "homepage": "https://github.com/code-pushup/cli/tree/main/packages/models#readme",
@@ -34,7 +34,7 @@
34
34
  "src",
35
35
  "!**/*.tsbuildinfo"
36
36
  ],
37
+ "types": "./src/index.d.ts",
37
38
  "module": "./src/index.js",
38
- "main": "./src/index.js",
39
- "types": "./src/index.d.ts"
39
+ "main": "./src/index.js"
40
40
  }
package/src/index.d.ts CHANGED
@@ -9,16 +9,16 @@ export { artifactGenerationCommandSchema, pluginArtifactOptionsSchema, type Plug
9
9
  export { coreConfigSchema, type CoreConfig } from './lib/core-config.js';
10
10
  export { groupRefSchema, groupSchema, type Group, type GroupMeta, type GroupRef, } from './lib/group.js';
11
11
  export { CONFIG_FILE_NAME, SUPPORTED_CONFIG_FILE_FORMATS, } from './lib/implementation/configuration.js';
12
- export { DEFAULT_PERSIST_CONFIG, DEFAULT_PERSIST_FILENAME, DEFAULT_PERSIST_FORMAT, DEFAULT_PERSIST_OUTPUT_DIR, } from './lib/implementation/constants.js';
12
+ export { DEFAULT_PERSIST_CONFIG, DEFAULT_PERSIST_FILENAME, DEFAULT_PERSIST_FORMAT, DEFAULT_PERSIST_OUTPUT_DIR, DEFAULT_PERSIST_SKIP_REPORT, } from './lib/implementation/constants.js';
13
13
  export { MAX_DESCRIPTION_LENGTH, MAX_ISSUE_MESSAGE_LENGTH, MAX_SLUG_LENGTH, MAX_TITLE_LENGTH, } from './lib/implementation/limits.js';
14
14
  export { fileNameSchema, filePathSchema, globPathSchema, materialIconSchema, scoreSchema, slugSchema, type MaterialIcon, } from './lib/implementation/schemas.js';
15
15
  export { exists } from './lib/implementation/utils.js';
16
16
  export { issueSchema, issueSeveritySchema, type Issue, type IssueSeverity, } from './lib/issue.js';
17
17
  export { formatSchema, persistConfigSchema, type Format, type PersistConfig, } from './lib/persist-config.js';
18
- export { pluginConfigSchema, pluginContextSchema, pluginMetaSchema, type PluginConfig, type PluginContext, type PluginMeta, type PluginScoreTargets, } from './lib/plugin-config.js';
18
+ export { pluginConfigSchema, pluginContextSchema, pluginMetaSchema, pluginScoreTargetsSchema, type PluginConfig, type PluginContext, type PluginMeta, type PluginScoreTargets, } from './lib/plugin-config.js';
19
19
  export { auditReportSchema, pluginReportSchema, reportSchema, type AuditReport, type PluginReport, type Report, } from './lib/report.js';
20
20
  export { auditDiffSchema, auditResultSchema, categoryDiffSchema, categoryResultSchema, groupDiffSchema, groupResultSchema, reportsDiffSchema, type AuditDiff, type AuditResult, type CategoryDiff, type CategoryResult, type GroupDiff, type GroupResult, type ReportsDiff, } from './lib/reports-diff.js';
21
- export { runnerConfigSchema, runnerFilesPathsSchema, runnerFunctionSchema, type RunnerConfig, type RunnerFilesPaths, type RunnerFunction, } from './lib/runner-config.js';
21
+ export { runnerArgsSchema, runnerConfigSchema, runnerFilesPathsSchema, runnerFunctionSchema, type RunnerArgs, type RunnerConfig, type RunnerFilesPaths, type RunnerFunction, } from './lib/runner-config.js';
22
22
  export { tableAlignmentSchema, tableColumnObjectSchema, tableColumnPrimitiveSchema, tableRowObjectSchema, tableRowPrimitiveSchema, tableSchema, type Table, type TableAlignment, type TableColumnObject, type TableColumnPrimitive, type TableRowObject, type TableRowPrimitive, } from './lib/table.js';
23
23
  export { basicTreeNodeSchema, basicTreeSchema, coverageTreeMissingLOCSchema, coverageTreeNodeSchema, coverageTreeSchema, treeSchema, type BasicTree, type BasicTreeNode, type CoverageTree, type CoverageTreeMissingLOC, type CoverageTreeNode, type Tree, } from './lib/tree.js';
24
24
  export { uploadConfigSchema, type UploadConfig } from './lib/upload-config.js';
package/src/index.js CHANGED
@@ -9,16 +9,16 @@ export { artifactGenerationCommandSchema, pluginArtifactOptionsSchema, } from '.
9
9
  export { coreConfigSchema } from './lib/core-config.js';
10
10
  export { groupRefSchema, groupSchema, } from './lib/group.js';
11
11
  export { CONFIG_FILE_NAME, SUPPORTED_CONFIG_FILE_FORMATS, } from './lib/implementation/configuration.js';
12
- export { DEFAULT_PERSIST_CONFIG, DEFAULT_PERSIST_FILENAME, DEFAULT_PERSIST_FORMAT, DEFAULT_PERSIST_OUTPUT_DIR, } from './lib/implementation/constants.js';
12
+ export { DEFAULT_PERSIST_CONFIG, DEFAULT_PERSIST_FILENAME, DEFAULT_PERSIST_FORMAT, DEFAULT_PERSIST_OUTPUT_DIR, DEFAULT_PERSIST_SKIP_REPORT, } from './lib/implementation/constants.js';
13
13
  export { MAX_DESCRIPTION_LENGTH, MAX_ISSUE_MESSAGE_LENGTH, MAX_SLUG_LENGTH, MAX_TITLE_LENGTH, } from './lib/implementation/limits.js';
14
14
  export { fileNameSchema, filePathSchema, globPathSchema, materialIconSchema, scoreSchema, slugSchema, } from './lib/implementation/schemas.js';
15
15
  export { exists } from './lib/implementation/utils.js';
16
16
  export { issueSchema, issueSeveritySchema, } from './lib/issue.js';
17
17
  export { formatSchema, persistConfigSchema, } from './lib/persist-config.js';
18
- export { pluginConfigSchema, pluginContextSchema, pluginMetaSchema, } from './lib/plugin-config.js';
18
+ export { pluginConfigSchema, pluginContextSchema, pluginMetaSchema, pluginScoreTargetsSchema, } from './lib/plugin-config.js';
19
19
  export { auditReportSchema, pluginReportSchema, reportSchema, } from './lib/report.js';
20
20
  export { auditDiffSchema, auditResultSchema, categoryDiffSchema, categoryResultSchema, groupDiffSchema, groupResultSchema, reportsDiffSchema, } from './lib/reports-diff.js';
21
- export { runnerConfigSchema, runnerFilesPathsSchema, runnerFunctionSchema, } from './lib/runner-config.js';
21
+ export { runnerArgsSchema, runnerConfigSchema, runnerFilesPathsSchema, runnerFunctionSchema, } from './lib/runner-config.js';
22
22
  export { tableAlignmentSchema, tableColumnObjectSchema, tableColumnPrimitiveSchema, tableRowObjectSchema, tableRowPrimitiveSchema, tableSchema, } from './lib/table.js';
23
23
  export { basicTreeNodeSchema, basicTreeSchema, coverageTreeMissingLOCSchema, coverageTreeNodeSchema, coverageTreeSchema, treeSchema, } from './lib/tree.js';
24
24
  export { uploadConfigSchema } from './lib/upload-config.js';
package/src/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,oBAAoB,GAErB,MAAM,iCAAiC,CAAC;AACzC,OAAO,EACL,wBAAwB,GAEzB,MAAM,iBAAiB,CAAC;AAEzB,OAAO,EACL,kBAAkB,EAClB,iBAAiB,EACjB,kBAAkB,GAInB,MAAM,uBAAuB,CAAC;AAC/B,OAAO,EAAE,WAAW,EAAc,MAAM,gBAAgB,CAAC;AACzD,OAAO,EACL,uBAAuB,EACvB,iBAAiB,EACjB,0BAA0B,GAI3B,MAAM,uBAAuB,CAAC;AAC/B,OAAO,EACL,oBAAoB,EACpB,iBAAiB,GAGlB,MAAM,0BAA0B,CAAC;AAClC,OAAO,EAAE,YAAY,EAAe,MAAM,iBAAiB,CAAC;AAC5D,OAAO,EACL,+BAA+B,EAC/B,2BAA2B,GAE5B,MAAM,wBAAwB,CAAC;AAChC,OAAO,EAAE,gBAAgB,EAAmB,MAAM,sBAAsB,CAAC;AACzE,OAAO,EACL,cAAc,EACd,WAAW,GAIZ,MAAM,gBAAgB,CAAC;AACxB,OAAO,EACL,gBAAgB,EAChB,6BAA6B,GAC9B,MAAM,uCAAuC,CAAC;AAC/C,OAAO,EACL,sBAAsB,EACtB,wBAAwB,EACxB,sBAAsB,EACtB,0BAA0B,GAC3B,MAAM,mCAAmC,CAAC;AAC3C,OAAO,EACL,sBAAsB,EACtB,wBAAwB,EACxB,eAAe,EACf,gBAAgB,GACjB,MAAM,gCAAgC,CAAC;AACxC,OAAO,EACL,cAAc,EACd,cAAc,EACd,cAAc,EACd,kBAAkB,EAClB,WAAW,EACX,UAAU,GAEX,MAAM,iCAAiC,CAAC;AACzC,OAAO,EAAE,MAAM,EAAE,MAAM,+BAA+B,CAAC;AACvD,OAAO,EACL,WAAW,EACX,mBAAmB,GAGpB,MAAM,gBAAgB,CAAC;AACxB,OAAO,EACL,YAAY,EACZ,mBAAmB,GAGpB,MAAM,yBAAyB,CAAC;AACjC,OAAO,EACL,kBAAkB,EAClB,mBAAmB,EACnB,gBAAgB,GAKjB,MAAM,wBAAwB,CAAC;AAChC,OAAO,EACL,iBAAiB,EACjB,kBAAkB,EAClB,YAAY,GAIb,MAAM,iBAAiB,CAAC;AACzB,OAAO,EACL,eAAe,EACf,iBAAiB,EACjB,kBAAkB,EAClB,oBAAoB,EACpB,eAAe,EACf,iBAAiB,EACjB,iBAAiB,GAQlB,MAAM,uBAAuB,CAAC;AAC/B,OAAO,EACL,kBAAkB,EAClB,sBAAsB,EACtB,oBAAoB,GAIrB,MAAM,wBAAwB,CAAC;AAChC,OAAO,EACL,oBAAoB,EACpB,uBAAuB,EACvB,0BAA0B,EAC1B,oBAAoB,EACpB,uBAAuB,EACvB,WAAW,GAOZ,MAAM,gBAAgB,CAAC;AACxB,OAAO,EACL,mBAAmB,EACnB,eAAe,EACf,4BAA4B,EAC5B,sBAAsB,EACtB,kBAAkB,EAClB,UAAU,GAOX,MAAM,eAAe,CAAC;AACvB,OAAO,EAAE,kBAAkB,EAAqB,MAAM,wBAAwB,CAAC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,oBAAoB,GAErB,MAAM,iCAAiC,CAAC;AACzC,OAAO,EACL,wBAAwB,GAEzB,MAAM,iBAAiB,CAAC;AAEzB,OAAO,EACL,kBAAkB,EAClB,iBAAiB,EACjB,kBAAkB,GAInB,MAAM,uBAAuB,CAAC;AAC/B,OAAO,EAAE,WAAW,EAAc,MAAM,gBAAgB,CAAC;AACzD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,uBAAuB,CAAC;AAC/B,OAAO,EACL,gBAAgB,EAChB,kBAAkB,EAClB,sBAAsB,EACtB,oBAAoB,GAKrB,MAAM,wBAAwB,CAAC;AAChC,OAAO,EACL,oBAAoB,EACpB,uBAAuB,EACvB,0BAA0B,EAC1B,oBAAoB,EACpB,uBAAuB,EACvB,WAAW,GAOZ,MAAM,gBAAgB,CAAC;AACxB,OAAO,EACL,mBAAmB,EACnB,eAAe,EACf,4BAA4B,EAC5B,sBAAsB,EACtB,kBAAkB,EAClB,UAAU,GAOX,MAAM,eAAe,CAAC;AACvB,OAAO,EAAE,kBAAkB,EAAqB,MAAM,wBAAwB,CAAC"}
@@ -993,13 +993,15 @@ export declare const unrefinedCoreConfigSchema: z.ZodObject<{
993
993
  }, z.core.$strip>>>]>>, unknown>>>;
994
994
  configFile: z.ZodOptional<z.ZodString>;
995
995
  }, z.core.$strip>, z.ZodPipe<z.ZodCustom<unknown, unknown>, z.ZodTransform<z.core.$InferInnerFunctionTypeAsync<z.core.$ZodTuple<[z.ZodObject<{
996
- outputDir: z.ZodOptional<z.ZodString>;
997
- filename: z.ZodOptional<z.ZodString>;
998
- format: z.ZodOptional<z.ZodArray<z.ZodEnum<{
999
- json: "json";
1000
- md: "md";
1001
- }>>>;
1002
- skipReports: z.ZodOptional<z.ZodBoolean>;
996
+ persist: z.ZodObject<{
997
+ outputDir: z.ZodNonOptional<z.ZodOptional<z.ZodString>>;
998
+ filename: z.ZodNonOptional<z.ZodOptional<z.ZodString>>;
999
+ format: z.ZodNonOptional<z.ZodOptional<z.ZodArray<z.ZodEnum<{
1000
+ json: "json";
1001
+ md: "md";
1002
+ }>>>>;
1003
+ skipReports: z.ZodNonOptional<z.ZodOptional<z.ZodBoolean>>;
1004
+ }, z.core.$strip>;
1003
1005
  }, z.core.$strip>], null>, z.ZodUnion<readonly [z.ZodArray<z.ZodObject<{
1004
1006
  slug: z.ZodString;
1005
1007
  displayValue: z.ZodOptional<z.ZodString>;
@@ -2168,13 +2170,15 @@ export declare const coreConfigSchema: z.ZodObject<{
2168
2170
  }, z.core.$strip>>>]>>, unknown>>>;
2169
2171
  configFile: z.ZodOptional<z.ZodString>;
2170
2172
  }, z.core.$strip>, z.ZodPipe<z.ZodCustom<unknown, unknown>, z.ZodTransform<z.core.$InferInnerFunctionTypeAsync<z.core.$ZodTuple<[z.ZodObject<{
2171
- outputDir: z.ZodOptional<z.ZodString>;
2172
- filename: z.ZodOptional<z.ZodString>;
2173
- format: z.ZodOptional<z.ZodArray<z.ZodEnum<{
2174
- json: "json";
2175
- md: "md";
2176
- }>>>;
2177
- skipReports: z.ZodOptional<z.ZodBoolean>;
2173
+ persist: z.ZodObject<{
2174
+ outputDir: z.ZodNonOptional<z.ZodOptional<z.ZodString>>;
2175
+ filename: z.ZodNonOptional<z.ZodOptional<z.ZodString>>;
2176
+ format: z.ZodNonOptional<z.ZodOptional<z.ZodArray<z.ZodEnum<{
2177
+ json: "json";
2178
+ md: "md";
2179
+ }>>>>;
2180
+ skipReports: z.ZodNonOptional<z.ZodOptional<z.ZodBoolean>>;
2181
+ }, z.core.$strip>;
2178
2182
  }, z.core.$strip>], null>, z.ZodUnion<readonly [z.ZodArray<z.ZodObject<{
2179
2183
  slug: z.ZodString;
2180
2184
  displayValue: z.ZodOptional<z.ZodString>;
@@ -3348,13 +3352,15 @@ export declare function refineCoreConfig(schema: typeof unrefinedCoreConfigSchem
3348
3352
  }, z.core.$strip>>>]>>, unknown>>>;
3349
3353
  configFile: z.ZodOptional<z.ZodString>;
3350
3354
  }, z.core.$strip>, z.ZodPipe<z.ZodCustom<unknown, unknown>, z.ZodTransform<z.core.$InferInnerFunctionTypeAsync<z.core.$ZodTuple<[z.ZodObject<{
3351
- outputDir: z.ZodOptional<z.ZodString>;
3352
- filename: z.ZodOptional<z.ZodString>;
3353
- format: z.ZodOptional<z.ZodArray<z.ZodEnum<{
3354
- json: "json";
3355
- md: "md";
3356
- }>>>;
3357
- skipReports: z.ZodOptional<z.ZodBoolean>;
3355
+ persist: z.ZodObject<{
3356
+ outputDir: z.ZodNonOptional<z.ZodOptional<z.ZodString>>;
3357
+ filename: z.ZodNonOptional<z.ZodOptional<z.ZodString>>;
3358
+ format: z.ZodNonOptional<z.ZodOptional<z.ZodArray<z.ZodEnum<{
3359
+ json: "json";
3360
+ md: "md";
3361
+ }>>>>;
3362
+ skipReports: z.ZodNonOptional<z.ZodOptional<z.ZodBoolean>>;
3363
+ }, z.core.$strip>;
3358
3364
  }, z.core.$strip>], null>, z.ZodUnion<readonly [z.ZodArray<z.ZodObject<{
3359
3365
  slug: z.ZodString;
3360
3366
  displayValue: z.ZodOptional<z.ZodString>;
@@ -1025,13 +1025,15 @@ export declare const pluginDataSchema: z.ZodObject<{
1025
1025
  }, z.core.$strip>>>]>>, unknown>>>;
1026
1026
  configFile: z.ZodOptional<z.ZodString>;
1027
1027
  }, z.core.$strip>, z.ZodPipe<z.ZodCustom<unknown, unknown>, z.ZodTransform<z.core.$InferInnerFunctionTypeAsync<z.core.$ZodTuple<[z.ZodObject<{
1028
- outputDir: z.ZodOptional<z.ZodString>;
1029
- filename: z.ZodOptional<z.ZodString>;
1030
- format: z.ZodOptional<z.ZodArray<z.ZodEnum<{
1031
- json: "json";
1032
- md: "md";
1033
- }>>>;
1034
- skipReports: z.ZodOptional<z.ZodBoolean>;
1028
+ persist: z.ZodObject<{
1029
+ outputDir: z.ZodNonOptional<z.ZodOptional<z.ZodString>>;
1030
+ filename: z.ZodNonOptional<z.ZodOptional<z.ZodString>>;
1031
+ format: z.ZodNonOptional<z.ZodOptional<z.ZodArray<z.ZodEnum<{
1032
+ json: "json";
1033
+ md: "md";
1034
+ }>>>>;
1035
+ skipReports: z.ZodNonOptional<z.ZodOptional<z.ZodBoolean>>;
1036
+ }, z.core.$strip>;
1035
1037
  }, z.core.$strip>], null>, z.ZodUnion<readonly [z.ZodArray<z.ZodObject<{
1036
1038
  slug: z.ZodString;
1037
1039
  displayValue: z.ZodOptional<z.ZodString>;
@@ -2165,13 +2167,15 @@ export declare const pluginConfigSchema: z.ZodObject<{
2165
2167
  }, z.core.$strip>>>]>>, unknown>>>;
2166
2168
  configFile: z.ZodOptional<z.ZodString>;
2167
2169
  }, z.core.$strip>, z.ZodPipe<z.ZodCustom<unknown, unknown>, z.ZodTransform<z.core.$InferInnerFunctionTypeAsync<z.core.$ZodTuple<[z.ZodObject<{
2168
- outputDir: z.ZodOptional<z.ZodString>;
2169
- filename: z.ZodOptional<z.ZodString>;
2170
- format: z.ZodOptional<z.ZodArray<z.ZodEnum<{
2171
- json: "json";
2172
- md: "md";
2173
- }>>>;
2174
- skipReports: z.ZodOptional<z.ZodBoolean>;
2170
+ persist: z.ZodObject<{
2171
+ outputDir: z.ZodNonOptional<z.ZodOptional<z.ZodString>>;
2172
+ filename: z.ZodNonOptional<z.ZodOptional<z.ZodString>>;
2173
+ format: z.ZodNonOptional<z.ZodOptional<z.ZodArray<z.ZodEnum<{
2174
+ json: "json";
2175
+ md: "md";
2176
+ }>>>>;
2177
+ skipReports: z.ZodNonOptional<z.ZodOptional<z.ZodBoolean>>;
2178
+ }, z.core.$strip>;
2175
2179
  }, z.core.$strip>], null>, z.ZodUnion<readonly [z.ZodArray<z.ZodObject<{
2176
2180
  slug: z.ZodString;
2177
2181
  displayValue: z.ZodOptional<z.ZodString>;
@@ -127,6 +127,26 @@ export declare const outputTransformSchema: z.ZodPipe<z.ZodCustom<unknown, unkno
127
127
  * @see {@link https://github.com/code-pushup/cli/blob/main/packages/models/docs/models-reference.md#outputtransform}
128
128
  */
129
129
  export type OutputTransform = z.infer<typeof outputTransformSchema>;
130
+ export declare const runnerArgsSchema: z.ZodObject<{
131
+ persist: z.ZodObject<{
132
+ outputDir: z.ZodNonOptional<z.ZodOptional<z.ZodString>>;
133
+ filename: z.ZodNonOptional<z.ZodOptional<z.ZodString>>;
134
+ format: z.ZodNonOptional<z.ZodOptional<z.ZodArray<z.ZodEnum<{
135
+ json: "json";
136
+ md: "md";
137
+ }>>>>;
138
+ skipReports: z.ZodNonOptional<z.ZodOptional<z.ZodBoolean>>;
139
+ }, z.core.$strip>;
140
+ }, z.core.$strip>;
141
+ /**
142
+ * Type Definition: `RunnerArgs`
143
+ *
144
+ * This type is derived from a Zod schema and represents
145
+ * the validated structure of `RunnerArgs` used within the application.
146
+ *
147
+ * @see {@link https://github.com/code-pushup/cli/blob/main/packages/models/docs/models-reference.md#runnerargs}
148
+ */
149
+ export type RunnerArgs = z.infer<typeof runnerArgsSchema>;
130
150
  export declare const runnerConfigSchema: z.ZodObject<{
131
151
  command: z.ZodString;
132
152
  args: z.ZodOptional<z.ZodArray<z.ZodString>>;
@@ -262,13 +282,15 @@ export declare const runnerConfigSchema: z.ZodObject<{
262
282
  */
263
283
  export type RunnerConfig = z.infer<typeof runnerConfigSchema>;
264
284
  export declare const runnerFunctionSchema: z.ZodPipe<z.ZodCustom<unknown, unknown>, z.ZodTransform<z.core.$InferInnerFunctionTypeAsync<z.core.$ZodTuple<[z.ZodObject<{
265
- outputDir: z.ZodOptional<z.ZodString>;
266
- filename: z.ZodOptional<z.ZodString>;
267
- format: z.ZodOptional<z.ZodArray<z.ZodEnum<{
268
- json: "json";
269
- md: "md";
270
- }>>>;
271
- skipReports: z.ZodOptional<z.ZodBoolean>;
285
+ persist: z.ZodObject<{
286
+ outputDir: z.ZodNonOptional<z.ZodOptional<z.ZodString>>;
287
+ filename: z.ZodNonOptional<z.ZodOptional<z.ZodString>>;
288
+ format: z.ZodNonOptional<z.ZodOptional<z.ZodArray<z.ZodEnum<{
289
+ json: "json";
290
+ md: "md";
291
+ }>>>>;
292
+ skipReports: z.ZodNonOptional<z.ZodOptional<z.ZodBoolean>>;
293
+ }, z.core.$strip>;
272
294
  }, z.core.$strip>], null>, z.ZodUnion<readonly [z.ZodArray<z.ZodObject<{
273
295
  slug: z.ZodString;
274
296
  displayValue: z.ZodOptional<z.ZodString>;
@@ -7,6 +7,13 @@ export const outputTransformSchema = convertAsyncZodFunctionToSchema(z.function(
7
7
  input: [z.unknown()],
8
8
  output: z.union([auditOutputsSchema, z.promise(auditOutputsSchema)]),
9
9
  }));
10
+ export const runnerArgsSchema = z
11
+ .object({
12
+ persist: persistConfigSchema
13
+ .required()
14
+ .describe('Persist config with defaults applied'),
15
+ })
16
+ .describe('Arguments passed to runner');
10
17
  export const runnerConfigSchema = z
11
18
  .object({
12
19
  command: z.string().describe('Shell command to execute'),
@@ -15,11 +22,11 @@ export const runnerConfigSchema = z
15
22
  outputTransform: outputTransformSchema.optional(),
16
23
  configFile: filePathSchema.describe('Runner config path').optional(),
17
24
  })
18
- .describe('How to execute runner');
25
+ .describe('How to execute runner using shell script');
19
26
  export const runnerFunctionSchema = convertAsyncZodFunctionToSchema(z.function({
20
- input: [persistConfigSchema],
27
+ input: [runnerArgsSchema],
21
28
  output: z.union([auditOutputsSchema, z.promise(auditOutputsSchema)]),
22
- }));
29
+ })).describe('Callback function for async runner execution in JS/TS');
23
30
  export const runnerFilesPathsSchema = z.object({
24
31
  runnerConfigPath: filePathSchema.describe('Runner config path'),
25
32
  runnerOutputPath: filePathSchema.describe('Runner output path'),
@@ -1 +1 @@
1
- {"version":3,"file":"runner-config.js","sourceRoot":"","sources":["../../../src/lib/runner-config.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,QAAQ,CAAC;AAC3B,OAAO,EAAE,kBAAkB,EAAE,MAAM,mBAAmB,CAAC;AACvD,OAAO,EAAE,+BAA+B,EAAE,MAAM,8BAA8B,CAAC;AAC/E,OAAO,EAAE,cAAc,EAAE,MAAM,6BAA6B,CAAC;AAC7D,OAAO,EAAE,mBAAmB,EAAE,MAAM,qBAAqB,CAAC;AAE1D,MAAM,CAAC,MAAM,qBAAqB,GAAG,+BAA+B,CAClE,CAAC,CAAC,QAAQ,CAAC;IACT,KAAK,EAAE,CAAC,CAAC,CAAC,OAAO,EAAE,CAAC;IACpB,MAAM,EAAE,CAAC,CAAC,KAAK,CAAC,CAAC,kBAAkB,EAAE,CAA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