UNPKG

dt-app

Version:

The Dynatrace App Toolkit is a tool you can use from your command line to create, develop, and deploy apps on your Dynatrace environment.

27 lines (26 loc) 1.3 kB
import type { DefinedError, JSONSchemaType } from 'ajv/dist/2019'; import type { DefaultableCliOptions, ResolvedCliOptions } from './cli-options'; export type ValidationLevel = 'default' | 'deployment' | 'none'; /** Initializes the schema to validate app.config options. Returns the schema and validator function */ export declare function initSchema(): { appOptionsSchema: JSONSchemaType<ResolvedCliOptions> | { additionalProperties: any; }; validateAppOptionsSchema: import("ajv/dist/types").ValidateFunction<ResolvedCliOptions>; }; /** Validates CLI config. */ export declare function validateConfig(config: ResolvedCliOptions, validationLevel?: ValidationLevel): Promise<ResolvedCliOptions>; /** * Returns a string for pretty console output of a validation error. * Refactored to accept a single options object. Title is optional and defaults to 'CLI configuration'. */ export declare function prettyConsoleError({ title, error, }: { title?: string; error: DefinedError; }): string; /** * Manual validation for the removed 1.0 configs. * A workaround solution to minimize the changes in the codebase * @param fileConfig The configuration object from the app.config.json file. */ export declare function manualValidations(fileConfig: DefaultableCliOptions): void;