@deepkit/app
Version:
Deepkit App, CLI framework and service container
25 lines (24 loc) • 730 B
TypeScript
export declare function resolveEnvFilePath(path: string): string | undefined;
export declare class EnvConfiguration {
protected container: {
[name: string]: any;
};
/**
* Reads a .env file from given path, based to basePath.
*/
loadEnvFile(path: string): boolean;
getKeys(): string[];
getAll(): {
[name: string]: any;
};
/**
* Returns the value for a configuration option.
*
* Priority is first process.env, then manually set options, then values from the loaded env file.
*/
get<T = any>(name: string): T;
/**
* Sets an option value. If a env file has been read, it will be overwritten.
*/
set(name: string, value: any): void;
}