import { AsyncSeriesBailHook, AsyncSeriesWaterfallHook } from "tapable"; import { ILogger } from "./utils/logger"; import { AutoRc, RepoInformation, AuthorInformation, PluginConfig } from "./types"; export interface InteractiveInitHooks { /** Override where/how the rc file is written */ writeRcFile: AsyncSeriesBailHook<[AutoRc], true | void>; /** Get or verify the repo information */ getRepo: AsyncSeriesBailHook<[], RepoInformation | true | void>; /** Get or verify the author information */ getAuthor: AsyncSeriesBailHook<[], AuthorInformation | true | void>; /** Run extra configuration for a plugin */ configurePlugin: AsyncSeriesBailHook<[string], PluginConfig | void>; /** Add environment variables to get from the user */ createEnv: AsyncSeriesWaterfallHook<[Array<{ /** The name of the env var */ variable: string; /** The message to ask the user for the the env var */ message: string; }>]>; } /** * Parse the gitlog for commits that are PRs and attach their labels. * This class can also be tapped into via plugin to parse commits * in other ways (ex: conventional-commits) */ export default class InteractiveInit { /** Plugin entry points */ hooks: InteractiveInitHooks; /** The logger for the initializer */ logger: ILogger; /** Initialize the the init prompter and tap the default functionality */ constructor(options: { /** The logger for the initializer */ logger: ILogger; }); /** Run a prompt to get the author information */ getAuthorInformation(): Promise<{ name?: string | undefined; email?: string | undefined; }>; /** Run a prompt to get the repo information */ getRepoInformation(): Promise<{ repo?: string | undefined; owner?: string | undefined; }>; /** Load the default behavior */ private tapDefaults; /** Run the initialization. */ run(): Promise; } //# sourceMappingURL=init.d.ts.map