envx-cli
Version:
Environment file encryption and management tool
256 lines • 8.27 kB
TypeScript
import { z } from 'zod';
export declare const baseOptionsSchema: z.ZodObject<{
cwd: z.ZodOptional<z.ZodString>;
environment: z.ZodOptional<z.ZodString>;
passphrase: z.ZodOptional<z.ZodString>;
secret: z.ZodOptional<z.ZodString>;
interactive: z.ZodOptional<z.ZodBoolean>;
generate: z.ZodOptional<z.ZodBoolean>;
stage: z.ZodOptional<z.ZodString>;
}, "strip", z.ZodTypeAny, {
cwd?: string | undefined;
environment?: string | undefined;
passphrase?: string | undefined;
secret?: string | undefined;
interactive?: boolean | undefined;
generate?: boolean | undefined;
stage?: string | undefined;
}, {
cwd?: string | undefined;
environment?: string | undefined;
passphrase?: string | undefined;
secret?: string | undefined;
interactive?: boolean | undefined;
generate?: boolean | undefined;
stage?: string | undefined;
}>;
export declare const encryptSchema: z.ZodEffects<z.ZodObject<{
environment: z.ZodString;
passphrase: z.ZodString;
cwd: z.ZodOptional<z.ZodString>;
secret: z.ZodOptional<z.ZodString>;
all: z.ZodOptional<z.ZodBoolean>;
overwrite: z.ZodOptional<z.ZodBoolean>;
}, "strip", z.ZodTypeAny, {
environment: string;
passphrase: string;
cwd?: string | undefined;
secret?: string | undefined;
all?: boolean | undefined;
overwrite?: boolean | undefined;
}, {
environment: string;
passphrase: string;
cwd?: string | undefined;
secret?: string | undefined;
all?: boolean | undefined;
overwrite?: boolean | undefined;
}>, {
environment: string;
passphrase: string;
cwd?: string | undefined;
secret?: string | undefined;
all?: boolean | undefined;
overwrite?: boolean | undefined;
}, {
environment: string;
passphrase: string;
cwd?: string | undefined;
secret?: string | undefined;
all?: boolean | undefined;
overwrite?: boolean | undefined;
}>;
export declare const decryptSchema: z.ZodEffects<z.ZodObject<{
environment: z.ZodString;
passphrase: z.ZodString;
cwd: z.ZodOptional<z.ZodString>;
secret: z.ZodOptional<z.ZodString>;
all: z.ZodOptional<z.ZodBoolean>;
overwrite: z.ZodOptional<z.ZodBoolean>;
}, "strip", z.ZodTypeAny, {
environment: string;
passphrase: string;
cwd?: string | undefined;
secret?: string | undefined;
all?: boolean | undefined;
overwrite?: boolean | undefined;
}, {
environment: string;
passphrase: string;
cwd?: string | undefined;
secret?: string | undefined;
all?: boolean | undefined;
overwrite?: boolean | undefined;
}>, {
environment: string;
passphrase: string;
cwd?: string | undefined;
secret?: string | undefined;
all?: boolean | undefined;
overwrite?: boolean | undefined;
}, {
environment: string;
passphrase: string;
cwd?: string | undefined;
secret?: string | undefined;
all?: boolean | undefined;
overwrite?: boolean | undefined;
}>;
export declare const createSchema: z.ZodObject<{
environment: z.ZodString;
template: z.ZodOptional<z.ZodString>;
cwd: z.ZodOptional<z.ZodString>;
}, "strip", z.ZodTypeAny, {
environment: string;
cwd?: string | undefined;
template?: string | undefined;
}, {
environment: string;
cwd?: string | undefined;
template?: string | undefined;
}>;
export declare const interactiveSchema: z.ZodObject<{
overwrite: z.ZodOptional<z.ZodBoolean>;
cwd: z.ZodOptional<z.ZodString>;
}, "strip", z.ZodTypeAny, {
cwd?: string | undefined;
overwrite?: boolean | undefined;
}, {
cwd?: string | undefined;
overwrite?: boolean | undefined;
}>;
export declare const copySchema: z.ZodEffects<z.ZodObject<{
environment: z.ZodOptional<z.ZodString>;
passphrase: z.ZodOptional<z.ZodString>;
secret: z.ZodOptional<z.ZodString>;
cwd: z.ZodOptional<z.ZodString>;
overwrite: z.ZodOptional<z.ZodBoolean>;
all: z.ZodOptional<z.ZodBoolean>;
}, "strip", z.ZodTypeAny, {
cwd?: string | undefined;
environment?: string | undefined;
passphrase?: string | undefined;
secret?: string | undefined;
all?: boolean | undefined;
overwrite?: boolean | undefined;
}, {
cwd?: string | undefined;
environment?: string | undefined;
passphrase?: string | undefined;
secret?: string | undefined;
all?: boolean | undefined;
overwrite?: boolean | undefined;
}>, {
cwd?: string | undefined;
environment?: string | undefined;
passphrase?: string | undefined;
secret?: string | undefined;
all?: boolean | undefined;
overwrite?: boolean | undefined;
}, {
cwd?: string | undefined;
environment?: string | undefined;
passphrase?: string | undefined;
secret?: string | undefined;
all?: boolean | undefined;
overwrite?: boolean | undefined;
}>;
export declare const stageSecretSchema: z.ZodObject<{
stage: z.ZodString;
secret: z.ZodString;
variableName: z.ZodString;
}, "strip", z.ZodTypeAny, {
secret: string;
stage: string;
variableName: string;
}, {
secret: string;
stage: string;
variableName: string;
}>;
export declare const envrcConfigSchema: z.ZodRecord<z.ZodString, z.ZodString>;
export declare const fileOperationSchema: z.ZodObject<{
success: z.ZodBoolean;
message: z.ZodString;
filePath: z.ZodOptional<z.ZodString>;
error: z.ZodOptional<z.ZodType<Error, z.ZodTypeDef, Error>>;
}, "strip", z.ZodTypeAny, {
message: string;
success: boolean;
filePath?: string | undefined;
error?: Error | undefined;
}, {
message: string;
success: boolean;
filePath?: string | undefined;
error?: Error | undefined;
}>;
export declare const commandResultSchema: z.ZodObject<{
success: z.ZodBoolean;
message: z.ZodString;
data: z.ZodOptional<z.ZodAny>;
errors: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
}, "strip", z.ZodTypeAny, {
message: string;
success: boolean;
data?: any;
errors?: string[] | undefined;
}, {
message: string;
success: boolean;
data?: any;
errors?: string[] | undefined;
}>;
export type EncryptSchemaType = z.infer<typeof encryptSchema>;
export type DecryptSchemaType = z.infer<typeof decryptSchema>;
export type CreateSchemaType = z.infer<typeof createSchema>;
export type InteractiveSchemaType = z.infer<typeof interactiveSchema>;
export type CopySchemaType = z.infer<typeof copySchema>;
export type StageSecretSchemaType = z.infer<typeof stageSecretSchema>;
export type EnvrcConfigSchemaType = z.infer<typeof envrcConfigSchema>;
export type FileOperationSchemaType = z.infer<typeof fileOperationSchema>;
export type CommandResultSchemaType = z.infer<typeof commandResultSchema>;
export declare const validateSchema: <T>(schema: z.ZodSchema<T>, data: unknown) => T;
export declare const validateOptions: (data: unknown) => {
cwd?: string | undefined;
environment?: string | undefined;
passphrase?: string | undefined;
secret?: string | undefined;
interactive?: boolean | undefined;
generate?: boolean | undefined;
stage?: string | undefined;
};
export declare const validateEncryptOptions: (data: unknown) => {
passphrase: string;
cwd?: string | undefined;
environment?: string | undefined;
secret?: string | undefined;
all?: boolean | undefined;
overwrite?: boolean | undefined;
};
export declare const validateDecryptOptions: (data: unknown) => {
passphrase: string;
cwd?: string | undefined;
environment?: string | undefined;
secret?: string | undefined;
all?: boolean | undefined;
overwrite?: boolean | undefined;
};
export declare const validateCreateOptions: (data: unknown) => {
environment: string;
cwd?: string | undefined;
template?: string | undefined;
};
export declare const validateInteractiveOptions: (data: unknown) => {
cwd?: string | undefined;
overwrite?: boolean | undefined;
};
export declare const validateCopyOptions: (data: unknown) => {
cwd?: string | undefined;
environment?: string | undefined;
passphrase?: string | undefined;
secret?: string | undefined;
all?: boolean | undefined;
overwrite?: boolean | undefined;
};
//# sourceMappingURL=index.d.ts.map