import type { Logger } from '../logging/types.js';
/**
 * Minimal hook context that shims the `this` context oclif provides to hooks.
 *
 * Provides `debug()`, `log()`, `warn()`, `error()`, and a stub `config` object
 * so that existing hook implementations work without `@oclif/core`.
 */
export interface HookContext {
    debug(...args: unknown[]): void;
    log(...args: unknown[]): void;
    warn(...args: unknown[]): void;
    error(...args: unknown[]): void;
    config: Record<string, unknown>;
}
export interface HookContextOptions {
    /** Logger to route debug/log/warn/error through */
    logger?: Logger;
    /** Extra properties to include on the stub config object */
    config?: Record<string, unknown>;
}
/**
 * Creates a minimal hook context matching what oclif provides to hooks.
 */
export declare function createHookContext(options?: HookContextOptions): HookContext;
/**
 * Dynamically imports a hook file and invokes its default export.
 *
 * @param hookFilePath - Absolute path to the hook JS file
 * @param context - Hook context (`this` inside the hook)
 * @param hookOptions - Options passed as the first argument to the hook function
 * @param logger - Optional logger for warnings on failure
 * @returns The hook function's return value, or `undefined` on error
 */
export declare function invokeHook<TResult>(hookFilePath: string, context: HookContext, hookOptions: Record<string, unknown>, logger?: Logger): Promise<TResult | undefined>;
