console-app/lib/Option.ts

36 lines
664 B
TypeScript
Raw Normal View History

2020-05-15 16:53:45 +02:00
/*
* Copyright (C) Sapphirecode - All Rights Reserved
* This file is part of console-app which is released under MIT.
* See file 'LICENSE' for full license details.
* Created by Timo Hocker <timo@scode.ovh>, May 2020
*/
2020-06-09 13:13:27 +02:00
interface SourceConfig {
console?: boolean,
configs?: string[],
env?: boolean,
interactive?: boolean,
}
2020-05-09 19:51:43 +02:00
interface Option {
name: string;
required?: boolean;
default?: unknown;
2020-06-09 13:13:27 +02:00
sources?: SourceConfig;
/*
* alias?: string;
* env?: string;
* message?: string;
* preset?: unknown[];
* error?: string;
*/
2020-05-09 19:51:43 +02:00
}
2020-06-09 13:13:27 +02:00
interface OptionValue {
2020-05-09 19:51:43 +02:00
filled: boolean;
value?: unknown;
}
2020-06-09 13:13:27 +02:00
export { Option, OptionValue };