padrone 1.7.0 → 1.8.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (54) hide show
  1. package/CHANGELOG.md +22 -0
  2. package/README.md +2 -1
  3. package/dist/{args-Cnq0nwSM.mjs → args-DrCXxXeP.mjs} +20 -4
  4. package/dist/args-DrCXxXeP.mjs.map +1 -0
  5. package/dist/codegen/index.mjs +1 -1
  6. package/dist/{commands-B_gufyR9.mjs → commands-DLR0rFgq.mjs} +2 -2
  7. package/dist/{commands-B_gufyR9.mjs.map → commands-DLR0rFgq.mjs.map} +1 -1
  8. package/dist/{completion-BEuflbDO.mjs → completion-UnBKfGuk.mjs} +2 -2
  9. package/dist/{completion-BEuflbDO.mjs.map → completion-UnBKfGuk.mjs.map} +1 -1
  10. package/dist/docs/index.d.mts +1 -1
  11. package/dist/docs/index.mjs +2 -2
  12. package/dist/{formatter-DrvhDMrq.d.mts → formatter-CY3KrOEd.d.mts} +3 -2
  13. package/dist/formatter-CY3KrOEd.d.mts.map +1 -0
  14. package/dist/{help-BtxLgrF_.mjs → help-B-ZMYyn-.mjs} +16 -6
  15. package/dist/help-B-ZMYyn-.mjs.map +1 -0
  16. package/dist/{index-D6-7dz0l.d.mts → index-C2n3k4e8.d.mts} +332 -116
  17. package/dist/index-C2n3k4e8.d.mts.map +1 -0
  18. package/dist/index.d.mts +17 -160
  19. package/dist/index.d.mts.map +1 -1
  20. package/dist/index.mjs +78 -65
  21. package/dist/index.mjs.map +1 -1
  22. package/dist/{mcp-6-Jw4Bpq.mjs → mcp-D6PdtjIs.mjs} +4 -4
  23. package/dist/{mcp-6-Jw4Bpq.mjs.map → mcp-D6PdtjIs.mjs.map} +1 -1
  24. package/dist/{serve-YVTPzBCl.mjs → serve-PaCLsNoD.mjs} +4 -4
  25. package/dist/{serve-YVTPzBCl.mjs.map → serve-PaCLsNoD.mjs.map} +1 -1
  26. package/dist/test.d.mts +1 -1
  27. package/dist/zod.d.mts +1 -1
  28. package/package.json +3 -3
  29. package/src/core/args.ts +24 -1
  30. package/src/core/create.ts +21 -14
  31. package/src/core/exec.ts +4 -3
  32. package/src/core/interceptors.ts +12 -6
  33. package/src/core/program-methods.ts +12 -2
  34. package/src/core/validate.ts +26 -7
  35. package/src/extension/auto-output.ts +1 -1
  36. package/src/extension/config.ts +2 -1
  37. package/src/extension/env.ts +5 -4
  38. package/src/extension/index.ts +1 -0
  39. package/src/extension/interactive.ts +2 -1
  40. package/src/extension/logger.ts +1 -1
  41. package/src/extension/progress.ts +2 -2
  42. package/src/extension/tracing.ts +1 -1
  43. package/src/index.ts +5 -1
  44. package/src/output/formatter.ts +6 -1
  45. package/src/output/help.ts +15 -3
  46. package/src/types/args-meta.ts +10 -0
  47. package/src/types/builder.ts +140 -38
  48. package/src/types/index.ts +2 -0
  49. package/src/types/interceptor.ts +12 -12
  50. package/src/util/type-utils.ts +22 -0
  51. package/dist/args-Cnq0nwSM.mjs.map +0 -1
  52. package/dist/formatter-DrvhDMrq.d.mts.map +0 -1
  53. package/dist/help-BtxLgrF_.mjs.map +0 -1
  54. package/dist/index-D6-7dz0l.d.mts.map +0 -1
@@ -1,4 +1,4 @@
1
- import { a as ColorConfig, n as HelpFormat, o as ColorTheme, t as HelpDetail } from "./formatter-DrvhDMrq.mjs";
1
+ import { a as ColorConfig, n as HelpFormat, o as ColorTheme, t as HelpDetail } from "./formatter-CY3KrOEd.mjs";
2
2
  import { StandardJSONSchemaV1, StandardSchemaV1 } from "@standard-schema/spec";
3
3
  import { Tool } from "ai";
4
4
 
@@ -12,6 +12,16 @@ interface PadroneFieldMeta {
12
12
  flags?: readonly SingleChar[] | SingleChar;
13
13
  /** Multi-character alternative long names. Used with double dash (e.g. `--dry-run` for `--dryRun`). */
14
14
  alias?: readonly string[] | string;
15
+ /**
16
+ * Custom negative keyword(s) for boolean options. When provided, `--<keyword>` sets this option to `false`.
17
+ * Disables the default `--no-<option>` negation prefix. Set to `''` or `[]` to only disable the prefix.
18
+ * @example
19
+ * ```ts
20
+ * local: z.boolean().default(true).meta({ negative: 'remote' })
21
+ * // --remote sets local to false, --no-local is disabled
22
+ * ```
23
+ */
24
+ negative?: readonly string[] | string;
15
25
  deprecated?: boolean | string;
16
26
  hidden?: boolean;
17
27
  examples?: readonly unknown[];
@@ -322,105 +332,6 @@ type ResolvedPadroneRuntime = Required<Omit<PadroneRuntime, 'prompt' | 'interact
322
332
  */
323
333
  declare const REPL_SIGINT: unique symbol;
324
334
  //#endregion
325
- //#region src/feature/mcp.d.ts
326
- type PadroneMcpPreferences = {
327
- /** Server name. Defaults to the program name. */name?: string; /** Server version. Defaults to the program version. */
328
- version?: string;
329
- /**
330
- * Transport mode.
331
- * - `'http'` — Start a Streamable HTTP server (default). Responds with `application/json` or `text/event-stream` based on the client's `Accept` header. Use `port` and `host` to configure.
332
- * - `'stdio'` — Communicate over stdin/stdout with newline-delimited JSON.
333
- */
334
- transport?: 'http' | 'stdio'; /** HTTP port. Defaults to `3000`. Only used with `transport: 'http'`. */
335
- port?: number; /** HTTP host. Defaults to `'127.0.0.1'`. Only used with `transport: 'http'`. */
336
- host?: string; /** Base path for the MCP endpoint. Defaults to `'/mcp'`. Only used with `transport: 'http'`. */
337
- basePath?: string; /** CORS allowed origin. Defaults to `'*'`. Set to a specific origin or `false` to disable CORS headers. Only used with HTTP transports. */
338
- cors?: string | false;
339
- };
340
- //#endregion
341
- //#region src/feature/serve.d.ts
342
- type PadroneServePreferences = {
343
- /** Port to listen on. Default: 3000 */port?: number; /** Host to bind to. Default: '127.0.0.1' */
344
- host?: string; /** Base path prefix for all routes. Default: '/' */
345
- basePath?: string; /** CORS allowed origin. Default: '*'. Set to `false` to disable CORS headers. */
346
- cors?: string | false; /** Control built-in utility endpoints. All enabled by default. */
347
- builtins?: {
348
- /** GET /_health — returns 200 OK. */health?: boolean; /** GET /_help and GET /_help/:command — returns help text. */
349
- help?: boolean; /** GET /_schema and GET /_schema/:command — returns JSON Schema. */
350
- schema?: boolean; /** GET /_docs — Scalar OpenAPI docs viewer. */
351
- docs?: boolean;
352
- }; /** Hook to run before each request. Return a Response to short-circuit. */
353
- onRequest?: (req: Request) => Response | void | Promise<Response | void>; /** Transform errors into responses. */
354
- onError?: (error: unknown, req: Request) => Response;
355
- };
356
- //#endregion
357
- //#region src/feature/wrap.d.ts
358
- /**
359
- * Configuration for wrapping an external CLI tool.
360
- */
361
- type WrapConfig<TCommandArgs extends PadroneSchema = PadroneSchema, TWrapArgs extends PadroneSchema = TCommandArgs> = {
362
- /**
363
- * The command to execute (e.g., 'git', 'docker', 'npm').
364
- */
365
- command: string;
366
- /**
367
- * Optional fixed arguments that always precede the arguments (e.g., ['commit'] for 'git commit').
368
- */
369
- args?: string[];
370
- /**
371
- * Positional argument configuration for the external command.
372
- * If not provided, defaults to the wrapping command's positional configuration.
373
- */
374
- positional?: string[];
375
- /**
376
- * Whether to inherit stdio streams (stdin, stdout, stderr) from the parent process.
377
- * Default: true
378
- */
379
- inheritStdio?: boolean;
380
- /**
381
- * Optional schema that transforms command arguments to external CLI arguments.
382
- * The schema's input type should match the command arguments, and its output type defines
383
- * the arguments expected by the external command.
384
- * If not provided, command arguments are passed through as-is.
385
- */
386
- schema?: TWrapArgs | ((commandArguments: TCommandArgs) => TWrapArgs);
387
- };
388
- /**
389
- * Result from executing a wrapped CLI tool.
390
- */
391
- type WrapResult = {
392
- /**
393
- * The exit code of the process.
394
- */
395
- exitCode: number;
396
- /**
397
- * Standard output from the process (only if inheritStdio is false).
398
- */
399
- stdout?: string;
400
- /**
401
- * Standard error from the process (only if inheritStdio is false).
402
- */
403
- stderr?: string;
404
- /**
405
- * Whether the process exited successfully (exit code 0).
406
- */
407
- success: boolean;
408
- };
409
- //#endregion
410
- //#region src/output/help.d.ts
411
- type HelpPreferences = {
412
- format?: HelpFormat | 'auto';
413
- detail?: HelpDetail;
414
- theme?: ColorTheme | ColorConfig; /** Show all global commands and flags in full detail */
415
- all?: boolean; /** Terminal width for text wrapping. Defaults to terminal columns or 80. */
416
- width?: number; /** Terminal capabilities for auto-detection of ANSI and width. */
417
- terminal?: {
418
- columns?: number;
419
- isTTY?: boolean;
420
- }; /** Environment variables for auto-detection (e.g., NO_COLOR, CI). */
421
- env?: Record<string, string | undefined>;
422
- };
423
- //#endregion
424
335
  //#region src/types/schema.d.ts
425
336
  /**
426
337
  * A schema that supports both validation (StandardSchemaV1) and JSON schema generation (StandardJSONSchemaV1).
@@ -569,6 +480,25 @@ type WithInterceptor<T, TProvides> = T extends {
569
480
  } ? T extends {
570
481
  run: any;
571
482
  } ? PadroneProgram<PN, N, PaN, A, R, C, any, AS, CTX, CTXP & TProvides> : PadroneBuilder<PN, N, PaN, A, R, C, any, AS, CTX, CTXP & TProvides> : T;
483
+ /**
484
+ * Utility type for extensions that force the builder/program into async mode.
485
+ * Sets `TAsync` to `true` while preserving all other type params.
486
+ */
487
+ type WithAsync<T> = T extends {
488
+ '~types': {
489
+ programName: infer PN extends string;
490
+ name: infer N extends string;
491
+ parentName: infer PaN extends string;
492
+ argsSchema: infer A extends PadroneSchema;
493
+ result: infer R;
494
+ commands: infer C extends [...AnyPadroneCommand[]];
495
+ async: any;
496
+ context: infer CTX;
497
+ contextProvided: infer CTXP;
498
+ };
499
+ } ? T extends {
500
+ run: any;
501
+ } ? PadroneProgram<PN, N, PaN, A, R, C, any, true, CTX, CTXP> : PadroneBuilder<PN, N, PaN, A, R, C, any, true, CTX, CTXP> : T;
572
502
  type PickCommandByName<TCommands extends AnyPadroneCommand[], TName extends string | AnyPadroneCommand> = TName extends AnyPadroneCommand ? TName : FlattenCommands<TCommands> extends infer Cmd extends AnyPadroneCommand ? Cmd extends AnyPadroneCommand ? TName extends GetCommandPathsAndAliases<Cmd> ? Cmd : never : never : never;
573
503
  type FlattenCommands<TCommands extends AnyPadroneCommand[]> = TCommands extends [] ? never : number extends TCommands['length'] ? IsAny<TCommands[number]> extends true ? never : TCommands[number] : TCommands[number] extends infer Cmd extends AnyPadroneCommand ? Cmd | FlattenCommands<Cmd['~types']['commands']> : never;
574
504
  /**
@@ -603,9 +533,250 @@ type RepathCommands<TCommands extends [...AnyPadroneCommand[]], TNewParentPath e
603
533
  type RepathCommand<TCommand extends AnyPadroneCommand, TNewParentName extends string> = PadroneCommand<TCommand['~types']['name'], TNewParentName, TCommand['~types']['argsSchema'], TCommand['~types']['result'], RepathCommands<TCommand['~types']['commands'], FullCommandName<TCommand['~types']['name'], TNewParentName>>, TCommand['~types']['aliases'], TCommand['~types']['async'], TCommand['~types']['context'], TCommand['~types']['contextProvided']>;
604
534
  type PickCommandByPossibleCommands<TCommands extends AnyPadroneCommand[], TCommand extends PossibleCommands<TCommands, true, true> | SafeString> = CommandIsUnknownable<TCommand> extends true ? FlattenCommands<TCommands> : TCommand extends AnyPadroneCommand ? TCommand : TCommand extends string ? TCommand extends GetCommandPathsOrAliases<TCommands> ? PickCommandByName<TCommands, TCommand> : SplitLastSpace<TCommand> extends [infer Prefix extends string, infer Rest] ? IsNever<Rest> extends true ? PickCommandByName<TCommands, Prefix> : PickCommandByPossibleCommands<TCommands, Prefix> : never : never;
605
535
  //#endregion
536
+ //#region src/extension/logger.d.ts
537
+ /** Log level values ordered by severity. */
538
+ type PadroneLogLevel = 'trace' | 'debug' | 'info' | 'warn' | 'error' | 'silent';
539
+ /** Logger instance injected into the command context. */
540
+ type PadroneLogger = {
541
+ trace: (...args: unknown[]) => void;
542
+ debug: (...args: unknown[]) => void;
543
+ info: (...args: unknown[]) => void;
544
+ warn: (...args: unknown[]) => void;
545
+ error: (...args: unknown[]) => void; /** The current effective log level. */
546
+ level: PadroneLogLevel; /** Create a child logger with a prefix label. */
547
+ child: (label: string) => PadroneLogger;
548
+ };
549
+ /** Configuration for the logger extension. */
550
+ type PadroneLoggerConfig = {
551
+ /** Minimum log level to output. Defaults to `'info'`. */level?: PadroneLogLevel; /** Prefix prepended to every log message. */
552
+ prefix?: string; /** Include timestamps in log output. Defaults to `false`. */
553
+ timestamps?: boolean;
554
+ };
555
+ /** Builder/program type after applying `padroneLogger()`. Adds `{ logger: PadroneLogger }` to the command context. */
556
+ type WithLogger<T> = WithInterceptor<T, {
557
+ logger: PadroneLogger;
558
+ }>;
559
+ /**
560
+ * Extension that injects a structured logger into the command context.
561
+ *
562
+ * The logger respects a configurable log level threshold, supports prefixed
563
+ * child loggers, and routes output through the runtime's `output`/`error`
564
+ * functions so it works in any environment (terminal, test, web).
565
+ *
566
+ * Supports CLI flags for runtime level overrides:
567
+ * - `--trace` → sets level to `trace`
568
+ * - `--verbose` or `--debug` → sets level to `debug`
569
+ * - `--silent` or `--quiet` → sets level to `silent`
570
+ * - `--log-level=<level>` → sets an explicit level (`trace`, `debug`, `info`, `warn`, `error`, `silent`)
571
+ *
572
+ * CLI flags take precedence over the programmatic config.
573
+ *
574
+ * Provides `{ logger: PadroneLogger }` on the command context.
575
+ * Access it in action handlers as `ctx.context.logger`.
576
+ *
577
+ * Usage:
578
+ * ```ts
579
+ * createPadrone('my-cli')
580
+ * .extend(padroneLogger({ level: 'info' }))
581
+ * .command('sync', (c) =>
582
+ * c.action((_args, ctx) => {
583
+ * ctx.context.logger.info('starting sync');
584
+ * const db = ctx.context.logger.child('db');
585
+ * db.debug('connecting...');
586
+ * })
587
+ * )
588
+ * ```
589
+ *
590
+ * Then run:
591
+ * ```sh
592
+ * my-cli sync --verbose # debug level
593
+ * my-cli sync --quiet # silent
594
+ * my-cli sync --log-level=warn
595
+ * ```
596
+ */
597
+ declare function padroneLogger<T extends CommandTypesBase>(config?: PadroneLoggerConfig): (builder: T) => WithLogger<T>;
598
+ //#endregion
599
+ //#region src/extension/tracing.d.ts
600
+ /** Minimal subset of OTEL `SpanStatusCode`. */
601
+ type SpanStatusCode = 0 | 1 | 2;
602
+ /** Minimal subset of OTEL `SpanStatus`. */
603
+ type SpanStatus = {
604
+ code: SpanStatusCode;
605
+ message?: string;
606
+ };
607
+ /** Minimal subset of OTEL `Span`. */
608
+ interface OtelSpan {
609
+ setAttribute(key: string, value: string | number | boolean): this;
610
+ addEvent(name: string, attributes?: Record<string, string | number | boolean>): this;
611
+ setStatus(status: SpanStatus): this;
612
+ recordException(error: unknown): this;
613
+ end(): void;
614
+ spanContext(): {
615
+ traceId: string;
616
+ spanId: string;
617
+ };
618
+ }
619
+ /** Minimal subset of OTEL `Tracer`. */
620
+ interface OtelTracer {
621
+ startSpan(name: string): OtelSpan;
622
+ }
623
+ /** Minimal subset of OTEL `TracerProvider`. */
624
+ interface OtelTracerProvider {
625
+ getTracer(name: string, version?: string): OtelTracer;
626
+ }
627
+ /** Tracing handle injected into the command context. */
628
+ type PadroneTracer = {
629
+ /** The underlying OTEL tracer. */tracer: OtelTracer; /** Root span covering the full command execution. */
630
+ rootSpan: OtelSpan; /** Run `fn` inside a child span that is automatically ended when `fn` returns (or rejects). */
631
+ span: <T>(name: string, fn: (span: OtelSpan) => T) => T;
632
+ };
633
+ /** Configuration for the tracing extension. */
634
+ type PadroneTracingConfig = {
635
+ /** OTEL `TracerProvider`. Required — there is no global fallback. */provider: OtelTracerProvider; /** Service / tracer name. Defaults to the CLI program name. */
636
+ serviceName?: string;
637
+ };
638
+ /** Builder/program type after applying `padroneTracing()`. Adds `{ tracing: PadroneTracer }` to the command context. */
639
+ type WithTracing<T> = WithInterceptor<T, {
640
+ tracing: PadroneTracer;
641
+ }>;
642
+ /**
643
+ * Extension that adds OpenTelemetry tracing to command execution.
644
+ *
645
+ * Creates a root span for each command invocation and provides a `PadroneTracer`
646
+ * on the command context for creating child spans in action handlers.
647
+ *
648
+ * When used with `padroneLogger()`, the logger automatically emits span events
649
+ * for each log call — no extra configuration needed. The logger detects the
650
+ * tracing context and bridges log output to span events.
651
+ *
652
+ * Uses minimal OTEL-compatible interfaces — pass any `TracerProvider` that
653
+ * implements `getTracer()`. Works with `@opentelemetry/api` or compatible
654
+ * libraries.
655
+ *
656
+ * Provides `{ tracing: PadroneTracer }` on the command context.
657
+ * Access it in action handlers as `ctx.context.tracing`.
658
+ *
659
+ * Usage:
660
+ * ```ts
661
+ * import { trace } from '@opentelemetry/api';
662
+ *
663
+ * createPadrone('my-cli')
664
+ * .extend(padroneTracing({ provider: trace.getTracerProvider() }))
665
+ * .extend(padroneLogger())
666
+ * .command('deploy', (c) =>
667
+ * c.action((_args, ctx) => {
668
+ * ctx.context.logger.info('deploying'); // also emits a span event
669
+ * ctx.context.tracing.span('build', (span) => {
670
+ * span.setAttribute('target', 'production');
671
+ * });
672
+ * })
673
+ * )
674
+ * ```
675
+ */
676
+ declare function padroneTracing<T extends CommandTypesBase>(config: PadroneTracingConfig): (builder: T) => WithTracing<T>;
677
+ //#endregion
678
+ //#region src/feature/mcp.d.ts
679
+ type PadroneMcpPreferences = {
680
+ /** Server name. Defaults to the program name. */name?: string; /** Server version. Defaults to the program version. */
681
+ version?: string;
682
+ /**
683
+ * Transport mode.
684
+ * - `'http'` — Start a Streamable HTTP server (default). Responds with `application/json` or `text/event-stream` based on the client's `Accept` header. Use `port` and `host` to configure.
685
+ * - `'stdio'` — Communicate over stdin/stdout with newline-delimited JSON.
686
+ */
687
+ transport?: 'http' | 'stdio'; /** HTTP port. Defaults to `3000`. Only used with `transport: 'http'`. */
688
+ port?: number; /** HTTP host. Defaults to `'127.0.0.1'`. Only used with `transport: 'http'`. */
689
+ host?: string; /** Base path for the MCP endpoint. Defaults to `'/mcp'`. Only used with `transport: 'http'`. */
690
+ basePath?: string; /** CORS allowed origin. Defaults to `'*'`. Set to a specific origin or `false` to disable CORS headers. Only used with HTTP transports. */
691
+ cors?: string | false;
692
+ };
693
+ //#endregion
694
+ //#region src/feature/serve.d.ts
695
+ type PadroneServePreferences = {
696
+ /** Port to listen on. Default: 3000 */port?: number; /** Host to bind to. Default: '127.0.0.1' */
697
+ host?: string; /** Base path prefix for all routes. Default: '/' */
698
+ basePath?: string; /** CORS allowed origin. Default: '*'. Set to `false` to disable CORS headers. */
699
+ cors?: string | false; /** Control built-in utility endpoints. All enabled by default. */
700
+ builtins?: {
701
+ /** GET /_health — returns 200 OK. */health?: boolean; /** GET /_help and GET /_help/:command — returns help text. */
702
+ help?: boolean; /** GET /_schema and GET /_schema/:command — returns JSON Schema. */
703
+ schema?: boolean; /** GET /_docs — Scalar OpenAPI docs viewer. */
704
+ docs?: boolean;
705
+ }; /** Hook to run before each request. Return a Response to short-circuit. */
706
+ onRequest?: (req: Request) => Response | void | Promise<Response | void>; /** Transform errors into responses. */
707
+ onError?: (error: unknown, req: Request) => Response;
708
+ };
709
+ //#endregion
710
+ //#region src/feature/wrap.d.ts
711
+ /**
712
+ * Configuration for wrapping an external CLI tool.
713
+ */
714
+ type WrapConfig<TCommandArgs extends PadroneSchema = PadroneSchema, TWrapArgs extends PadroneSchema = TCommandArgs> = {
715
+ /**
716
+ * The command to execute (e.g., 'git', 'docker', 'npm').
717
+ */
718
+ command: string;
719
+ /**
720
+ * Optional fixed arguments that always precede the arguments (e.g., ['commit'] for 'git commit').
721
+ */
722
+ args?: string[];
723
+ /**
724
+ * Positional argument configuration for the external command.
725
+ * If not provided, defaults to the wrapping command's positional configuration.
726
+ */
727
+ positional?: string[];
728
+ /**
729
+ * Whether to inherit stdio streams (stdin, stdout, stderr) from the parent process.
730
+ * Default: true
731
+ */
732
+ inheritStdio?: boolean;
733
+ /**
734
+ * Optional schema that transforms command arguments to external CLI arguments.
735
+ * The schema's input type should match the command arguments, and its output type defines
736
+ * the arguments expected by the external command.
737
+ * If not provided, command arguments are passed through as-is.
738
+ */
739
+ schema?: TWrapArgs | ((commandArguments: TCommandArgs) => TWrapArgs);
740
+ };
741
+ /**
742
+ * Result from executing a wrapped CLI tool.
743
+ */
744
+ type WrapResult = {
745
+ /**
746
+ * The exit code of the process.
747
+ */
748
+ exitCode: number;
749
+ /**
750
+ * Standard output from the process (only if inheritStdio is false).
751
+ */
752
+ stdout?: string;
753
+ /**
754
+ * Standard error from the process (only if inheritStdio is false).
755
+ */
756
+ stderr?: string;
757
+ /**
758
+ * Whether the process exited successfully (exit code 0).
759
+ */
760
+ success: boolean;
761
+ };
762
+ //#endregion
763
+ //#region src/output/help.d.ts
764
+ type HelpPreferences = {
765
+ format?: HelpFormat | 'auto';
766
+ detail?: HelpDetail;
767
+ theme?: ColorTheme | ColorConfig; /** Show all global commands and flags in full detail */
768
+ all?: boolean; /** Terminal width for text wrapping. Defaults to terminal columns or 80. */
769
+ width?: number; /** Terminal capabilities for auto-detection of ANSI and width. */
770
+ terminal?: {
771
+ columns?: number;
772
+ isTTY?: boolean;
773
+ }; /** Environment variables for auto-detection (e.g., NO_COLOR, CI). */
774
+ env?: Record<string, string | undefined>;
775
+ };
776
+ //#endregion
606
777
  //#region src/types/interceptor.d.ts
607
778
  /** Base context shared across all interceptor phases within a single execution. */
608
- type InterceptorBaseContext<TContext = unknown> = {
779
+ type InterceptorBaseContext<TContext = object> = {
609
780
  /** The resolved command for this execution. In the parse phase, this is the root program. */command: AnyPadroneCommand; /** The raw CLI input string (undefined when invoked without input). */
610
781
  input: string | undefined; /** Cancellation signal that fires when the process receives a termination signal. */
611
782
  signal: AbortSignal; /** User-defined context object, resolved through the command's parent chain. */
@@ -615,7 +786,7 @@ type InterceptorBaseContext<TContext = unknown> = {
615
786
  caller: PadroneActionContext['caller'];
616
787
  };
617
788
  /** Context for the parse phase. */
618
- type InterceptorParseContext<TContext = unknown> = InterceptorBaseContext<TContext>;
789
+ type InterceptorParseContext<TContext = object> = InterceptorBaseContext<TContext>;
619
790
  /** Result returned by the parse phase's `next()`. */
620
791
  type InterceptorParseResult = {
621
792
  command: AnyPadroneCommand;
@@ -623,7 +794,7 @@ type InterceptorParseResult = {
623
794
  positionalArgs: string[];
624
795
  };
625
796
  /** Context for the validate phase. */
626
- type InterceptorValidateContext<TContext = unknown> = InterceptorBaseContext<TContext> & {
797
+ type InterceptorValidateContext<TContext = object> = InterceptorBaseContext<TContext> & {
627
798
  /** Raw named arguments extracted by the parser. Mutable — modify before `next()` to inject/override values. */rawArgs: Record<string, unknown>; /** Positional argument strings extracted by the parser. */
628
799
  positionalArgs: string[]; /** Interactive mode override (set by the interactive extension when `--interactive` / `-i` flag is used). */
629
800
  interactive?: boolean; /** Interactive mode preference from eval/cli options. Available for the interactive extension. */
@@ -635,7 +806,7 @@ type InterceptorValidateResult<TArgs = unknown> = {
635
806
  argsResult: StandardSchemaV1.Result<TArgs>;
636
807
  };
637
808
  /** Context for the execute phase. Includes validate context fields (rawArgs, positionalArgs). */
638
- type InterceptorExecuteContext<TArgs = unknown, TContext = unknown> = InterceptorValidateContext<TContext> & {
809
+ type InterceptorExecuteContext<TArgs = unknown, TContext = object> = InterceptorValidateContext<TContext> & {
639
810
  /** Validated arguments that will be passed to the action. Mutable — modify before `next()` to override. */args: TArgs;
640
811
  };
641
812
  /** Result returned by the execute phase's `next()`. */
@@ -643,9 +814,9 @@ type InterceptorExecuteResult<TResult = unknown> = {
643
814
  result: TResult;
644
815
  };
645
816
  /** Context for the start phase. Runs before parsing, wraps the entire pipeline. */
646
- type InterceptorStartContext<TContext = unknown> = InterceptorBaseContext<TContext>;
817
+ type InterceptorStartContext<TContext = object> = InterceptorBaseContext<TContext>;
647
818
  /** Context for the error phase. Called when the pipeline throws. Includes pipeline state accumulated before the error. */
648
- type InterceptorErrorContext<TContext = unknown> = InterceptorBaseContext<TContext> & {
819
+ type InterceptorErrorContext<TContext = object> = InterceptorBaseContext<TContext> & {
649
820
  /** The error that was thrown. */error: unknown; /** Raw named arguments (available if parse completed). */
650
821
  rawArgs?: Record<string, unknown>; /** Positional argument strings (available if parse completed). */
651
822
  positionalArgs?: string[]; /** Validated arguments (available if validate completed). */
@@ -657,7 +828,7 @@ type InterceptorErrorResult<TResult = unknown> = {
657
828
  result?: TResult;
658
829
  };
659
830
  /** Context for the shutdown phase. Always runs after the pipeline (success or failure). Includes pipeline state accumulated before completion. */
660
- type InterceptorShutdownContext<TResult = unknown, TContext = unknown> = InterceptorBaseContext<TContext> & {
831
+ type InterceptorShutdownContext<TResult = unknown, TContext = object> = InterceptorBaseContext<TContext> & {
661
832
  /** The error, if the pipeline failed (after error phase processing). */error?: unknown; /** The pipeline result, if it succeeded. */
662
833
  result?: TResult; /** Raw named arguments (available if parse completed). */
663
834
  rawArgs?: Record<string, unknown>; /** Positional argument strings (available if parse completed). */
@@ -708,7 +879,7 @@ type InterceptorMeta = {
708
879
  * - `TArgs` — the validated arguments type (output of the args schema).
709
880
  * - `TResult` — the command's return type.
710
881
  */
711
- type InterceptorPhases<TArgs = unknown, TResult = unknown, TContext = unknown> = {
882
+ type InterceptorPhases<TArgs = unknown, TResult = unknown, TContext = object> = {
712
883
  /**
713
884
  * Runs before the pipeline (parse → validate → execute). `next()` proceeds to the pipeline.
714
885
  * Root interceptors only. Use for startup tasks like telemetry, update checks, or global config loading.
@@ -732,7 +903,7 @@ type InterceptorPhases<TArgs = unknown, TResult = unknown, TContext = unknown> =
732
903
  * Factory function that creates phase handlers for an interceptor.
733
904
  * Called once per command execution — the closure provides typed, scoped cross-phase state across phases.
734
905
  */
735
- type InterceptorFactory<TArgs = unknown, TResult = unknown, TContext = unknown> = () => InterceptorPhases<TArgs, TResult, TContext>;
906
+ type InterceptorFactory<TArgs = unknown, TResult = unknown, TContext = object> = () => InterceptorPhases<TArgs, TResult, TContext>;
736
907
  /**
737
908
  * A self-contained interceptor value: a factory function with static metadata as own properties.
738
909
  * Created via `defineInterceptor(meta, factory)`. This is the distributable form — a single
@@ -741,7 +912,7 @@ type InterceptorFactory<TArgs = unknown, TResult = unknown, TContext = unknown>
741
912
  * Also accepted directly by `.intercept()` as the single-argument form.
742
913
  * Call `.provides<T>()` to brand it as a context-providing interceptor.
743
914
  */
744
- type PadroneInterceptorFn<TArgs = unknown, TResult = unknown, TContext = unknown> = InterceptorFactory<TArgs, TResult, TContext> & InterceptorMeta & {
915
+ type PadroneInterceptorFn<TArgs = unknown, TResult = unknown, TContext = object> = InterceptorFactory<TArgs, TResult, TContext> & InterceptorMeta & {
745
916
  /** Brand this interceptor as providing additional context of type `TProvides`. No-op at runtime; purely a type-level cast. */provides: <TProvides>() => PadroneContextInterceptor<TProvides, TArgs, TResult, TContext>;
746
917
  /**
747
918
  * Brand this interceptor as requiring context of type `TRequires` to be available.
@@ -757,7 +928,7 @@ type PadroneInterceptorFn<TArgs = unknown, TResult = unknown, TContext = unknown
757
928
  *
758
929
  * Create with `defineInterceptor(meta, factory)` or pass `(meta, factory)` directly to `.intercept()`.
759
930
  */
760
- type PadroneInterceptor<TArgs = unknown, TResult = unknown, TContext = unknown> = PadroneInterceptorFn<TArgs, TResult, TContext>;
931
+ type PadroneInterceptor<TArgs = unknown, TResult = unknown, TContext = object> = PadroneInterceptorFn<TArgs, TResult, TContext>;
761
932
  /**
762
933
  * A context-providing interceptor. Carries a phantom `'~context'` brand declaring what it adds
763
934
  * to the command context. When registered via `.intercept()`, the builder's context type is
@@ -766,7 +937,7 @@ type PadroneInterceptor<TArgs = unknown, TResult = unknown, TContext = unknown>
766
937
  * Created by calling `.provides<T>()` on a `PadroneInterceptorFn`.
767
938
  * Chain `.requires<T>()` to also declare context dependencies.
768
939
  */
769
- type PadroneContextInterceptor<TProvides = unknown, TArgs = unknown, TResult = unknown, TContext = unknown> = Omit<PadroneInterceptorFn<TArgs, TResult, TContext>, 'requires'> & InterceptorFactory<TArgs, TResult, TContext> & {
940
+ type PadroneContextInterceptor<TProvides = unknown, TArgs = unknown, TResult = unknown, TContext = object> = Omit<PadroneInterceptorFn<TArgs, TResult, TContext>, 'requires'> & InterceptorFactory<TArgs, TResult, TContext> & {
770
941
  /** Phantom brand — declares the context type this interceptor provides. */'~context': TProvides; /** Like `.requires()` on `PadroneInterceptorFn` but preserves the `'~context'` brand. */
771
942
  requires: <TRequires>() => PadroneContextInterceptor<TProvides, TArgs, TResult, TContext> & InterceptorRequiresBrand<TRequires>;
772
943
  };
@@ -1119,7 +1290,13 @@ type PadroneBuilderMethods<TProgramName extends string, TName extends string, TP
1119
1290
  arguments: <TNewArgs extends PadroneSchema = PadroneSchema<void>, TMeta extends GetArgsMeta<TNewArgs> = GetArgsMeta<TNewArgs>>(schema?: TNewArgs | ((parentSchema: TParentArgs) => TNewArgs), meta?: TMeta) => BuilderOrProgram<TReturn, TProgramName, TName, TParentName, TNewArgs, TRes, TCommands, TParentArgs, OrAsyncMeta<OrAsync<TAsync, TNewArgs>, TMeta>, TContext, TContextProvided>; /** Set the handler function that runs when this command is executed. @category Builder */
1120
1291
  action: <TNewRes>(handler?: (args: StandardSchemaV1.InferOutput<TArgs>, ctx: PadroneActionContext<TContext & TContextProvided>, base: (args: StandardSchemaV1.InferOutput<TArgs>, ctx: PadroneActionContext<TContext & TContextProvided>) => TRes) => TNewRes) => BuilderOrProgram<TReturn, TProgramName, TName, TParentName, TArgs, TNewRes, TCommands, TParentArgs, TAsync, TContext, TContextProvided>; /** Wrap an external CLI tool, delegating execution to a shell command. @category Builder */
1121
1292
  wrap: <TWrapArgs extends PadroneSchema = TArgs>(config: WrapConfig<TArgs, TWrapArgs>) => BuilderOrProgram<TReturn, TProgramName, TName, TParentName, TArgs, Promise<WrapResult>, TCommands, TParentArgs, TAsync, TContext, TContextProvided>; /** Add or override a subcommand. Pass a builder function to define its schema, action, and nested commands. @category Builder */
1122
- command: <TNameNested extends string, TAliases extends string[] = [], TBuilder extends CommandTypesBase = DefaultCommandBuilder<TProgramName, TNameNested, FullCommandName<TName, TParentName>, TArgs, TCommands, TContext & TContextProvided>>(name: TNameNested | readonly [TNameNested, ...TAliases], builderFn?: (builder: InitialCommandBuilder<TProgramName, TNameNested, FullCommandName<TName, TParentName>, TArgs, TCommands, TContext & TContextProvided>) => TBuilder) => BuilderOrProgram<TReturn, TProgramName, TName, TParentName, TArgs, TRes, TCommands extends [] ? [WithAliases<TBuilder['~types']['command'], TAliases>] : AnyPadroneCommand[] extends TCommands ? [WithAliases<TBuilder['~types']['command'], TAliases>] : ReplaceOrAppendCommand<TCommands, TNameNested, WithAliases<TBuilder['~types']['command'], ResolvedAliases<TCommands, TNameNested, TAliases>>>, TParentArgs, TAsync, TContext, TContextProvided>; /** Mount an existing program as a subcommand, optionally transforming the context. @category Builder */
1293
+ command: {
1294
+ <TNameNested extends string, TAliases extends string[] = [], TBuilder extends CommandTypesBase = DefaultCommandBuilder<TProgramName, TNameNested, FullCommandName<TName, TParentName>, TArgs, TCommands, TContext & TContextProvided>>(name: TNameNested | readonly [TNameNested, ...TAliases], builderFn?: (builder: InitialCommandBuilder<TProgramName, TNameNested, FullCommandName<TName, TParentName>, TArgs, TCommands, TContext & TContextProvided>) => TBuilder): BuilderOrProgram<TReturn, TProgramName, TName, TParentName, TArgs, TRes, TCommands extends [] ? [WithAliases<TBuilder['~types']['command'], TAliases>] : AnyPadroneCommand[] extends TCommands ? [WithAliases<TBuilder['~types']['command'], TAliases>] : ReplaceOrAppendCommand<TCommands, TNameNested, WithAliases<TBuilder['~types']['command'], ResolvedAliases<TCommands, TNameNested, TAliases>>>, TParentArgs, TAsync, TContext, TContextProvided>;
1295
+ <TNameNested extends string, TAliases extends string[] = [], TBuilder extends CommandTypesBase = CommandTypesBase, TReq = unknown>(name: TNameNested | readonly [TNameNested, ...TAliases], builderFn: ((builder: any) => TBuilder) & {
1296
+ '~contextRequires': (ctx: TReq) => void;
1297
+ }): TContext & TContextProvided extends TReq ? BuilderOrProgram<TReturn, TProgramName, TName, TParentName, TArgs, TRes, TCommands extends [] ? [WithAliases<TBuilder['~types']['command'], TAliases>] : AnyPadroneCommand[] extends TCommands ? [WithAliases<TBuilder['~types']['command'], TAliases>] : ReplaceOrAppendCommand<TCommands, TNameNested, WithAliases<TBuilder['~types']['command'], ResolvedAliases<TCommands, TNameNested, TAliases>>>, TParentArgs, TAsync, TContext, TContextProvided> : DefineCommandRequiresError;
1298
+ <TNameNested extends string, TAliases extends string[] = [], TBuilder extends CommandTypesBase = CommandTypesBase>(name: TNameNested | readonly [TNameNested, ...TAliases], builderFn?: (builder: any) => TBuilder): BuilderOrProgram<TReturn, TProgramName, TName, TParentName, TArgs, TRes, TCommands extends [] ? [WithAliases<TBuilder['~types']['command'], TAliases>] : AnyPadroneCommand[] extends TCommands ? [WithAliases<TBuilder['~types']['command'], TAliases>] : ReplaceOrAppendCommand<TCommands, TNameNested, WithAliases<TBuilder['~types']['command'], ResolvedAliases<TCommands, TNameNested, TAliases>>>, TParentArgs, TAsync, TContext, TContextProvided>;
1299
+ }; /** Mount an existing program as a subcommand, optionally transforming the context. @category Builder */
1123
1300
  mount: {
1124
1301
  <TNameNested extends string, TAliases extends string[] = [], TProgram extends CommandTypesBase = CommandTypesBase>(name: TNameNested | readonly [TNameNested, ...TAliases], program: TProgram): BuilderOrProgram<TReturn, TProgramName, TName, TParentName, TArgs, TRes, TCommands extends [] ? [WithAliases<PadroneCommand<TNameNested, FullCommandName<TName, TParentName>, TProgram['~types']['command']['~types']['argsSchema'], TProgram['~types']['command']['~types']['result'], RepathCommands<TProgram['~types']['command']['~types']['commands'], FullCommandName<TNameNested, FullCommandName<TName, TParentName>>>, [], TProgram['~types']['command']['~types']['async'], TContext & TContextProvided>, TAliases>] : AnyPadroneCommand[] extends TCommands ? [WithAliases<PadroneCommand<TNameNested, FullCommandName<TName, TParentName>, TProgram['~types']['command']['~types']['argsSchema'], TProgram['~types']['command']['~types']['result'], RepathCommands<TProgram['~types']['command']['~types']['commands'], FullCommandName<TNameNested, FullCommandName<TName, TParentName>>>, [], TProgram['~types']['command']['~types']['async'], TContext & TContextProvided>, TAliases>] : ReplaceOrAppendCommand<TCommands, TNameNested, WithAliases<PadroneCommand<TNameNested, FullCommandName<TName, TParentName>, TProgram['~types']['command']['~types']['argsSchema'], TProgram['~types']['command']['~types']['result'], RepathCommands<TProgram['~types']['command']['~types']['commands'], FullCommandName<TNameNested, FullCommandName<TName, TParentName>>>, [], TProgram['~types']['command']['~types']['async'], TContext & TContextProvided>, ResolvedAliases<TCommands, TNameNested, TAliases>>>, TParentArgs, TAsync, TContext, TContextProvided>;
1125
1302
  <TNameNested extends string, TAliases extends string[] = [], TProgram extends CommandTypesBase = CommandTypesBase, TNewContext = unknown>(name: TNameNested | readonly [TNameNested, ...TAliases], program: TProgram, options: MountOptions<TContext & TContextProvided, TNewContext>): BuilderOrProgram<TReturn, TProgramName, TName, TParentName, TArgs, TRes, TCommands extends [] ? [WithAliases<PadroneCommand<TNameNested, FullCommandName<TName, TParentName>, TProgram['~types']['command']['~types']['argsSchema'], TProgram['~types']['command']['~types']['result'], RepathCommands<TProgram['~types']['command']['~types']['commands'], FullCommandName<TNameNested, FullCommandName<TName, TParentName>>>, [], TProgram['~types']['command']['~types']['async'], TNewContext>, TAliases>] : AnyPadroneCommand[] extends TCommands ? [WithAliases<PadroneCommand<TNameNested, FullCommandName<TName, TParentName>, TProgram['~types']['command']['~types']['argsSchema'], TProgram['~types']['command']['~types']['result'], RepathCommands<TProgram['~types']['command']['~types']['commands'], FullCommandName<TNameNested, FullCommandName<TName, TParentName>>>, [], TProgram['~types']['command']['~types']['async'], TNewContext>, TAliases>] : ReplaceOrAppendCommand<TCommands, TNameNested, WithAliases<PadroneCommand<TNameNested, FullCommandName<TName, TParentName>, TProgram['~types']['command']['~types']['argsSchema'], TProgram['~types']['command']['~types']['result'], RepathCommands<TProgram['~types']['command']['~types']['commands'], FullCommandName<TNameNested, FullCommandName<TName, TParentName>>>, [], TProgram['~types']['command']['~types']['async'], TNewContext>, ResolvedAliases<TCommands, TNameNested, TAliases>>>, TParentArgs, TAsync, TContext, TContextProvided>;
@@ -1172,6 +1349,28 @@ type AnyPadroneProgram = PadroneProgram<string, string, string, any, any, [...An
1172
1349
  * ```
1173
1350
  */
1174
1351
  type PadroneExtension<TIn extends CommandTypesBase = CommandTypesBase, TOut extends CommandTypesBase = TIn> = (builder: TIn) => TOut;
1352
+ /**
1353
+ * Default context type for commands defined with `defineCommand()`.
1354
+ * Includes optional context properties provided by common extensions (logger, tracing, progress).
1355
+ *
1356
+ * Override globally via module augmentation to add your application's context:
1357
+ * ```ts
1358
+ * declare module 'padrone' {
1359
+ * interface DefineCommandContext {
1360
+ * db: Database;
1361
+ * }
1362
+ * }
1363
+ * ```
1364
+ */
1365
+ interface DefineCommandContext {
1366
+ logger?: PadroneLogger;
1367
+ tracing?: PadroneTracer;
1368
+ progress?: PadroneProgressIndicator;
1369
+ }
1370
+ /** Error brand returned by `.command()` when a `defineCommand.requires()` context requirement is not satisfied. */
1371
+ type DefineCommandRequiresError = {
1372
+ readonly '~error': 'Required context not satisfied. Ensure required interceptors are registered on the program.';
1373
+ };
1175
1374
  /**
1176
1375
  * Type for a command builder callback used with `.command()`.
1177
1376
  * Use this when defining commands in separate files where full return type inference isn't needed.
@@ -1189,8 +1388,25 @@ type PadroneExtension<TIn extends CommandTypesBase = CommandTypesBase, TOut exte
1189
1388
  * createPadrone('test').command('my-command', myCommand)
1190
1389
  * ```
1191
1390
  */
1192
- type DefineCommand<TContext = unknown, TParentArgs extends PadroneSchema = PadroneSchema> = (builder: PadroneBuilder<string, string, string, PadroneSchema<void>, void, [], TParentArgs, false, TContext>) => CommandTypesBase;
1391
+ type DefineCommand<TContext = unknown, TParentArgs extends PadroneSchema = PadroneSchema> = (builder: PadroneBuilder<string, string, string, PadroneSchema<void>, void, [], TParentArgs, false, TContext, DefineCommandContext>) => CommandTypesBase;
1392
+ /**
1393
+ * Builder returned by `defineCommand()` (no-arg form).
1394
+ * Call `.requires<T>()` to declare context dependencies, then `.command()` to provide the builder callback.
1395
+ *
1396
+ * @example
1397
+ * ```ts
1398
+ * const adminCommand = defineCommand()
1399
+ * .requires<{ adminDb: AdminDB }>()
1400
+ * .define((c) => c.action((_args, ctx) => ctx.context.adminDb.query(...)));
1401
+ * ```
1402
+ */
1403
+ type DefineCommandBuilder<TContextProvided = DefineCommandContext, TBrand = unknown> = {
1404
+ /** Declare context types this command requires. Purely type-level — no runtime effect. */requires: <TRequires>() => DefineCommandBuilder<DefineCommandContext & TRequires, {
1405
+ '~contextRequires': (ctx: TRequires) => void;
1406
+ }>; /** Provide the command builder callback. */
1407
+ define: <TContext = unknown, TOut extends CommandTypesBase = CommandTypesBase>(fn: (builder: PadroneBuilder<string, string, string, PadroneSchema<void>, void, [], any, false, TContext, TContextProvided>) => TOut) => typeof fn & TBrand;
1408
+ };
1193
1409
  type DefaultArgs = Record<string, unknown> | void;
1194
1410
  //#endregion
1195
- export { PadroneProgressIndicator as $, InterceptorShutdownContext as A, WithCommand as B, InterceptorExecuteContext as C, InterceptorParseContext as D, InterceptorMeta as E, PadroneInterceptor as F, WrapResult as G, AsyncPadroneSchema as H, PadroneInterceptorFn as I, InteractiveMode as J, PadroneServePreferences as K, Drained as L, InterceptorValidateContext as M, InterceptorValidateResult as N, InterceptorParseResult as O, PadroneContextInterceptor as P, PadroneBarConfig as Q, PickCommandByName as R, InterceptorErrorResult as S, InterceptorFactory as T, PadroneSchema as U, WithInterceptor as V, WrapConfig as W, PadroneBarAnimation as X, InteractivePromptConfig as Y, PadroneBarChar as Z, ExtractInterceptorContext as _, PadroneExtension as a, PadroneSpinnerConfig as at, InterceptorDefBuilder as b, PadroneDrainResult as c, AnyPadroneCommand as d, PadroneProgressOptions as et, CommandTypesBase as f, PadroneProgramMeta as g, PadroneCommand as h, PadroneBuilder as i, PadroneSignal as it, InterceptorStartContext as j, InterceptorPhases as k, PadroneParseResult as l, PadroneActionContext as m, AnyPadroneProgram as n, PadroneProgressUpdate as nt, PadroneProgram as o, PadroneSpinnerPreset as ot, GetArgsMeta as p, PadroneMcpPreferences as q, DefineCommand as r, PadroneRuntime as rt, PadroneCommandResult as s, REPL_SIGINT as st, AnyPadroneBuilder as t, PadroneProgressShow as tt, PadroneReplPreferences as u, ExtractInterceptorRequires as v, InterceptorExecuteResult as w, InterceptorErrorContext as x, InterceptorBaseContext as y, PossibleCommands as z };
1196
- //# sourceMappingURL=index-D6-7dz0l.d.mts.map
1411
+ export { PadroneLoggerConfig as $, InterceptorParseResult as A, WrapConfig as B, InterceptorErrorContext as C, REPL_SIGINT as Ct, InterceptorFactory as D, InterceptorExecuteResult as E, InterceptorValidateResult as F, OtelTracer as G, PadroneServePreferences as H, PadroneContextInterceptor as I, PadroneTracingConfig as J, OtelTracerProvider as K, PadroneInterceptor as L, InterceptorShutdownContext as M, InterceptorStartContext as N, InterceptorMeta as O, InterceptorValidateContext as P, PadroneLogger as Q, PadroneInterceptorFn as R, InterceptorDefBuilder as S, PadroneSpinnerPreset as St, InterceptorExecuteContext as T, PadroneMcpPreferences as U, WrapResult as V, OtelSpan as W, padroneTracing as X, WithTracing as Y, PadroneLogLevel as Z, PadroneCommand as _, PadroneProgressShow as _t, DefineCommandContext as a, WithAsync as at, ExtractInterceptorRequires as b, PadroneSignal as bt, PadroneProgram as c, AsyncPadroneSchema as ct, PadroneParseResult as d, InteractivePromptConfig as dt, WithLogger as et, PadroneReplPreferences as f, PadroneBarAnimation as ft, PadroneActionContext as g, PadroneProgressOptions as gt, GetArgsMeta as h, PadroneProgressIndicator as ht, DefineCommandBuilder as i, PossibleCommands as it, InterceptorPhases as j, InterceptorParseContext as k, PadroneCommandResult as l, PadroneSchema as lt, CommandTypesBase as m, PadroneBarConfig as mt, AnyPadroneProgram as n, Drained as nt, PadroneBuilder as o, WithCommand as ot, AnyPadroneCommand as p, PadroneBarChar as pt, PadroneTracer as q, DefineCommand as r, PickCommandByName as rt, PadroneExtension as s, WithInterceptor as st, AnyPadroneBuilder as t, padroneLogger as tt, PadroneDrainResult as u, InteractiveMode as ut, PadroneProgramMeta as v, PadroneProgressUpdate as vt, InterceptorErrorResult as w, InterceptorBaseContext as x, PadroneSpinnerConfig as xt, ExtractInterceptorContext as y, PadroneRuntime as yt, RegisteredInterceptor as z };
1412
+ //# sourceMappingURL=index-C2n3k4e8.d.mts.map