@cto.ai/ops
Version:
💻 CTO.ai - The CLI built for Teams 🚀
26 lines (25 loc) • 1.03 kB
TypeScript
import Command from './../../base';
import { Config } from './../../types';
import { flags } from '@oclif/parser';
export interface SetSecretInputs {
config: Config;
key: string;
value: string;
valueFilename: string;
}
export default class SecretsSet extends Command {
static description: string;
static flags: {
key: flags.IOptionFlag<string | undefined>;
value: flags.IOptionFlag<string | undefined>;
'from-file': flags.IOptionFlag<string | undefined>;
};
validateKeyInput: (input: string) => Promise<boolean | string>;
validateValueInput: (input: string) => Promise<boolean | string>;
resolveFileSecret: (input: SetSecretInputs) => Promise<SetSecretInputs>;
promptForSecret: (input: SetSecretInputs) => Promise<SetSecretInputs>;
setSecret: (inputs: SetSecretInputs) => Promise<SetSecretInputs>;
logMessage: (inputs: SetSecretInputs) => SetSecretInputs;
sendAnalytics: (inputs: SetSecretInputs) => Promise<SetSecretInputs>;
run(): Promise<void>;
}