windmill-cli 0.0.1
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.
- package/LICENSE +22 -0
- package/README.md +110 -0
- package/esm/_dnt.polyfills.d.ts +19 -0
- package/esm/_dnt.polyfills.d.ts.map +1 -0
- package/esm/_dnt.polyfills.js +124 -0
- package/esm/_dnt.shims.d.ts +14 -0
- package/esm/_dnt.shims.d.ts.map +1 -0
- package/esm/_dnt.shims.js +69 -0
- package/esm/apps.d.ts +16 -0
- package/esm/apps.d.ts.map +1 -0
- package/esm/apps.js +123 -0
- package/esm/bootstrap/common.d.ts +35 -0
- package/esm/bootstrap/common.d.ts.map +1 -0
- package/esm/bootstrap/common.js +1 -0
- package/esm/bootstrap/flow_bootstrap.d.ts +20 -0
- package/esm/bootstrap/flow_bootstrap.d.ts.map +1 -0
- package/esm/bootstrap/flow_bootstrap.js +17 -0
- package/esm/bootstrap/script_bootstrap.d.ts +34 -0
- package/esm/bootstrap/script_bootstrap.d.ts.map +1 -0
- package/esm/bootstrap/script_bootstrap.js +57 -0
- package/esm/codebase.d.ts +6 -0
- package/esm/codebase.d.ts.map +1 -0
- package/esm/codebase.js +18 -0
- package/esm/conf.d.ts +41 -0
- package/esm/conf.d.ts.map +1 -0
- package/esm/conf.js +19 -0
- package/esm/context.d.ts +15 -0
- package/esm/context.d.ts.map +1 -0
- package/esm/context.js +97 -0
- package/esm/deps/jsr.io/@cliffy/ansi/1.0.0-rc.5/ansi_escapes.d.ts +135 -0
- package/esm/deps/jsr.io/@cliffy/ansi/1.0.0-rc.5/ansi_escapes.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/ansi/1.0.0-rc.5/ansi_escapes.js +218 -0
- package/esm/deps/jsr.io/@cliffy/ansi/1.0.0-rc.5/chain.d.ts +137 -0
- package/esm/deps/jsr.io/@cliffy/ansi/1.0.0-rc.5/chain.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/ansi/1.0.0-rc.5/chain.js +1 -0
- package/esm/deps/jsr.io/@cliffy/ansi/1.0.0-rc.5/colors.d.ts +39 -0
- package/esm/deps/jsr.io/@cliffy/ansi/1.0.0-rc.5/colors.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/ansi/1.0.0-rc.5/colors.js +48 -0
- package/esm/deps/jsr.io/@cliffy/ansi/1.0.0-rc.5/cursor_position.d.ts +28 -0
- package/esm/deps/jsr.io/@cliffy/ansi/1.0.0-rc.5/cursor_position.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/ansi/1.0.0-rc.5/cursor_position.js +31 -0
- package/esm/deps/jsr.io/@cliffy/ansi/1.0.0-rc.5/tty.d.ts +37 -0
- package/esm/deps/jsr.io/@cliffy/ansi/1.0.0-rc.5/tty.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/ansi/1.0.0-rc.5/tty.js +61 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/_argument_types.d.ts +157 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/_argument_types.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/_argument_types.js +1 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/_errors.d.ts +77 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/_errors.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/_errors.js +155 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/_spread.d.ts +16 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/_spread.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/_spread.js +1 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/_type_utils.d.ts +9 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/_type_utils.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/_type_utils.js +1 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/_utils.d.ts +37 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/_utils.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/_utils.js +125 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/command.d.ts +815 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/command.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/command.js +1789 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/completions/_bash_completions_generator.d.ts +19 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/completions/_bash_completions_generator.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/completions/_bash_completions_generator.js +211 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/completions/_fish_completions_generator.d.ts +16 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/completions/_fish_completions_generator.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/completions/_fish_completions_generator.js +151 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/completions/_zsh_completions_generator.d.ts +23 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/completions/_zsh_completions_generator.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/completions/_zsh_completions_generator.js +314 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/completions/bash.d.ts +9 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/completions/bash.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/completions/bash.js +39 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/completions/complete.d.ts +9 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/completions/complete.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/completions/complete.js +32 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/completions/completions_command.d.ts +9 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/completions/completions_command.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/completions/completions_command.js +47 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/completions/fish.d.ts +9 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/completions/fish.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/completions/fish.js +39 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/completions/mod.d.ts +5 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/completions/mod.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/completions/mod.js +4 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/completions/zsh.d.ts +9 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/completions/zsh.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/completions/zsh.js +39 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/deprecated.d.ts +46 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/deprecated.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/deprecated.js +2 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/help/_help_generator.d.ts +28 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/help/_help_generator.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/help/_help_generator.js +320 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/mod.d.ts +15 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/mod.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/mod.js +13 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/type.d.ts +45 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/type.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/type.js +27 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/types/action_list.d.ts +10 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/types/action_list.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/types/action_list.js +20 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/types/boolean.d.ts +10 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/types/boolean.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/types/boolean.js +13 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/types/child_command.d.ts +10 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/types/child_command.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/types/child_command.js +27 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/types/command.d.ts +8 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/types/command.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/types/command.js +9 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/types/enum.d.ts +11 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/types/enum.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/types/enum.js +29 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/types/file.d.ts +6 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/types/file.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/types/file.js +12 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/types/integer.d.ts +8 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/types/integer.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/types/integer.js +9 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/types/number.d.ts +8 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/types/number.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/types/number.js +9 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/types/string.d.ts +8 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/types/string.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/types/string.js +9 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/types.d.ts +119 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/types.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/types.js +2 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/upgrade/_check_version.d.ts +4 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/upgrade/_check_version.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/upgrade/_check_version.js +21 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/upgrade/get_runtime.d.ts +11 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/upgrade/get_runtime.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/upgrade/get_runtime.js +21 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/upgrade/logger.d.ts +13 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/upgrade/logger.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/upgrade/logger.js +15 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/upgrade/mod.d.ts +3 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/upgrade/mod.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/upgrade/mod.js +2 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/upgrade/provider/npm.d.ts +19 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/upgrade/provider/npm.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/upgrade/provider/npm.js +61 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/upgrade/provider.d.ts +66 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/upgrade/provider.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/upgrade/provider.js +118 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/upgrade/runtime/bun_runtime.d.ts +6 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/upgrade/runtime/bun_runtime.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/upgrade/runtime/bun_runtime.js +21 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/upgrade/runtime/deno_runtime.d.ts +14 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/upgrade/runtime/deno_runtime.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/upgrade/runtime/deno_runtime.js +34 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/upgrade/runtime/node_runtime.d.ts +7 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/upgrade/runtime/node_runtime.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/upgrade/runtime/node_runtime.js +29 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/upgrade/runtime.d.ts +12 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/upgrade/runtime.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/upgrade/runtime.js +3 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/upgrade/spinner.d.ts +156 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/upgrade/spinner.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/upgrade/spinner.js +198 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/upgrade/upgrade.d.ts +27 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/upgrade/upgrade.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/upgrade/upgrade.js +42 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/upgrade/upgrade_command.d.ts +52 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/upgrade/upgrade_command.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/command/1.0.0-rc.5/upgrade/upgrade_command.js +133 -0
- package/esm/deps/jsr.io/@cliffy/flags/1.0.0-rc.5/_errors.d.ts +61 -0
- package/esm/deps/jsr.io/@cliffy/flags/1.0.0-rc.5/_errors.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/flags/1.0.0-rc.5/_errors.js +117 -0
- package/esm/deps/jsr.io/@cliffy/flags/1.0.0-rc.5/_utils.d.ts +17 -0
- package/esm/deps/jsr.io/@cliffy/flags/1.0.0-rc.5/_utils.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/flags/1.0.0-rc.5/_utils.js +89 -0
- package/esm/deps/jsr.io/@cliffy/flags/1.0.0-rc.5/_validate_flags.d.ts +11 -0
- package/esm/deps/jsr.io/@cliffy/flags/1.0.0-rc.5/_validate_flags.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/flags/1.0.0-rc.5/_validate_flags.js +155 -0
- package/esm/deps/jsr.io/@cliffy/flags/1.0.0-rc.5/deprecated.d.ts +25 -0
- package/esm/deps/jsr.io/@cliffy/flags/1.0.0-rc.5/deprecated.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/flags/1.0.0-rc.5/deprecated.js +9 -0
- package/esm/deps/jsr.io/@cliffy/flags/1.0.0-rc.5/flags.d.ts +35 -0
- package/esm/deps/jsr.io/@cliffy/flags/1.0.0-rc.5/flags.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/flags/1.0.0-rc.5/flags.js +401 -0
- package/esm/deps/jsr.io/@cliffy/flags/1.0.0-rc.5/mod.d.ts +9 -0
- package/esm/deps/jsr.io/@cliffy/flags/1.0.0-rc.5/mod.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/flags/1.0.0-rc.5/mod.js +7 -0
- package/esm/deps/jsr.io/@cliffy/flags/1.0.0-rc.5/types/boolean.d.ts +4 -0
- package/esm/deps/jsr.io/@cliffy/flags/1.0.0-rc.5/types/boolean.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/flags/1.0.0-rc.5/types/boolean.js +11 -0
- package/esm/deps/jsr.io/@cliffy/flags/1.0.0-rc.5/types/integer.d.ts +4 -0
- package/esm/deps/jsr.io/@cliffy/flags/1.0.0-rc.5/types/integer.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/flags/1.0.0-rc.5/types/integer.js +9 -0
- package/esm/deps/jsr.io/@cliffy/flags/1.0.0-rc.5/types/number.d.ts +4 -0
- package/esm/deps/jsr.io/@cliffy/flags/1.0.0-rc.5/types/number.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/flags/1.0.0-rc.5/types/number.js +9 -0
- package/esm/deps/jsr.io/@cliffy/flags/1.0.0-rc.5/types/string.d.ts +4 -0
- package/esm/deps/jsr.io/@cliffy/flags/1.0.0-rc.5/types/string.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/flags/1.0.0-rc.5/types/string.js +4 -0
- package/esm/deps/jsr.io/@cliffy/flags/1.0.0-rc.5/types.d.ts +137 -0
- package/esm/deps/jsr.io/@cliffy/flags/1.0.0-rc.5/types.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/flags/1.0.0-rc.5/types.js +1 -0
- package/esm/deps/jsr.io/@cliffy/internal/1.0.0-rc.5/runtime/exit.d.ts +2 -0
- package/esm/deps/jsr.io/@cliffy/internal/1.0.0-rc.5/runtime/exit.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/internal/1.0.0-rc.5/runtime/exit.js +16 -0
- package/esm/deps/jsr.io/@cliffy/internal/1.0.0-rc.5/runtime/get_args.d.ts +2 -0
- package/esm/deps/jsr.io/@cliffy/internal/1.0.0-rc.5/runtime/get_args.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/internal/1.0.0-rc.5/runtime/get_args.js +11 -0
- package/esm/deps/jsr.io/@cliffy/internal/1.0.0-rc.5/runtime/get_columns.d.ts +2 -0
- package/esm/deps/jsr.io/@cliffy/internal/1.0.0-rc.5/runtime/get_columns.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/internal/1.0.0-rc.5/runtime/get_columns.js +23 -0
- package/esm/deps/jsr.io/@cliffy/internal/1.0.0-rc.5/runtime/get_env.d.ts +2 -0
- package/esm/deps/jsr.io/@cliffy/internal/1.0.0-rc.5/runtime/get_env.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/internal/1.0.0-rc.5/runtime/get_env.js +18 -0
- package/esm/deps/jsr.io/@cliffy/internal/1.0.0-rc.5/runtime/get_os.d.ts +2 -0
- package/esm/deps/jsr.io/@cliffy/internal/1.0.0-rc.5/runtime/get_os.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/internal/1.0.0-rc.5/runtime/get_os.js +19 -0
- package/esm/deps/jsr.io/@cliffy/internal/1.0.0-rc.5/runtime/inspect.d.ts +2 -0
- package/esm/deps/jsr.io/@cliffy/internal/1.0.0-rc.5/runtime/inspect.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/internal/1.0.0-rc.5/runtime/inspect.js +11 -0
- package/esm/deps/jsr.io/@cliffy/internal/1.0.0-rc.5/runtime/is_directory.d.ts +8 -0
- package/esm/deps/jsr.io/@cliffy/internal/1.0.0-rc.5/runtime/is_directory.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/internal/1.0.0-rc.5/runtime/is_directory.js +16 -0
- package/esm/deps/jsr.io/@cliffy/internal/1.0.0-rc.5/runtime/is_terminal.d.ts +2 -0
- package/esm/deps/jsr.io/@cliffy/internal/1.0.0-rc.5/runtime/is_terminal.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/internal/1.0.0-rc.5/runtime/is_terminal.js +19 -0
- package/esm/deps/jsr.io/@cliffy/internal/1.0.0-rc.5/runtime/no_color.d.ts +2 -0
- package/esm/deps/jsr.io/@cliffy/internal/1.0.0-rc.5/runtime/no_color.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/internal/1.0.0-rc.5/runtime/no_color.js +18 -0
- package/esm/deps/jsr.io/@cliffy/internal/1.0.0-rc.5/runtime/read.d.ts +2 -0
- package/esm/deps/jsr.io/@cliffy/internal/1.0.0-rc.5/runtime/read.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/internal/1.0.0-rc.5/runtime/read.js +36 -0
- package/esm/deps/jsr.io/@cliffy/internal/1.0.0-rc.5/runtime/read_dir.d.ts +4 -0
- package/esm/deps/jsr.io/@cliffy/internal/1.0.0-rc.5/runtime/read_dir.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/internal/1.0.0-rc.5/runtime/read_dir.js +23 -0
- package/esm/deps/jsr.io/@cliffy/internal/1.0.0-rc.5/runtime/read_sync.d.ts +8 -0
- package/esm/deps/jsr.io/@cliffy/internal/1.0.0-rc.5/runtime/read_sync.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/internal/1.0.0-rc.5/runtime/read_sync.js +28 -0
- package/esm/deps/jsr.io/@cliffy/internal/1.0.0-rc.5/runtime/set_raw.d.ts +4 -0
- package/esm/deps/jsr.io/@cliffy/internal/1.0.0-rc.5/runtime/set_raw.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/internal/1.0.0-rc.5/runtime/set_raw.js +21 -0
- package/esm/deps/jsr.io/@cliffy/internal/1.0.0-rc.5/runtime/stat.d.ts +4 -0
- package/esm/deps/jsr.io/@cliffy/internal/1.0.0-rc.5/runtime/stat.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/internal/1.0.0-rc.5/runtime/stat.js +21 -0
- package/esm/deps/jsr.io/@cliffy/internal/1.0.0-rc.5/runtime/write_sync.d.ts +2 -0
- package/esm/deps/jsr.io/@cliffy/internal/1.0.0-rc.5/runtime/write_sync.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/internal/1.0.0-rc.5/runtime/write_sync.js +21 -0
- package/esm/deps/jsr.io/@cliffy/keycode/1.0.0-rc.5/_key_codes.d.ts +9 -0
- package/esm/deps/jsr.io/@cliffy/keycode/1.0.0-rc.5/_key_codes.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/keycode/1.0.0-rc.5/_key_codes.js +103 -0
- package/esm/deps/jsr.io/@cliffy/keycode/1.0.0-rc.5/key_code.d.ts +37 -0
- package/esm/deps/jsr.io/@cliffy/keycode/1.0.0-rc.5/key_code.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/keycode/1.0.0-rc.5/key_code.js +235 -0
- package/esm/deps/jsr.io/@cliffy/keycode/1.0.0-rc.5/mod.d.ts +2 -0
- package/esm/deps/jsr.io/@cliffy/keycode/1.0.0-rc.5/mod.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/keycode/1.0.0-rc.5/mod.js +1 -0
- package/esm/deps/jsr.io/@cliffy/prompt/1.0.0-rc.5/_figures.d.ts +34 -0
- package/esm/deps/jsr.io/@cliffy/prompt/1.0.0-rc.5/_figures.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/prompt/1.0.0-rc.5/_figures.js +63 -0
- package/esm/deps/jsr.io/@cliffy/prompt/1.0.0-rc.5/_generic_input.d.ts +49 -0
- package/esm/deps/jsr.io/@cliffy/prompt/1.0.0-rc.5/_generic_input.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/prompt/1.0.0-rc.5/_generic_input.js +112 -0
- package/esm/deps/jsr.io/@cliffy/prompt/1.0.0-rc.5/_generic_list.d.ts +190 -0
- package/esm/deps/jsr.io/@cliffy/prompt/1.0.0-rc.5/_generic_list.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/prompt/1.0.0-rc.5/_generic_list.js +519 -0
- package/esm/deps/jsr.io/@cliffy/prompt/1.0.0-rc.5/_generic_prompt.d.ts +142 -0
- package/esm/deps/jsr.io/@cliffy/prompt/1.0.0-rc.5/_generic_prompt.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/prompt/1.0.0-rc.5/_generic_prompt.js +282 -0
- package/esm/deps/jsr.io/@cliffy/prompt/1.0.0-rc.5/_generic_suggestions.d.ts +115 -0
- package/esm/deps/jsr.io/@cliffy/prompt/1.0.0-rc.5/_generic_suggestions.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/prompt/1.0.0-rc.5/_generic_suggestions.js +424 -0
- package/esm/deps/jsr.io/@cliffy/prompt/1.0.0-rc.5/_utils.d.ts +4 -0
- package/esm/deps/jsr.io/@cliffy/prompt/1.0.0-rc.5/_utils.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/prompt/1.0.0-rc.5/_utils.js +5 -0
- package/esm/deps/jsr.io/@cliffy/prompt/1.0.0-rc.5/confirm.d.ts +66 -0
- package/esm/deps/jsr.io/@cliffy/prompt/1.0.0-rc.5/confirm.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/prompt/1.0.0-rc.5/confirm.js +117 -0
- package/esm/deps/jsr.io/@cliffy/prompt/1.0.0-rc.5/input.d.ts +64 -0
- package/esm/deps/jsr.io/@cliffy/prompt/1.0.0-rc.5/input.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/prompt/1.0.0-rc.5/input.js +88 -0
- package/esm/deps/jsr.io/@cliffy/prompt/1.0.0-rc.5/secret.d.ts +74 -0
- package/esm/deps/jsr.io/@cliffy/prompt/1.0.0-rc.5/secret.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/prompt/1.0.0-rc.5/secret.js +96 -0
- package/esm/deps/jsr.io/@cliffy/prompt/1.0.0-rc.5/select.d.ts +142 -0
- package/esm/deps/jsr.io/@cliffy/prompt/1.0.0-rc.5/select.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/prompt/1.0.0-rc.5/select.js +184 -0
- package/esm/deps/jsr.io/@cliffy/table/1.0.0-rc.5/_layout.d.ts +104 -0
- package/esm/deps/jsr.io/@cliffy/table/1.0.0-rc.5/_layout.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/table/1.0.0-rc.5/_layout.js +546 -0
- package/esm/deps/jsr.io/@cliffy/table/1.0.0-rc.5/_utils.d.ts +29 -0
- package/esm/deps/jsr.io/@cliffy/table/1.0.0-rc.5/_utils.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/table/1.0.0-rc.5/_utils.js +71 -0
- package/esm/deps/jsr.io/@cliffy/table/1.0.0-rc.5/border.d.ts +23 -0
- package/esm/deps/jsr.io/@cliffy/table/1.0.0-rc.5/border.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/table/1.0.0-rc.5/border.js +18 -0
- package/esm/deps/jsr.io/@cliffy/table/1.0.0-rc.5/cell.d.ts +157 -0
- package/esm/deps/jsr.io/@cliffy/table/1.0.0-rc.5/cell.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/table/1.0.0-rc.5/cell.js +199 -0
- package/esm/deps/jsr.io/@cliffy/table/1.0.0-rc.5/column.d.ts +62 -0
- package/esm/deps/jsr.io/@cliffy/table/1.0.0-rc.5/column.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/table/1.0.0-rc.5/column.js +85 -0
- package/esm/deps/jsr.io/@cliffy/table/1.0.0-rc.5/consume_words.d.ts +30 -0
- package/esm/deps/jsr.io/@cliffy/table/1.0.0-rc.5/consume_words.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/table/1.0.0-rc.5/consume_words.js +64 -0
- package/esm/deps/jsr.io/@cliffy/table/1.0.0-rc.5/mod.d.ts +7 -0
- package/esm/deps/jsr.io/@cliffy/table/1.0.0-rc.5/mod.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/table/1.0.0-rc.5/mod.js +6 -0
- package/esm/deps/jsr.io/@cliffy/table/1.0.0-rc.5/row.d.ts +71 -0
- package/esm/deps/jsr.io/@cliffy/table/1.0.0-rc.5/row.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/table/1.0.0-rc.5/row.js +90 -0
- package/esm/deps/jsr.io/@cliffy/table/1.0.0-rc.5/table.d.ts +192 -0
- package/esm/deps/jsr.io/@cliffy/table/1.0.0-rc.5/table.d.ts.map +1 -0
- package/esm/deps/jsr.io/@cliffy/table/1.0.0-rc.5/table.js +304 -0
- package/esm/deps/jsr.io/@std/assert/1.0.0-rc.2/equal.d.ts +17 -0
- package/esm/deps/jsr.io/@std/assert/1.0.0-rc.2/equal.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/assert/1.0.0-rc.2/equal.js +113 -0
- package/esm/deps/jsr.io/@std/bytes/1.0.2/concat.d.ts +19 -0
- package/esm/deps/jsr.io/@std/bytes/1.0.2/concat.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/bytes/1.0.2/concat.js +32 -0
- package/esm/deps/jsr.io/@std/cli/1.0.0-rc.2/_data.d.ts +9 -0
- package/esm/deps/jsr.io/@std/cli/1.0.0-rc.2/_data.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/cli/1.0.0-rc.2/_data.js +17 -0
- package/esm/deps/jsr.io/@std/cli/1.0.0-rc.2/_run_length.d.ts +9 -0
- package/esm/deps/jsr.io/@std/cli/1.0.0-rc.2/_run_length.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/cli/1.0.0-rc.2/_run_length.js +34 -0
- package/esm/deps/jsr.io/@std/cli/1.0.0-rc.2/unicode_width.d.ts +40 -0
- package/esm/deps/jsr.io/@std/cli/1.0.0-rc.2/unicode_width.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/cli/1.0.0-rc.2/unicode_width.js +74 -0
- package/esm/deps/jsr.io/@std/encoding/1.0.0-rc.2/_validate_binary_like.d.ts +2 -0
- package/esm/deps/jsr.io/@std/encoding/1.0.0-rc.2/_validate_binary_like.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/encoding/1.0.0-rc.2/_validate_binary_like.js +26 -0
- package/esm/deps/jsr.io/@std/encoding/1.0.0-rc.2/base64.d.ts +38 -0
- package/esm/deps/jsr.io/@std/encoding/1.0.0-rc.2/base64.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/encoding/1.0.0-rc.2/base64.js +163 -0
- package/esm/deps/jsr.io/@std/encoding/1.0.4/_base32_common.d.ts +17 -0
- package/esm/deps/jsr.io/@std/encoding/1.0.4/_base32_common.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/encoding/1.0.4/_base32_common.js +183 -0
- package/esm/deps/jsr.io/@std/encoding/1.0.4/_validate_binary_like.d.ts +2 -0
- package/esm/deps/jsr.io/@std/encoding/1.0.4/_validate_binary_like.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/encoding/1.0.4/_validate_binary_like.js +26 -0
- package/esm/deps/jsr.io/@std/encoding/1.0.4/ascii85.d.ts +59 -0
- package/esm/deps/jsr.io/@std/encoding/1.0.4/ascii85.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/encoding/1.0.4/ascii85.js +152 -0
- package/esm/deps/jsr.io/@std/encoding/1.0.4/base32.d.ts +38 -0
- package/esm/deps/jsr.io/@std/encoding/1.0.4/base32.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/encoding/1.0.4/base32.js +69 -0
- package/esm/deps/jsr.io/@std/encoding/1.0.4/base32_stream.d.ts +48 -0
- package/esm/deps/jsr.io/@std/encoding/1.0.4/base32_stream.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/encoding/1.0.4/base32_stream.js +92 -0
- package/esm/deps/jsr.io/@std/encoding/1.0.4/base32hex.d.ts +42 -0
- package/esm/deps/jsr.io/@std/encoding/1.0.4/base32hex.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/encoding/1.0.4/base32hex.js +77 -0
- package/esm/deps/jsr.io/@std/encoding/1.0.4/base32hex_stream.d.ts +48 -0
- package/esm/deps/jsr.io/@std/encoding/1.0.4/base32hex_stream.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/encoding/1.0.4/base32hex_stream.js +92 -0
- package/esm/deps/jsr.io/@std/encoding/1.0.4/base58.d.ts +38 -0
- package/esm/deps/jsr.io/@std/encoding/1.0.4/base58.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/encoding/1.0.4/base58.js +131 -0
- package/esm/deps/jsr.io/@std/encoding/1.0.4/base64.d.ts +38 -0
- package/esm/deps/jsr.io/@std/encoding/1.0.4/base64.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/encoding/1.0.4/base64.js +163 -0
- package/esm/deps/jsr.io/@std/encoding/1.0.4/base64_stream.d.ts +48 -0
- package/esm/deps/jsr.io/@std/encoding/1.0.4/base64_stream.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/encoding/1.0.4/base64_stream.js +92 -0
- package/esm/deps/jsr.io/@std/encoding/1.0.4/base64url.d.ts +38 -0
- package/esm/deps/jsr.io/@std/encoding/1.0.4/base64url.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/encoding/1.0.4/base64url.js +81 -0
- package/esm/deps/jsr.io/@std/encoding/1.0.4/base64url_stream.d.ts +49 -0
- package/esm/deps/jsr.io/@std/encoding/1.0.4/base64url_stream.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/encoding/1.0.4/base64url_stream.js +93 -0
- package/esm/deps/jsr.io/@std/encoding/1.0.4/hex.d.ts +37 -0
- package/esm/deps/jsr.io/@std/encoding/1.0.4/hex.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/encoding/1.0.4/hex.js +109 -0
- package/esm/deps/jsr.io/@std/encoding/1.0.4/hex_stream.d.ts +48 -0
- package/esm/deps/jsr.io/@std/encoding/1.0.4/hex_stream.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/encoding/1.0.4/hex_stream.js +81 -0
- package/esm/deps/jsr.io/@std/encoding/1.0.4/mod.d.ts +28 -0
- package/esm/deps/jsr.io/@std/encoding/1.0.4/mod.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/encoding/1.0.4/mod.js +28 -0
- package/esm/deps/jsr.io/@std/encoding/1.0.4/varint.d.ts +118 -0
- package/esm/deps/jsr.io/@std/encoding/1.0.4/varint.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/encoding/1.0.4/varint.js +207 -0
- package/esm/deps/jsr.io/@std/fmt/0.225.6/colors.d.ts +716 -0
- package/esm/deps/jsr.io/@std/fmt/0.225.6/colors.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/fmt/0.225.6/colors.js +916 -0
- package/esm/deps/jsr.io/@std/fmt/1.0.2/colors.d.ts +700 -0
- package/esm/deps/jsr.io/@std/fmt/1.0.2/colors.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/fmt/1.0.2/colors.js +903 -0
- package/esm/deps/jsr.io/@std/fs/1.0.3/_create_walk_entry.d.ts +14 -0
- package/esm/deps/jsr.io/@std/fs/1.0.3/_create_walk_entry.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/fs/1.0.3/_create_walk_entry.js +34 -0
- package/esm/deps/jsr.io/@std/fs/1.0.3/_get_file_info_type.d.ts +13 -0
- package/esm/deps/jsr.io/@std/fs/1.0.3/_get_file_info_type.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/fs/1.0.3/_get_file_info_type.js +18 -0
- package/esm/deps/jsr.io/@std/fs/1.0.3/_is_same_path.d.ts +10 -0
- package/esm/deps/jsr.io/@std/fs/1.0.3/_is_same_path.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/fs/1.0.3/_is_same_path.js +17 -0
- package/esm/deps/jsr.io/@std/fs/1.0.3/_is_subdir.d.ts +12 -0
- package/esm/deps/jsr.io/@std/fs/1.0.3/_is_subdir.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/fs/1.0.3/_is_subdir.js +25 -0
- package/esm/deps/jsr.io/@std/fs/1.0.3/_to_path_string.d.ts +9 -0
- package/esm/deps/jsr.io/@std/fs/1.0.3/_to_path_string.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/fs/1.0.3/_to_path_string.js +13 -0
- package/esm/deps/jsr.io/@std/fs/1.0.3/copy.d.ts +117 -0
- package/esm/deps/jsr.io/@std/fs/1.0.3/copy.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/fs/1.0.3/copy.js +313 -0
- package/esm/deps/jsr.io/@std/fs/1.0.3/empty_dir.d.ts +48 -0
- package/esm/deps/jsr.io/@std/fs/1.0.3/empty_dir.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/fs/1.0.3/empty_dir.js +87 -0
- package/esm/deps/jsr.io/@std/fs/1.0.3/ensure_dir.d.ts +49 -0
- package/esm/deps/jsr.io/@std/fs/1.0.3/ensure_dir.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/fs/1.0.3/ensure_dir.js +102 -0
- package/esm/deps/jsr.io/@std/fs/1.0.3/ensure_file.d.ts +47 -0
- package/esm/deps/jsr.io/@std/fs/1.0.3/ensure_file.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/fs/1.0.3/ensure_file.js +90 -0
- package/esm/deps/jsr.io/@std/fs/1.0.3/ensure_link.d.ts +49 -0
- package/esm/deps/jsr.io/@std/fs/1.0.3/ensure_link.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/fs/1.0.3/ensure_link.js +61 -0
- package/esm/deps/jsr.io/@std/fs/1.0.3/ensure_symlink.d.ts +52 -0
- package/esm/deps/jsr.io/@std/fs/1.0.3/ensure_symlink.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/fs/1.0.3/ensure_symlink.js +120 -0
- package/esm/deps/jsr.io/@std/fs/1.0.3/eol.d.ts +52 -0
- package/esm/deps/jsr.io/@std/fs/1.0.3/eol.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/fs/1.0.3/eol.js +64 -0
- package/esm/deps/jsr.io/@std/fs/1.0.3/exists.d.ts +198 -0
- package/esm/deps/jsr.io/@std/fs/1.0.3/exists.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/fs/1.0.3/exists.js +251 -0
- package/esm/deps/jsr.io/@std/fs/1.0.3/expand_glob.d.ts +267 -0
- package/esm/deps/jsr.io/@std/fs/1.0.3/expand_glob.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/fs/1.0.3/expand_glob.js +415 -0
- package/esm/deps/jsr.io/@std/fs/1.0.3/mod.d.ts +29 -0
- package/esm/deps/jsr.io/@std/fs/1.0.3/mod.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/fs/1.0.3/mod.js +29 -0
- package/esm/deps/jsr.io/@std/fs/1.0.3/move.d.ts +86 -0
- package/esm/deps/jsr.io/@std/fs/1.0.3/move.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/fs/1.0.3/move.js +141 -0
- package/esm/deps/jsr.io/@std/fs/1.0.3/walk.d.ts +777 -0
- package/esm/deps/jsr.io/@std/fs/1.0.3/walk.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/fs/1.0.3/walk.js +846 -0
- package/esm/deps/jsr.io/@std/io/0.224.7/_constants.d.ts +3 -0
- package/esm/deps/jsr.io/@std/io/0.224.7/_constants.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/io/0.224.7/_constants.js +4 -0
- package/esm/deps/jsr.io/@std/io/0.224.7/copy.d.ts +25 -0
- package/esm/deps/jsr.io/@std/io/0.224.7/copy.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/io/0.224.7/copy.js +36 -0
- package/esm/deps/jsr.io/@std/io/0.224.7/read_all.d.ts +42 -0
- package/esm/deps/jsr.io/@std/io/0.224.7/read_all.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/io/0.224.7/read_all.js +73 -0
- package/esm/deps/jsr.io/@std/io/0.224.7/types.d.ts +95 -0
- package/esm/deps/jsr.io/@std/io/0.224.7/types.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/io/0.224.7/types.js +3 -0
- package/esm/deps/jsr.io/@std/io/0.224.7/write_all.d.ts +51 -0
- package/esm/deps/jsr.io/@std/io/0.224.7/write_all.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/io/0.224.7/write_all.js +61 -0
- package/esm/deps/jsr.io/@std/log/0.224.7/_config.d.ts +4 -0
- package/esm/deps/jsr.io/@std/log/0.224.7/_config.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/log/0.224.7/_config.js +14 -0
- package/esm/deps/jsr.io/@std/log/0.224.7/_file_handler_symbols.d.ts +8 -0
- package/esm/deps/jsr.io/@std/log/0.224.7/_file_handler_symbols.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/log/0.224.7/_file_handler_symbols.js +8 -0
- package/esm/deps/jsr.io/@std/log/0.224.7/_state.d.ts +8 -0
- package/esm/deps/jsr.io/@std/log/0.224.7/_state.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/log/0.224.7/_state.js +7 -0
- package/esm/deps/jsr.io/@std/log/0.224.7/base_handler.d.ts +22 -0
- package/esm/deps/jsr.io/@std/log/0.224.7/base_handler.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/log/0.224.7/base_handler.js +60 -0
- package/esm/deps/jsr.io/@std/log/0.224.7/console_handler.d.ts +18 -0
- package/esm/deps/jsr.io/@std/log/0.224.7/console_handler.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/log/0.224.7/console_handler.js +58 -0
- package/esm/deps/jsr.io/@std/log/0.224.7/critical.d.ts +5 -0
- package/esm/deps/jsr.io/@std/log/0.224.7/critical.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/log/0.224.7/critical.js +10 -0
- package/esm/deps/jsr.io/@std/log/0.224.7/debug.d.ts +5 -0
- package/esm/deps/jsr.io/@std/log/0.224.7/debug.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/log/0.224.7/debug.js +10 -0
- package/esm/deps/jsr.io/@std/log/0.224.7/error.d.ts +5 -0
- package/esm/deps/jsr.io/@std/log/0.224.7/error.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/log/0.224.7/error.js +10 -0
- package/esm/deps/jsr.io/@std/log/0.224.7/file_handler.d.ts +54 -0
- package/esm/deps/jsr.io/@std/log/0.224.7/file_handler.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/log/0.224.7/file_handler.js +135 -0
- package/esm/deps/jsr.io/@std/log/0.224.7/formatters.d.ts +6 -0
- package/esm/deps/jsr.io/@std/log/0.224.7/formatters.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/log/0.224.7/formatters.js +19 -0
- package/esm/deps/jsr.io/@std/log/0.224.7/get_logger.d.ts +4 -0
- package/esm/deps/jsr.io/@std/log/0.224.7/get_logger.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/log/0.224.7/get_logger.js +21 -0
- package/esm/deps/jsr.io/@std/log/0.224.7/info.d.ts +5 -0
- package/esm/deps/jsr.io/@std/log/0.224.7/info.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/log/0.224.7/info.js +10 -0
- package/esm/deps/jsr.io/@std/log/0.224.7/levels.d.ts +26 -0
- package/esm/deps/jsr.io/@std/log/0.224.7/levels.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/log/0.224.7/levels.js +43 -0
- package/esm/deps/jsr.io/@std/log/0.224.7/logger.d.ts +62 -0
- package/esm/deps/jsr.io/@std/log/0.224.7/logger.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/log/0.224.7/logger.js +179 -0
- package/esm/deps/jsr.io/@std/log/0.224.7/mod.d.ts +390 -0
- package/esm/deps/jsr.io/@std/log/0.224.7/mod.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/log/0.224.7/mod.js +390 -0
- package/esm/deps/jsr.io/@std/log/0.224.7/rotating_file_handler.d.ts +53 -0
- package/esm/deps/jsr.io/@std/log/0.224.7/rotating_file_handler.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/log/0.224.7/rotating_file_handler.js +125 -0
- package/esm/deps/jsr.io/@std/log/0.224.7/setup.d.ts +4 -0
- package/esm/deps/jsr.io/@std/log/0.224.7/setup.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/log/0.224.7/setup.js +41 -0
- package/esm/deps/jsr.io/@std/log/0.224.7/warn.d.ts +5 -0
- package/esm/deps/jsr.io/@std/log/0.224.7/warn.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/log/0.224.7/warn.js +10 -0
- package/esm/deps/jsr.io/@std/net/1.0.2/get_available_port.d.ts +52 -0
- package/esm/deps/jsr.io/@std/net/1.0.2/get_available_port.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/net/1.0.2/get_available_port.js +125 -0
- package/esm/deps/jsr.io/@std/net/1.0.2/get_network_address.d.ts +37 -0
- package/esm/deps/jsr.io/@std/net/1.0.2/get_network_address.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/net/1.0.2/get_network_address.js +46 -0
- package/esm/deps/jsr.io/@std/net/1.0.2/mod.d.ts +20 -0
- package/esm/deps/jsr.io/@std/net/1.0.2/mod.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/net/1.0.2/mod.js +20 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/_common/assert_path.d.ts +2 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/_common/assert_path.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/_common/assert_path.js +7 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/_common/basename.d.ts +4 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/_common/basename.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/_common/basename.js +40 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/_common/common.d.ts +2 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/_common/common.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/_common/common.js +23 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/_common/constants.d.ts +40 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/_common/constants.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/_common/constants.js +46 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/_common/dirname.d.ts +2 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/_common/dirname.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/_common/dirname.js +8 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/_common/format.d.ts +4 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/_common/format.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/_common/format.js +19 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/_common/from_file_url.d.ts +2 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/_common/from_file_url.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/_common/from_file_url.js +9 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/_common/glob_to_reg_exp.d.ts +34 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/_common/glob_to_reg_exp.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/_common/glob_to_reg_exp.js +234 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/_common/normalize.d.ts +2 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/_common/normalize.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/_common/normalize.js +8 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/_common/normalize_string.d.ts +2 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/_common/normalize_string.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/_common/normalize_string.js +77 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/_common/relative.d.ts +2 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/_common/relative.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/_common/relative.js +9 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/_common/strip_trailing_separators.d.ts +2 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/_common/strip_trailing_separators.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/_common/strip_trailing_separators.js +19 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/_common/to_file_url.d.ts +2 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/_common/to_file_url.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/_common/to_file_url.js +15 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/_interface.d.ts +42 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/_interface.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/_interface.js +3 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/_os.d.ts +2 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/_os.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/_os.js +14 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/basename.d.ts +25 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/basename.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/basename.js +33 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/common.d.ts +28 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/common.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/common.js +33 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/constants.d.ts +15 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/constants.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/constants.js +17 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/dirname.d.ts +20 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/dirname.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/dirname.js +26 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/extname.d.ts +20 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/extname.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/extname.js +26 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/format.d.ts +22 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/format.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/format.js +27 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/from_file_url.d.ts +22 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/from_file_url.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/from_file_url.js +28 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/glob_to_regexp.d.ts +79 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/glob_to_regexp.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/glob_to_regexp.js +83 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/is_absolute.d.ts +22 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/is_absolute.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/is_absolute.js +28 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/is_glob.d.ts +17 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/is_glob.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/is_glob.js +42 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/join.d.ts +20 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/join.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/join.js +26 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/join_globs.d.ts +28 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/join_globs.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/join_globs.js +34 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/mod.d.ts +51 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/mod.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/mod.js +54 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/normalize.d.ts +24 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/normalize.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/normalize.js +30 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/normalize_glob.d.ts +29 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/normalize_glob.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/normalize_glob.js +35 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/parse.d.ts +35 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/parse.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/parse.js +39 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/posix/_util.d.ts +2 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/posix/_util.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/posix/_util.js +8 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/posix/basename.d.ts +20 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/posix/basename.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/posix/basename.js +29 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/posix/constants.d.ts +13 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/posix/constants.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/posix/constants.js +14 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/posix/dirname.d.ts +17 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/posix/dirname.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/posix/dirname.js +47 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/posix/extname.d.ts +18 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/posix/extname.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/posix/extname.js +70 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/posix/format.d.ts +24 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/posix/format.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/posix/format.js +28 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/posix/from_file_url.d.ts +16 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/posix/from_file_url.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/posix/from_file_url.js +21 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/posix/glob_to_regexp.d.ts +72 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/posix/glob_to_regexp.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/posix/glob_to_regexp.js +82 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/posix/is_absolute.d.ts +17 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/posix/is_absolute.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/posix/is_absolute.js +23 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/posix/join.d.ts +17 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/posix/join.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/posix/join.js +26 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/posix/join_globs.d.ts +20 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/posix/join_globs.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/posix/join_globs.js +39 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/posix/normalize.d.ts +19 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/posix/normalize.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/posix/normalize.js +36 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/posix/normalize_glob.d.ts +20 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/posix/normalize_glob.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/posix/normalize_glob.js +31 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/posix/parse.d.ts +25 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/posix/parse.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/posix/parse.js +115 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/posix/relative.d.ts +20 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/posix/relative.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/posix/relative.js +106 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/posix/resolve.d.ts +17 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/posix/resolve.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/posix/resolve.js +59 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/posix/to_file_url.d.ts +17 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/posix/to_file_url.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/posix/to_file_url.js +27 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/posix/to_namespaced_path.d.ts +16 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/posix/to_namespaced_path.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/posix/to_namespaced_path.js +20 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/relative.d.ts +24 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/relative.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/relative.js +30 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/resolve.d.ts +22 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/resolve.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/resolve.js +30 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/to_file_url.d.ts +22 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/to_file_url.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/to_file_url.js +28 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/to_namespaced_path.d.ts +21 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/to_namespaced_path.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/to_namespaced_path.js +29 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/windows/_util.d.ts +4 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/windows/_util.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/windows/_util.js +15 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/windows/basename.d.ts +20 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/windows/basename.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/windows/basename.js +41 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/windows/constants.d.ts +13 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/windows/constants.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/windows/constants.js +14 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/windows/dirname.d.ts +17 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/windows/dirname.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/windows/dirname.js +109 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/windows/extname.d.ts +17 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/windows/extname.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/windows/extname.js +78 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/windows/format.d.ts +24 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/windows/format.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/windows/format.js +28 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/windows/from_file_url.d.ts +18 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/windows/from_file_url.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/windows/from_file_url.js +30 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/windows/glob_to_regexp.d.ts +71 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/windows/glob_to_regexp.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/windows/glob_to_regexp.js +82 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/windows/is_absolute.d.ts +17 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/windows/is_absolute.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/windows/is_absolute.js +38 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/windows/join.d.ts +17 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/windows/join.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/windows/join.js +71 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/windows/join_globs.d.ts +21 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/windows/join_globs.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/windows/join_globs.js +40 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/windows/normalize.d.ts +19 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/windows/normalize.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/windows/normalize.js +131 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/windows/normalize_glob.d.ts +20 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/windows/normalize_glob.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/windows/normalize_glob.js +31 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/windows/parse.d.ts +25 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/windows/parse.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/windows/parse.js +176 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/windows/relative.d.ts +23 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/windows/relative.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/windows/relative.js +131 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/windows/resolve.d.ts +17 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/windows/resolve.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/windows/resolve.js +154 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/windows/to_file_url.d.ts +17 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/windows/to_file_url.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/windows/to_file_url.js +34 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/windows/to_namespaced_path.d.ts +17 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/windows/to_namespaced_path.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.0-rc.2/windows/to_namespaced_path.js +49 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/_common/assert_path.d.ts +2 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/_common/assert_path.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/_common/assert_path.js +7 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/_common/basename.d.ts +4 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/_common/basename.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/_common/basename.js +40 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/_common/common.d.ts +2 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/_common/common.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/_common/common.js +23 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/_common/constants.d.ts +40 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/_common/constants.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/_common/constants.js +46 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/_common/dirname.d.ts +2 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/_common/dirname.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/_common/dirname.js +8 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/_common/format.d.ts +4 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/_common/format.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/_common/format.js +19 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/_common/from_file_url.d.ts +2 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/_common/from_file_url.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/_common/from_file_url.js +9 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/_common/glob_to_reg_exp.d.ts +35 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/_common/glob_to_reg_exp.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/_common/glob_to_reg_exp.js +234 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/_common/normalize.d.ts +2 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/_common/normalize.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/_common/normalize.js +8 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/_common/normalize_string.d.ts +2 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/_common/normalize_string.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/_common/normalize_string.js +77 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/_common/relative.d.ts +2 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/_common/relative.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/_common/relative.js +9 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/_common/strip_trailing_separators.d.ts +2 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/_common/strip_trailing_separators.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/_common/strip_trailing_separators.js +19 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/_common/to_file_url.d.ts +2 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/_common/to_file_url.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/_common/to_file_url.js +15 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/_os.d.ts +2 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/_os.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/_os.js +9 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/basename.d.ts +53 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/basename.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/basename.js +10 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/common.d.ts +28 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/common.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/common.js +33 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/constants.d.ts +15 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/constants.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/constants.js +17 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/dirname.d.ts +43 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/dirname.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/dirname.js +8 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/extname.d.ts +43 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/extname.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/extname.js +8 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/format.d.ts +22 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/format.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/format.js +27 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/from_file_url.d.ts +22 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/from_file_url.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/from_file_url.js +28 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/glob_to_regexp.d.ts +77 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/glob_to_regexp.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/glob_to_regexp.js +83 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/is_absolute.d.ts +22 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/is_absolute.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/is_absolute.js +28 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/is_glob.d.ts +17 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/is_glob.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/is_glob.js +42 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/join.d.ts +39 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/join.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/join.js +8 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/join_globs.d.ts +28 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/join_globs.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/join_globs.js +34 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/mod.d.ts +54 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/mod.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/mod.js +57 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/normalize.d.ts +51 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/normalize.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/normalize.js +8 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/normalize_glob.d.ts +29 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/normalize_glob.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/normalize_glob.js +35 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/parse.d.ts +35 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/parse.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/parse.js +39 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/posix/_util.d.ts +2 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/posix/_util.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/posix/_util.js +8 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/posix/basename.d.ts +43 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/posix/basename.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/posix/basename.js +13 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/posix/constants.d.ts +13 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/posix/constants.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/posix/constants.js +14 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/posix/dirname.d.ts +36 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/posix/dirname.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/posix/dirname.js +36 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/posix/extname.d.ts +43 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/posix/extname.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/posix/extname.js +58 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/posix/format.d.ts +24 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/posix/format.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/posix/format.js +28 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/posix/from_file_url.d.ts +16 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/posix/from_file_url.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/posix/from_file_url.js +21 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/posix/glob_to_regexp.d.ts +72 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/posix/glob_to_regexp.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/posix/glob_to_regexp.js +82 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/posix/is_absolute.d.ts +17 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/posix/is_absolute.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/posix/is_absolute.js +23 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/posix/join.d.ts +36 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/posix/join.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/posix/join.js +14 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/posix/join_globs.d.ts +20 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/posix/join_globs.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/posix/join_globs.js +39 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/posix/normalize.d.ts +39 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/posix/normalize.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/posix/normalize.js +21 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/posix/normalize_glob.d.ts +20 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/posix/normalize_glob.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/posix/normalize_glob.js +31 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/posix/parse.d.ts +25 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/posix/parse.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/posix/parse.js +115 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/posix/relative.d.ts +20 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/posix/relative.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/posix/relative.js +106 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/posix/resolve.d.ts +17 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/posix/resolve.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/posix/resolve.js +59 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/posix/to_file_url.d.ts +17 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/posix/to_file_url.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/posix/to_file_url.js +27 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/posix/to_namespaced_path.d.ts +16 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/posix/to_namespaced_path.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/posix/to_namespaced_path.js +20 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/relative.d.ts +24 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/relative.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/relative.js +30 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/resolve.d.ts +22 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/resolve.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/resolve.js +30 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/to_file_url.d.ts +22 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/to_file_url.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/to_file_url.js +28 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/to_namespaced_path.d.ts +21 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/to_namespaced_path.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/to_namespaced_path.js +29 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/types.d.ts +38 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/types.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/types.js +3 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/windows/_util.d.ts +4 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/windows/_util.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/windows/_util.js +15 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/windows/basename.d.ts +43 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/windows/basename.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/windows/basename.js +25 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/windows/constants.d.ts +13 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/windows/constants.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/windows/constants.js +14 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/windows/dirname.d.ts +35 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/windows/dirname.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/windows/dirname.js +98 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/windows/extname.d.ts +35 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/windows/extname.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/windows/extname.js +67 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/windows/format.d.ts +24 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/windows/format.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/windows/format.js +28 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/windows/from_file_url.d.ts +18 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/windows/from_file_url.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/windows/from_file_url.js +30 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/windows/glob_to_regexp.d.ts +71 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/windows/glob_to_regexp.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/windows/glob_to_regexp.js +82 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/windows/is_absolute.d.ts +17 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/windows/is_absolute.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/windows/is_absolute.js +38 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/windows/join.d.ts +36 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/windows/join.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/windows/join.js +59 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/windows/join_globs.d.ts +21 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/windows/join_globs.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/windows/join_globs.js +40 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/windows/normalize.d.ts +39 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/windows/normalize.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/windows/normalize.js +116 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/windows/normalize_glob.d.ts +20 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/windows/normalize_glob.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/windows/normalize_glob.js +31 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/windows/parse.d.ts +25 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/windows/parse.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/windows/parse.js +176 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/windows/relative.d.ts +23 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/windows/relative.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/windows/relative.js +131 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/windows/resolve.d.ts +17 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/windows/resolve.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/windows/resolve.js +154 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/windows/to_file_url.d.ts +17 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/windows/to_file_url.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/windows/to_file_url.js +34 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/windows/to_namespaced_path.d.ts +17 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/windows/to_namespaced_path.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.4/windows/to_namespaced_path.js +49 -0
- package/esm/deps/jsr.io/@std/text/1.0.0-rc.1/closest_string.d.ts +29 -0
- package/esm/deps/jsr.io/@std/text/1.0.0-rc.1/closest_string.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/text/1.0.0-rc.1/closest_string.js +52 -0
- package/esm/deps/jsr.io/@std/text/1.0.0-rc.1/levenshtein_distance.d.ts +18 -0
- package/esm/deps/jsr.io/@std/text/1.0.0-rc.1/levenshtein_distance.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/text/1.0.0-rc.1/levenshtein_distance.js +40 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/_chars.d.ts +33 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/_chars.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/_chars.js +48 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/_dumper_state.d.ts +99 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/_dumper_state.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/_dumper_state.js +707 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/_loader_state.d.ts +60 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/_loader_state.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/_loader_state.js +1409 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/_schema.d.ts +40 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/_schema.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/_schema.js +112 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/_type/binary.d.ts +3 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/_type/binary.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/_type/binary.js +103 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/_type/bool.d.ts +3 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/_type/bool.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/_type/bool.js +32 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/_type/float.d.ts +3 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/_type/float.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/_type/float.js +96 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/_type/int.d.ts +3 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/_type/int.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/_type/int.js +159 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/_type/map.d.ts +3 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/_type/map.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/_type/map.js +14 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/_type/merge.d.ts +3 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/_type/merge.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/_type/merge.js +10 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/_type/nil.d.ts +3 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/_type/nil.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/_type/nil.js +22 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/_type/omap.d.ts +3 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/_type/omap.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/_type/omap.js +29 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/_type/pairs.d.ts +3 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/_type/pairs.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/_type/pairs.js +19 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/_type/regexp.d.ts +3 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/_type/regexp.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/_type/regexp.js +30 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/_type/seq.d.ts +3 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/_type/seq.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/_type/seq.js +10 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/_type/set.d.ts +3 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/_type/set.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/_type/set.js +14 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/_type/str.d.ts +3 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/_type/str.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/_type/str.js +9 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/_type/timestamp.d.ts +3 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/_type/timestamp.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/_type/timestamp.js +81 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/_type/undefined.d.ts +3 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/_type/undefined.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/_type/undefined.js +20 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/_type.d.ts +16 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/_type.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/_type.js +6 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/_utils.d.ts +4 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/_utils.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/_utils.js +13 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/mod.d.ts +50 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/mod.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/mod.js +52 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/parse.d.ts +76 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/parse.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/parse.js +93 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/stringify.d.ts +100 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/stringify.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/yaml/1.0.5/stringify.js +33 -0
- package/esm/deps.d.ts +27 -0
- package/esm/deps.d.ts.map +1 -0
- package/esm/deps.js +30 -0
- package/esm/dev.d.ts +12 -0
- package/esm/dev.d.ts.map +1 -0
- package/esm/dev.js +107 -0
- package/esm/flow.d.ts +29 -0
- package/esm/flow.d.ts.map +1 -0
- package/esm/flow.js +267 -0
- package/esm/folder.d.ts +16 -0
- package/esm/folder.d.ts.map +1 -0
- package/esm/folder.js +97 -0
- package/esm/hub.d.ts +10 -0
- package/esm/hub.d.ts.map +1 -0
- package/esm/hub.js +71 -0
- package/esm/instance.d.ts +39 -0
- package/esm/instance.d.ts.map +1 -0
- package/esm/instance.js +384 -0
- package/esm/login.d.ts +5 -0
- package/esm/login.d.ts.map +1 -0
- package/esm/login.js +96 -0
- package/esm/main.d.ts +6 -0
- package/esm/main.d.ts.map +1 -0
- package/esm/main.js +132 -0
- package/esm/metadata.d.ts +71 -0
- package/esm/metadata.d.ts.map +1 -0
- package/esm/metadata.js +631 -0
- package/esm/package.json +3 -0
- package/esm/pull.d.ts +12 -0
- package/esm/pull.d.ts.map +1 -0
- package/esm/pull.js +39 -0
- package/esm/push.d.ts +10 -0
- package/esm/push.d.ts.map +1 -0
- package/esm/push.js +10 -0
- package/esm/resource-type.d.ts +15 -0
- package/esm/resource-type.d.ts.map +1 -0
- package/esm/resource-type.js +70 -0
- package/esm/resource.d.ts +17 -0
- package/esm/resource.d.ts.map +1 -0
- package/esm/resource.js +86 -0
- package/esm/schedule.d.ts +19 -0
- package/esm/schedule.d.ts.map +1 -0
- package/esm/schedule.js +88 -0
- package/esm/script.d.ts +51 -0
- package/esm/script.d.ts.map +1 -0
- package/esm/script.js +666 -0
- package/esm/script_common.d.ts +3 -0
- package/esm/script_common.d.ts.map +1 -0
- package/esm/script_common.js +50 -0
- package/esm/settings.d.ts +24 -0
- package/esm/settings.d.ts.map +1 -0
- package/esm/settings.js +327 -0
- package/esm/store.d.ts +3 -0
- package/esm/store.d.ts.map +1 -0
- package/esm/store.js +71 -0
- package/esm/sync.d.ts +99 -0
- package/esm/sync.d.ts.map +1 -0
- package/esm/sync.js +1137 -0
- package/esm/types.d.ts +31 -0
- package/esm/types.d.ts.map +1 -0
- package/esm/types.js +179 -0
- package/esm/user.d.ts +30 -0
- package/esm/user.d.ts.map +1 -0
- package/esm/user.js +396 -0
- package/esm/utils.d.ts +8 -0
- package/esm/utils.d.ts.map +1 -0
- package/esm/utils.js +122 -0
- package/esm/variable.d.ts +20 -0
- package/esm/variable.d.ts.map +1 -0
- package/esm/variable.js +118 -0
- package/esm/wasm/windmill_parser_wasm.generated.d.ts +117 -0
- package/esm/wasm/windmill_parser_wasm.generated.d.ts.map +1 -0
- package/esm/wasm/windmill_parser_wasm.generated.js +1029 -0
- package/esm/workspace.d.ts +27 -0
- package/esm/workspace.d.ts.map +1 -0
- package/esm/workspace.js +241 -0
- package/package.json +40 -0
|
@@ -0,0 +1,1789 @@
|
|
|
1
|
+
// deno-lint-ignore-file no-explicit-any
|
|
2
|
+
import * as dntShim from "../../../../../_dnt.shims.js";
|
|
3
|
+
import { parseFlags, UnknownTypeError, ValidationError as FlagsValidationError, } from "../../flags/1.0.0-rc.5/mod.js";
|
|
4
|
+
import { bold, brightBlue, red } from "../../../@std/fmt/0.225.6/colors.js";
|
|
5
|
+
import { CommandNotFoundError, DefaultCommandNotFoundError, DuplicateCommandAliasError, DuplicateCommandNameError, DuplicateCompletionError, DuplicateEnvVarError, DuplicateExampleError, DuplicateOptionNameError, DuplicateTypeError, MissingArgumentError, MissingArgumentsError, MissingCommandNameError, MissingRequiredEnvVarError, NoArgumentsAllowedError, TooManyArgumentsError, TooManyEnvVarValuesError, UnexpectedOptionalEnvVarValueError, UnexpectedVariadicEnvVarValueError, UnknownCommandError, ValidationError, } from "./_errors.js";
|
|
6
|
+
import { exit } from "../../internal/1.0.0-rc.5/runtime/exit.js";
|
|
7
|
+
import { getArgs } from "../../internal/1.0.0-rc.5/runtime/get_args.js";
|
|
8
|
+
import { getEnv } from "../../internal/1.0.0-rc.5/runtime/get_env.js";
|
|
9
|
+
import { getDescription, parseArgumentsDefinition, splitArguments, underscoreToCamelCase, } from "./_utils.js";
|
|
10
|
+
import { HelpGenerator } from "./help/_help_generator.js";
|
|
11
|
+
import { Type } from "./type.js";
|
|
12
|
+
import { BooleanType } from "./types/boolean.js";
|
|
13
|
+
import { FileType } from "./types/file.js";
|
|
14
|
+
import { IntegerType } from "./types/integer.js";
|
|
15
|
+
import { NumberType } from "./types/number.js";
|
|
16
|
+
import { StringType } from "./types/string.js";
|
|
17
|
+
import { checkVersion } from "./upgrade/_check_version.js";
|
|
18
|
+
/**
|
|
19
|
+
* Chainable command factory class.
|
|
20
|
+
*
|
|
21
|
+
* ```ts
|
|
22
|
+
* import { Command } from "./mod.ts";
|
|
23
|
+
*
|
|
24
|
+
* export const cli = new Command()
|
|
25
|
+
* .name("todo")
|
|
26
|
+
* .description("Example command description")
|
|
27
|
+
* .globalOption("--verbose", "Enable verbose output.")
|
|
28
|
+
* .globalEnv("VERBOSE=<value>", "Enable verbose output.")
|
|
29
|
+
* .command("add <todo>", "Add todo.")
|
|
30
|
+
* .action(({ verbose }, todo: string) => {
|
|
31
|
+
* if (verbose) {
|
|
32
|
+
* console.log("Add todo '%s'.", todo);
|
|
33
|
+
* }
|
|
34
|
+
* })
|
|
35
|
+
* .command("delete <id>", "Delete todo.")
|
|
36
|
+
* .action(({ verbose }, id: string) => {
|
|
37
|
+
* if (verbose) {
|
|
38
|
+
* console.log("Delete todo with id '%s'.", id);
|
|
39
|
+
* }
|
|
40
|
+
* });
|
|
41
|
+
*
|
|
42
|
+
* if (import.meta.main) {
|
|
43
|
+
* await cli.parse();
|
|
44
|
+
* }
|
|
45
|
+
* ```
|
|
46
|
+
*/
|
|
47
|
+
export class Command {
|
|
48
|
+
constructor() {
|
|
49
|
+
Object.defineProperty(this, "types", {
|
|
50
|
+
enumerable: true,
|
|
51
|
+
configurable: true,
|
|
52
|
+
writable: true,
|
|
53
|
+
value: new Map()
|
|
54
|
+
});
|
|
55
|
+
Object.defineProperty(this, "rawArgs", {
|
|
56
|
+
enumerable: true,
|
|
57
|
+
configurable: true,
|
|
58
|
+
writable: true,
|
|
59
|
+
value: []
|
|
60
|
+
});
|
|
61
|
+
Object.defineProperty(this, "literalArgs", {
|
|
62
|
+
enumerable: true,
|
|
63
|
+
configurable: true,
|
|
64
|
+
writable: true,
|
|
65
|
+
value: []
|
|
66
|
+
});
|
|
67
|
+
Object.defineProperty(this, "_name", {
|
|
68
|
+
enumerable: true,
|
|
69
|
+
configurable: true,
|
|
70
|
+
writable: true,
|
|
71
|
+
value: "COMMAND"
|
|
72
|
+
});
|
|
73
|
+
Object.defineProperty(this, "_parent", {
|
|
74
|
+
enumerable: true,
|
|
75
|
+
configurable: true,
|
|
76
|
+
writable: true,
|
|
77
|
+
value: void 0
|
|
78
|
+
});
|
|
79
|
+
Object.defineProperty(this, "_globalParent", {
|
|
80
|
+
enumerable: true,
|
|
81
|
+
configurable: true,
|
|
82
|
+
writable: true,
|
|
83
|
+
value: void 0
|
|
84
|
+
});
|
|
85
|
+
Object.defineProperty(this, "ver", {
|
|
86
|
+
enumerable: true,
|
|
87
|
+
configurable: true,
|
|
88
|
+
writable: true,
|
|
89
|
+
value: void 0
|
|
90
|
+
});
|
|
91
|
+
Object.defineProperty(this, "desc", {
|
|
92
|
+
enumerable: true,
|
|
93
|
+
configurable: true,
|
|
94
|
+
writable: true,
|
|
95
|
+
value: ""
|
|
96
|
+
});
|
|
97
|
+
Object.defineProperty(this, "_usage", {
|
|
98
|
+
enumerable: true,
|
|
99
|
+
configurable: true,
|
|
100
|
+
writable: true,
|
|
101
|
+
value: void 0
|
|
102
|
+
});
|
|
103
|
+
Object.defineProperty(this, "actionHandler", {
|
|
104
|
+
enumerable: true,
|
|
105
|
+
configurable: true,
|
|
106
|
+
writable: true,
|
|
107
|
+
value: void 0
|
|
108
|
+
});
|
|
109
|
+
Object.defineProperty(this, "globalActionHandler", {
|
|
110
|
+
enumerable: true,
|
|
111
|
+
configurable: true,
|
|
112
|
+
writable: true,
|
|
113
|
+
value: void 0
|
|
114
|
+
});
|
|
115
|
+
Object.defineProperty(this, "options", {
|
|
116
|
+
enumerable: true,
|
|
117
|
+
configurable: true,
|
|
118
|
+
writable: true,
|
|
119
|
+
value: []
|
|
120
|
+
});
|
|
121
|
+
Object.defineProperty(this, "commands", {
|
|
122
|
+
enumerable: true,
|
|
123
|
+
configurable: true,
|
|
124
|
+
writable: true,
|
|
125
|
+
value: new Map()
|
|
126
|
+
});
|
|
127
|
+
Object.defineProperty(this, "examples", {
|
|
128
|
+
enumerable: true,
|
|
129
|
+
configurable: true,
|
|
130
|
+
writable: true,
|
|
131
|
+
value: []
|
|
132
|
+
});
|
|
133
|
+
Object.defineProperty(this, "envVars", {
|
|
134
|
+
enumerable: true,
|
|
135
|
+
configurable: true,
|
|
136
|
+
writable: true,
|
|
137
|
+
value: []
|
|
138
|
+
});
|
|
139
|
+
Object.defineProperty(this, "aliases", {
|
|
140
|
+
enumerable: true,
|
|
141
|
+
configurable: true,
|
|
142
|
+
writable: true,
|
|
143
|
+
value: []
|
|
144
|
+
});
|
|
145
|
+
Object.defineProperty(this, "completions", {
|
|
146
|
+
enumerable: true,
|
|
147
|
+
configurable: true,
|
|
148
|
+
writable: true,
|
|
149
|
+
value: new Map()
|
|
150
|
+
});
|
|
151
|
+
Object.defineProperty(this, "cmd", {
|
|
152
|
+
enumerable: true,
|
|
153
|
+
configurable: true,
|
|
154
|
+
writable: true,
|
|
155
|
+
value: this
|
|
156
|
+
});
|
|
157
|
+
Object.defineProperty(this, "argsDefinition", {
|
|
158
|
+
enumerable: true,
|
|
159
|
+
configurable: true,
|
|
160
|
+
writable: true,
|
|
161
|
+
value: void 0
|
|
162
|
+
});
|
|
163
|
+
Object.defineProperty(this, "throwOnError", {
|
|
164
|
+
enumerable: true,
|
|
165
|
+
configurable: true,
|
|
166
|
+
writable: true,
|
|
167
|
+
value: false
|
|
168
|
+
});
|
|
169
|
+
Object.defineProperty(this, "_allowEmpty", {
|
|
170
|
+
enumerable: true,
|
|
171
|
+
configurable: true,
|
|
172
|
+
writable: true,
|
|
173
|
+
value: false
|
|
174
|
+
});
|
|
175
|
+
Object.defineProperty(this, "_stopEarly", {
|
|
176
|
+
enumerable: true,
|
|
177
|
+
configurable: true,
|
|
178
|
+
writable: true,
|
|
179
|
+
value: false
|
|
180
|
+
});
|
|
181
|
+
Object.defineProperty(this, "defaultCommand", {
|
|
182
|
+
enumerable: true,
|
|
183
|
+
configurable: true,
|
|
184
|
+
writable: true,
|
|
185
|
+
value: void 0
|
|
186
|
+
});
|
|
187
|
+
Object.defineProperty(this, "_useRawArgs", {
|
|
188
|
+
enumerable: true,
|
|
189
|
+
configurable: true,
|
|
190
|
+
writable: true,
|
|
191
|
+
value: false
|
|
192
|
+
});
|
|
193
|
+
Object.defineProperty(this, "args", {
|
|
194
|
+
enumerable: true,
|
|
195
|
+
configurable: true,
|
|
196
|
+
writable: true,
|
|
197
|
+
value: []
|
|
198
|
+
});
|
|
199
|
+
Object.defineProperty(this, "isHidden", {
|
|
200
|
+
enumerable: true,
|
|
201
|
+
configurable: true,
|
|
202
|
+
writable: true,
|
|
203
|
+
value: false
|
|
204
|
+
});
|
|
205
|
+
Object.defineProperty(this, "isGlobal", {
|
|
206
|
+
enumerable: true,
|
|
207
|
+
configurable: true,
|
|
208
|
+
writable: true,
|
|
209
|
+
value: false
|
|
210
|
+
});
|
|
211
|
+
Object.defineProperty(this, "hasDefaults", {
|
|
212
|
+
enumerable: true,
|
|
213
|
+
configurable: true,
|
|
214
|
+
writable: true,
|
|
215
|
+
value: false
|
|
216
|
+
});
|
|
217
|
+
Object.defineProperty(this, "_versionOptions", {
|
|
218
|
+
enumerable: true,
|
|
219
|
+
configurable: true,
|
|
220
|
+
writable: true,
|
|
221
|
+
value: void 0
|
|
222
|
+
});
|
|
223
|
+
Object.defineProperty(this, "_helpOptions", {
|
|
224
|
+
enumerable: true,
|
|
225
|
+
configurable: true,
|
|
226
|
+
writable: true,
|
|
227
|
+
value: void 0
|
|
228
|
+
});
|
|
229
|
+
Object.defineProperty(this, "_versionOption", {
|
|
230
|
+
enumerable: true,
|
|
231
|
+
configurable: true,
|
|
232
|
+
writable: true,
|
|
233
|
+
value: void 0
|
|
234
|
+
});
|
|
235
|
+
Object.defineProperty(this, "_helpOption", {
|
|
236
|
+
enumerable: true,
|
|
237
|
+
configurable: true,
|
|
238
|
+
writable: true,
|
|
239
|
+
value: void 0
|
|
240
|
+
});
|
|
241
|
+
Object.defineProperty(this, "_help", {
|
|
242
|
+
enumerable: true,
|
|
243
|
+
configurable: true,
|
|
244
|
+
writable: true,
|
|
245
|
+
value: void 0
|
|
246
|
+
});
|
|
247
|
+
Object.defineProperty(this, "_shouldExit", {
|
|
248
|
+
enumerable: true,
|
|
249
|
+
configurable: true,
|
|
250
|
+
writable: true,
|
|
251
|
+
value: void 0
|
|
252
|
+
});
|
|
253
|
+
Object.defineProperty(this, "_meta", {
|
|
254
|
+
enumerable: true,
|
|
255
|
+
configurable: true,
|
|
256
|
+
writable: true,
|
|
257
|
+
value: {}
|
|
258
|
+
});
|
|
259
|
+
Object.defineProperty(this, "_groupName", {
|
|
260
|
+
enumerable: true,
|
|
261
|
+
configurable: true,
|
|
262
|
+
writable: true,
|
|
263
|
+
value: null
|
|
264
|
+
});
|
|
265
|
+
Object.defineProperty(this, "_noGlobals", {
|
|
266
|
+
enumerable: true,
|
|
267
|
+
configurable: true,
|
|
268
|
+
writable: true,
|
|
269
|
+
value: false
|
|
270
|
+
});
|
|
271
|
+
Object.defineProperty(this, "errorHandler", {
|
|
272
|
+
enumerable: true,
|
|
273
|
+
configurable: true,
|
|
274
|
+
writable: true,
|
|
275
|
+
value: void 0
|
|
276
|
+
});
|
|
277
|
+
}
|
|
278
|
+
versionOption(flags, desc, opts) {
|
|
279
|
+
this._versionOptions = flags === false ? flags : {
|
|
280
|
+
flags,
|
|
281
|
+
desc,
|
|
282
|
+
opts: typeof opts === "function" ? { action: opts } : opts,
|
|
283
|
+
};
|
|
284
|
+
return this;
|
|
285
|
+
}
|
|
286
|
+
helpOption(flags, desc, opts) {
|
|
287
|
+
this._helpOptions = flags === false ? flags : {
|
|
288
|
+
flags,
|
|
289
|
+
desc,
|
|
290
|
+
opts: typeof opts === "function" ? { action: opts } : opts,
|
|
291
|
+
};
|
|
292
|
+
return this;
|
|
293
|
+
}
|
|
294
|
+
/**
|
|
295
|
+
* Add new sub-command.
|
|
296
|
+
* @param nameAndArguments Command definition. E.g: `my-command <input-file:string> <output-file:string>`
|
|
297
|
+
* @param cmdOrDescription The description of the new child command.
|
|
298
|
+
* @param override Override existing child command.
|
|
299
|
+
*/
|
|
300
|
+
command(nameAndArguments, cmdOrDescription, override) {
|
|
301
|
+
this.reset();
|
|
302
|
+
const result = splitArguments(nameAndArguments);
|
|
303
|
+
const name = result.flags.shift();
|
|
304
|
+
const aliases = result.flags;
|
|
305
|
+
if (!name) {
|
|
306
|
+
throw new MissingCommandNameError();
|
|
307
|
+
}
|
|
308
|
+
if (this.getBaseCommand(name, true)) {
|
|
309
|
+
if (!override) {
|
|
310
|
+
throw new DuplicateCommandNameError(name);
|
|
311
|
+
}
|
|
312
|
+
this.removeCommand(name);
|
|
313
|
+
}
|
|
314
|
+
let description;
|
|
315
|
+
let cmd;
|
|
316
|
+
if (typeof cmdOrDescription === "string") {
|
|
317
|
+
description = cmdOrDescription;
|
|
318
|
+
}
|
|
319
|
+
if (cmdOrDescription instanceof Command) {
|
|
320
|
+
cmd = cmdOrDescription.reset();
|
|
321
|
+
}
|
|
322
|
+
else {
|
|
323
|
+
cmd = new Command();
|
|
324
|
+
}
|
|
325
|
+
cmd._name = name;
|
|
326
|
+
cmd._parent = this;
|
|
327
|
+
if (description) {
|
|
328
|
+
cmd.description(description);
|
|
329
|
+
}
|
|
330
|
+
if (result.typeDefinition) {
|
|
331
|
+
cmd.arguments(result.typeDefinition);
|
|
332
|
+
}
|
|
333
|
+
aliases.forEach((alias) => cmd.alias(alias));
|
|
334
|
+
this.commands.set(name, cmd);
|
|
335
|
+
this.select(name);
|
|
336
|
+
return this;
|
|
337
|
+
}
|
|
338
|
+
/**
|
|
339
|
+
* Add new command alias.
|
|
340
|
+
*
|
|
341
|
+
* @param alias Tha name of the alias.
|
|
342
|
+
*/
|
|
343
|
+
alias(alias) {
|
|
344
|
+
if (this.cmd._name === alias || this.cmd.aliases.includes(alias)) {
|
|
345
|
+
throw new DuplicateCommandAliasError(alias);
|
|
346
|
+
}
|
|
347
|
+
this.cmd.aliases.push(alias);
|
|
348
|
+
return this;
|
|
349
|
+
}
|
|
350
|
+
/** Reset internal command reference to main command. */
|
|
351
|
+
reset() {
|
|
352
|
+
this._groupName = null;
|
|
353
|
+
this.cmd = this;
|
|
354
|
+
return this;
|
|
355
|
+
}
|
|
356
|
+
/**
|
|
357
|
+
* Set internal command pointer to child command with given name.
|
|
358
|
+
* @param name The name of the command to select.
|
|
359
|
+
*/
|
|
360
|
+
select(name) {
|
|
361
|
+
const cmd = this.getBaseCommand(name, true);
|
|
362
|
+
if (!cmd) {
|
|
363
|
+
throw new CommandNotFoundError(name, this.getBaseCommands(true));
|
|
364
|
+
}
|
|
365
|
+
this.cmd = cmd;
|
|
366
|
+
return this;
|
|
367
|
+
}
|
|
368
|
+
/*****************************************************************************
|
|
369
|
+
**** SUB HANDLER ************************************************************
|
|
370
|
+
*****************************************************************************/
|
|
371
|
+
/** Set command name. Used in auto generated help and shell completions */
|
|
372
|
+
name(name) {
|
|
373
|
+
this.cmd._name = name;
|
|
374
|
+
return this;
|
|
375
|
+
}
|
|
376
|
+
/**
|
|
377
|
+
* Set command version.
|
|
378
|
+
*
|
|
379
|
+
* @param version Semantic version string string or method that returns the version string.
|
|
380
|
+
*/
|
|
381
|
+
version(version) {
|
|
382
|
+
if (typeof version === "string") {
|
|
383
|
+
this.cmd.ver = () => version;
|
|
384
|
+
}
|
|
385
|
+
else if (typeof version === "function") {
|
|
386
|
+
this.cmd.ver = version;
|
|
387
|
+
}
|
|
388
|
+
return this;
|
|
389
|
+
}
|
|
390
|
+
/**
|
|
391
|
+
* Add meta data. Will be displayed in the auto generated help and in the
|
|
392
|
+
* output of the long version.
|
|
393
|
+
*
|
|
394
|
+
* @param name The name/label of the metadata.
|
|
395
|
+
* @param value The value of the metadata.
|
|
396
|
+
*/
|
|
397
|
+
meta(name, value) {
|
|
398
|
+
this.cmd._meta[name] = value;
|
|
399
|
+
return this;
|
|
400
|
+
}
|
|
401
|
+
getMeta(name) {
|
|
402
|
+
return typeof name === "undefined" ? this._meta : this._meta[name];
|
|
403
|
+
}
|
|
404
|
+
/**
|
|
405
|
+
* Set command help.
|
|
406
|
+
*
|
|
407
|
+
* @param help Help string, method, or config for generator that returns the help string.
|
|
408
|
+
*/
|
|
409
|
+
help(help) {
|
|
410
|
+
if (typeof help === "string") {
|
|
411
|
+
this.cmd._help = () => help;
|
|
412
|
+
}
|
|
413
|
+
else if (typeof help === "function") {
|
|
414
|
+
this.cmd._help = help;
|
|
415
|
+
}
|
|
416
|
+
else {
|
|
417
|
+
this.cmd._help = (cmd, options) => HelpGenerator.generate(cmd, { ...help, ...options });
|
|
418
|
+
}
|
|
419
|
+
return this;
|
|
420
|
+
}
|
|
421
|
+
/**
|
|
422
|
+
* Set the long command description.
|
|
423
|
+
*
|
|
424
|
+
* @param description The command description.
|
|
425
|
+
*/
|
|
426
|
+
description(description) {
|
|
427
|
+
this.cmd.desc = description;
|
|
428
|
+
return this;
|
|
429
|
+
}
|
|
430
|
+
/**
|
|
431
|
+
* Set the command usage. Defaults to arguments.
|
|
432
|
+
*
|
|
433
|
+
* @param usage The command usage.
|
|
434
|
+
*/
|
|
435
|
+
usage(usage) {
|
|
436
|
+
this.cmd._usage = usage;
|
|
437
|
+
return this;
|
|
438
|
+
}
|
|
439
|
+
/** Hide command from help, completions, etc. */
|
|
440
|
+
hidden() {
|
|
441
|
+
this.cmd.isHidden = true;
|
|
442
|
+
return this;
|
|
443
|
+
}
|
|
444
|
+
/** Make command globally available. */
|
|
445
|
+
global() {
|
|
446
|
+
this.cmd.isGlobal = true;
|
|
447
|
+
return this;
|
|
448
|
+
}
|
|
449
|
+
/**
|
|
450
|
+
* Set command arguments.
|
|
451
|
+
*
|
|
452
|
+
* Syntax: `<requiredArg:string> [optionalArg: number] [...restArgs:string]`
|
|
453
|
+
*/
|
|
454
|
+
arguments(args) {
|
|
455
|
+
this.cmd.argsDefinition = args;
|
|
456
|
+
return this;
|
|
457
|
+
}
|
|
458
|
+
/**
|
|
459
|
+
* Set command callback method.
|
|
460
|
+
*
|
|
461
|
+
* @param fn Command action handler.
|
|
462
|
+
*/
|
|
463
|
+
action(fn) {
|
|
464
|
+
this.cmd.actionHandler = fn;
|
|
465
|
+
return this;
|
|
466
|
+
}
|
|
467
|
+
/**
|
|
468
|
+
* Set command callback method.
|
|
469
|
+
*
|
|
470
|
+
* @param fn Command action handler.
|
|
471
|
+
*/
|
|
472
|
+
globalAction(fn) {
|
|
473
|
+
this.cmd.globalActionHandler = fn;
|
|
474
|
+
return this;
|
|
475
|
+
}
|
|
476
|
+
/**
|
|
477
|
+
* Don't throw an error if the command was called without arguments.
|
|
478
|
+
*
|
|
479
|
+
* @param allowEmpty Enable/disable allow empty.
|
|
480
|
+
*/
|
|
481
|
+
allowEmpty(allowEmpty) {
|
|
482
|
+
this.cmd._allowEmpty = allowEmpty !== false;
|
|
483
|
+
return this;
|
|
484
|
+
}
|
|
485
|
+
/**
|
|
486
|
+
* Enable stop early. If enabled, all arguments starting from the first non
|
|
487
|
+
* option argument will be passed as arguments with type string to the command
|
|
488
|
+
* action handler.
|
|
489
|
+
*
|
|
490
|
+
* For example:
|
|
491
|
+
* `command --debug-level warning server --port 80`
|
|
492
|
+
*
|
|
493
|
+
* Will result in:
|
|
494
|
+
* - options: `{ debugLevel: 'warning' }`
|
|
495
|
+
* - args: `['server', '--port', '80']`
|
|
496
|
+
*
|
|
497
|
+
* @param stopEarly Enable/disable stop early.
|
|
498
|
+
*/
|
|
499
|
+
stopEarly(stopEarly = true) {
|
|
500
|
+
this.cmd._stopEarly = stopEarly;
|
|
501
|
+
return this;
|
|
502
|
+
}
|
|
503
|
+
/**
|
|
504
|
+
* Disable parsing arguments. If enabled the raw arguments will be passed to
|
|
505
|
+
* the action handler. This has no effect for parent or child commands. Only
|
|
506
|
+
* for the command on which this method was called.
|
|
507
|
+
*
|
|
508
|
+
* @param useRawArgs Enable/disable raw arguments.
|
|
509
|
+
*/
|
|
510
|
+
useRawArgs(useRawArgs = true) {
|
|
511
|
+
this.cmd._useRawArgs = useRawArgs;
|
|
512
|
+
return this;
|
|
513
|
+
}
|
|
514
|
+
/**
|
|
515
|
+
* Set default command. The default command is executed when the program
|
|
516
|
+
* was called without any argument and if no action handler is registered.
|
|
517
|
+
*
|
|
518
|
+
* @param name Name of the default command.
|
|
519
|
+
*/
|
|
520
|
+
default(name) {
|
|
521
|
+
this.cmd.defaultCommand = name;
|
|
522
|
+
return this;
|
|
523
|
+
}
|
|
524
|
+
globalType(name, handler, options) {
|
|
525
|
+
return this.type(name, handler, { ...options, global: true });
|
|
526
|
+
}
|
|
527
|
+
/**
|
|
528
|
+
* Register custom type.
|
|
529
|
+
*
|
|
530
|
+
* @param name The name of the type.
|
|
531
|
+
* @param handler The callback method to parse the type.
|
|
532
|
+
* @param options Type options.
|
|
533
|
+
*/
|
|
534
|
+
type(name, handler, options) {
|
|
535
|
+
if (this.cmd.types.get(name) && !options?.override) {
|
|
536
|
+
throw new DuplicateTypeError(name);
|
|
537
|
+
}
|
|
538
|
+
this.cmd.types.set(name, {
|
|
539
|
+
...options,
|
|
540
|
+
name,
|
|
541
|
+
handler: handler,
|
|
542
|
+
});
|
|
543
|
+
if (handler instanceof Type &&
|
|
544
|
+
(typeof handler.complete !== "undefined" ||
|
|
545
|
+
typeof handler.values !== "undefined")) {
|
|
546
|
+
const completeHandler = (cmd, parent) => handler.complete?.(cmd, parent) || [];
|
|
547
|
+
this.complete(name, completeHandler, options);
|
|
548
|
+
}
|
|
549
|
+
return this;
|
|
550
|
+
}
|
|
551
|
+
/**
|
|
552
|
+
* Register global complete handler.
|
|
553
|
+
*
|
|
554
|
+
* @param name The name of the completion.
|
|
555
|
+
* @param complete The callback method to complete the type.
|
|
556
|
+
* @param options Complete options.
|
|
557
|
+
*/
|
|
558
|
+
globalComplete(name, complete, options) {
|
|
559
|
+
return this.complete(name, complete, { ...options, global: true });
|
|
560
|
+
}
|
|
561
|
+
complete(name, complete, options) {
|
|
562
|
+
if (this.cmd.completions.has(name) && !options?.override) {
|
|
563
|
+
throw new DuplicateCompletionError(name);
|
|
564
|
+
}
|
|
565
|
+
this.cmd.completions.set(name, {
|
|
566
|
+
name,
|
|
567
|
+
complete,
|
|
568
|
+
...options,
|
|
569
|
+
});
|
|
570
|
+
return this;
|
|
571
|
+
}
|
|
572
|
+
/**
|
|
573
|
+
* Throw validation errors instead of calling `exit()` to handle
|
|
574
|
+
* validation errors manually.
|
|
575
|
+
*
|
|
576
|
+
* A validation error is thrown when the command is wrongly used by the user.
|
|
577
|
+
* For example: If the user passes some invalid options or arguments to the
|
|
578
|
+
* command.
|
|
579
|
+
*
|
|
580
|
+
* This has no effect for parent commands. Only for the command on which this
|
|
581
|
+
* method was called and all child commands.
|
|
582
|
+
*
|
|
583
|
+
* **Example:**
|
|
584
|
+
*
|
|
585
|
+
* ```ts
|
|
586
|
+
* import { Command, ValidationError } from "./mod.ts";
|
|
587
|
+
*
|
|
588
|
+
* const cmd = new Command();
|
|
589
|
+
* // ...
|
|
590
|
+
*
|
|
591
|
+
* try {
|
|
592
|
+
* cmd.parse();
|
|
593
|
+
* } catch(error) {
|
|
594
|
+
* if (error instanceof ValidationError) {
|
|
595
|
+
* cmd.showHelp();
|
|
596
|
+
* Deno.exit(1);
|
|
597
|
+
* }
|
|
598
|
+
* throw error;
|
|
599
|
+
* }
|
|
600
|
+
* ```
|
|
601
|
+
*
|
|
602
|
+
* @see ValidationError
|
|
603
|
+
*/
|
|
604
|
+
throwErrors() {
|
|
605
|
+
this.cmd.throwOnError = true;
|
|
606
|
+
return this;
|
|
607
|
+
}
|
|
608
|
+
/**
|
|
609
|
+
* Set custom error handler.
|
|
610
|
+
*
|
|
611
|
+
* @param handler Error handler callback function.
|
|
612
|
+
*/
|
|
613
|
+
error(handler) {
|
|
614
|
+
this.cmd.errorHandler = handler;
|
|
615
|
+
return this;
|
|
616
|
+
}
|
|
617
|
+
/** Get error handler callback function. */
|
|
618
|
+
getErrorHandler() {
|
|
619
|
+
return this.errorHandler ?? this._parent?.errorHandler;
|
|
620
|
+
}
|
|
621
|
+
/**
|
|
622
|
+
* Same as `.throwErrors()` but also prevents calling `exit()` after
|
|
623
|
+
* printing help or version with the --help and --version option.
|
|
624
|
+
*/
|
|
625
|
+
noExit() {
|
|
626
|
+
this.cmd._shouldExit = false;
|
|
627
|
+
this.throwErrors();
|
|
628
|
+
return this;
|
|
629
|
+
}
|
|
630
|
+
/**
|
|
631
|
+
* Disable inheriting global commands, options and environment variables from
|
|
632
|
+
* parent commands.
|
|
633
|
+
*/
|
|
634
|
+
noGlobals() {
|
|
635
|
+
this.cmd._noGlobals = true;
|
|
636
|
+
return this;
|
|
637
|
+
}
|
|
638
|
+
/** Check whether the command should throw errors or exit. */
|
|
639
|
+
shouldThrowErrors() {
|
|
640
|
+
return this.throwOnError || !!this._parent?.shouldThrowErrors();
|
|
641
|
+
}
|
|
642
|
+
/** Check whether the command should exit after printing help or version. */
|
|
643
|
+
shouldExit() {
|
|
644
|
+
return this._shouldExit ?? this._parent?.shouldExit() ?? true;
|
|
645
|
+
}
|
|
646
|
+
/**
|
|
647
|
+
* Enable grouping of options and set the name of the group.
|
|
648
|
+
* All option which are added after calling the `.group()` method will be
|
|
649
|
+
* grouped in the help output. If the `.group()` method can be use multiple
|
|
650
|
+
* times to create more groups.
|
|
651
|
+
*
|
|
652
|
+
* @param name The name of the option group.
|
|
653
|
+
*/
|
|
654
|
+
group(name) {
|
|
655
|
+
this.cmd._groupName = name;
|
|
656
|
+
return this;
|
|
657
|
+
}
|
|
658
|
+
/**
|
|
659
|
+
* Register a global option.
|
|
660
|
+
*
|
|
661
|
+
* @param flags Flags string e.g: -h, --help, --manual <requiredArg:string> [optionalArg:number] [...restArgs:string]
|
|
662
|
+
* @param desc Flag description.
|
|
663
|
+
* @param opts Flag options or custom handler for processing flag value.
|
|
664
|
+
*/
|
|
665
|
+
globalOption(flags, desc, opts) {
|
|
666
|
+
if (typeof opts === "function") {
|
|
667
|
+
return this.option(flags, desc, { value: opts, global: true });
|
|
668
|
+
}
|
|
669
|
+
return this.option(flags, desc, { ...opts, global: true });
|
|
670
|
+
}
|
|
671
|
+
option(flags, desc, opts) {
|
|
672
|
+
if (typeof opts === "function") {
|
|
673
|
+
opts = { value: opts };
|
|
674
|
+
}
|
|
675
|
+
const result = splitArguments(flags);
|
|
676
|
+
const args = result.typeDefinition
|
|
677
|
+
? parseArgumentsDefinition(result.typeDefinition)
|
|
678
|
+
: [];
|
|
679
|
+
const option = {
|
|
680
|
+
...opts,
|
|
681
|
+
name: "",
|
|
682
|
+
description: desc,
|
|
683
|
+
args,
|
|
684
|
+
flags: result.flags,
|
|
685
|
+
equalsSign: result.equalsSign,
|
|
686
|
+
typeDefinition: result.typeDefinition,
|
|
687
|
+
groupName: this._groupName ?? undefined,
|
|
688
|
+
};
|
|
689
|
+
if (option.separator) {
|
|
690
|
+
for (const arg of args) {
|
|
691
|
+
if (arg.list) {
|
|
692
|
+
arg.separator = option.separator;
|
|
693
|
+
}
|
|
694
|
+
}
|
|
695
|
+
}
|
|
696
|
+
for (const part of option.flags) {
|
|
697
|
+
const arg = part.trim();
|
|
698
|
+
const isLong = /^--/.test(arg);
|
|
699
|
+
const name = isLong ? arg.slice(2) : arg.slice(1);
|
|
700
|
+
if (this.cmd.getBaseOption(name, true)) {
|
|
701
|
+
if (opts?.override) {
|
|
702
|
+
this.removeOption(name);
|
|
703
|
+
}
|
|
704
|
+
else {
|
|
705
|
+
throw new DuplicateOptionNameError(name, this.getPath());
|
|
706
|
+
}
|
|
707
|
+
}
|
|
708
|
+
if (!option.name && isLong) {
|
|
709
|
+
option.name = name;
|
|
710
|
+
}
|
|
711
|
+
else if (!option.aliases) {
|
|
712
|
+
option.aliases = [name];
|
|
713
|
+
}
|
|
714
|
+
else {
|
|
715
|
+
option.aliases.push(name);
|
|
716
|
+
}
|
|
717
|
+
}
|
|
718
|
+
if (option.prepend) {
|
|
719
|
+
this.cmd.options.unshift(option);
|
|
720
|
+
}
|
|
721
|
+
else {
|
|
722
|
+
this.cmd.options.push(option);
|
|
723
|
+
}
|
|
724
|
+
return this;
|
|
725
|
+
}
|
|
726
|
+
/**
|
|
727
|
+
* Register command example.
|
|
728
|
+
*
|
|
729
|
+
* @param name Name of the example.
|
|
730
|
+
* @param description The content of the example.
|
|
731
|
+
*/
|
|
732
|
+
example(name, description) {
|
|
733
|
+
if (this.cmd.hasExample(name)) {
|
|
734
|
+
throw new DuplicateExampleError(name);
|
|
735
|
+
}
|
|
736
|
+
this.cmd.examples.push({ name, description });
|
|
737
|
+
return this;
|
|
738
|
+
}
|
|
739
|
+
/**
|
|
740
|
+
* @param flags Flags string e.g: -h, --help, --manual <requiredArg:string> [optionalArg:number] [...restArgs:string]
|
|
741
|
+
* @param desc Flag description.
|
|
742
|
+
* @param opts Flag options or custom handler for processing flag value.
|
|
743
|
+
*/
|
|
744
|
+
/**
|
|
745
|
+
* Register a global environment variable.
|
|
746
|
+
*
|
|
747
|
+
* @param name Name of the environment variable.
|
|
748
|
+
* @param description The description of the environment variable.
|
|
749
|
+
* @param options Environment variable options.
|
|
750
|
+
*/
|
|
751
|
+
globalEnv(name, description, options) {
|
|
752
|
+
return this.env(name, description, { ...options, global: true });
|
|
753
|
+
}
|
|
754
|
+
env(name, description, options) {
|
|
755
|
+
const result = splitArguments(name);
|
|
756
|
+
if (!result.typeDefinition) {
|
|
757
|
+
result.typeDefinition = "<value:boolean>";
|
|
758
|
+
}
|
|
759
|
+
if (result.flags.some((envName) => this.cmd.getBaseEnvVar(envName, true))) {
|
|
760
|
+
throw new DuplicateEnvVarError(name);
|
|
761
|
+
}
|
|
762
|
+
const details = parseArgumentsDefinition(result.typeDefinition);
|
|
763
|
+
if (details.length > 1) {
|
|
764
|
+
throw new TooManyEnvVarValuesError(name);
|
|
765
|
+
}
|
|
766
|
+
else if (details.length && details[0].optional) {
|
|
767
|
+
throw new UnexpectedOptionalEnvVarValueError(name);
|
|
768
|
+
}
|
|
769
|
+
else if (details.length && details[0].variadic) {
|
|
770
|
+
throw new UnexpectedVariadicEnvVarValueError(name);
|
|
771
|
+
}
|
|
772
|
+
this.cmd.envVars.push({
|
|
773
|
+
name: result.flags[0],
|
|
774
|
+
names: result.flags,
|
|
775
|
+
description,
|
|
776
|
+
type: details[0].type,
|
|
777
|
+
details: details.shift(),
|
|
778
|
+
...options,
|
|
779
|
+
});
|
|
780
|
+
return this;
|
|
781
|
+
}
|
|
782
|
+
/*****************************************************************************
|
|
783
|
+
**** MAIN HANDLER ***********************************************************
|
|
784
|
+
*****************************************************************************/
|
|
785
|
+
/**
|
|
786
|
+
* Parse command line arguments and execute matched command.
|
|
787
|
+
*
|
|
788
|
+
* @param args Command line args to parse. Ex: `cmd.parse( Deno.args )`
|
|
789
|
+
*/
|
|
790
|
+
parse(args = getArgs()) {
|
|
791
|
+
const ctx = {
|
|
792
|
+
unknown: args.slice(),
|
|
793
|
+
flags: {},
|
|
794
|
+
env: {},
|
|
795
|
+
literal: [],
|
|
796
|
+
stopEarly: false,
|
|
797
|
+
stopOnUnknown: false,
|
|
798
|
+
defaults: {},
|
|
799
|
+
actions: [],
|
|
800
|
+
};
|
|
801
|
+
return this.parseCommand(ctx);
|
|
802
|
+
}
|
|
803
|
+
async parseCommand(ctx) {
|
|
804
|
+
try {
|
|
805
|
+
this.reset();
|
|
806
|
+
this.registerDefaults();
|
|
807
|
+
this.rawArgs = ctx.unknown.slice();
|
|
808
|
+
if (this._useRawArgs) {
|
|
809
|
+
await this.parseEnvVars(ctx, this.envVars);
|
|
810
|
+
return await this.execute(ctx.env, ctx.unknown);
|
|
811
|
+
}
|
|
812
|
+
let preParseGlobals = false;
|
|
813
|
+
let subCommand;
|
|
814
|
+
// Pre parse globals to support: cmd --global-option sub-command --option
|
|
815
|
+
if (ctx.unknown.length > 0) {
|
|
816
|
+
// Detect sub command.
|
|
817
|
+
subCommand = this.getSubCommand(ctx);
|
|
818
|
+
if (!subCommand) {
|
|
819
|
+
// Only pre parse globals if first arg ist a global option.
|
|
820
|
+
const optionName = ctx.unknown[0].replace(/^-+/, "");
|
|
821
|
+
const option = this.getOption(optionName, true);
|
|
822
|
+
if (option?.global) {
|
|
823
|
+
preParseGlobals = true;
|
|
824
|
+
await this.parseGlobalOptionsAndEnvVars(ctx);
|
|
825
|
+
}
|
|
826
|
+
}
|
|
827
|
+
}
|
|
828
|
+
if (subCommand || ctx.unknown.length > 0) {
|
|
829
|
+
subCommand ??= this.getSubCommand(ctx);
|
|
830
|
+
if (subCommand) {
|
|
831
|
+
subCommand._globalParent = this;
|
|
832
|
+
return subCommand.parseCommand(ctx);
|
|
833
|
+
}
|
|
834
|
+
}
|
|
835
|
+
// Parse rest options & env vars.
|
|
836
|
+
await this.parseOptionsAndEnvVars(ctx, preParseGlobals);
|
|
837
|
+
const options = { ...ctx.env, ...ctx.flags };
|
|
838
|
+
const args = this.parseArguments(ctx, options);
|
|
839
|
+
this.literalArgs = ctx.literal;
|
|
840
|
+
// Execute option action.
|
|
841
|
+
if (ctx.actions.length) {
|
|
842
|
+
await Promise.all(ctx.actions.map((action) => action.call(this, options, ...args)));
|
|
843
|
+
if (ctx.standalone) {
|
|
844
|
+
return {
|
|
845
|
+
options,
|
|
846
|
+
args,
|
|
847
|
+
cmd: this,
|
|
848
|
+
literal: this.literalArgs,
|
|
849
|
+
};
|
|
850
|
+
}
|
|
851
|
+
}
|
|
852
|
+
return await this.execute(options, args);
|
|
853
|
+
}
|
|
854
|
+
catch (error) {
|
|
855
|
+
this.handleError(error);
|
|
856
|
+
}
|
|
857
|
+
}
|
|
858
|
+
getSubCommand(ctx) {
|
|
859
|
+
const subCommand = this.getCommand(ctx.unknown[0], true);
|
|
860
|
+
if (subCommand) {
|
|
861
|
+
ctx.unknown.shift();
|
|
862
|
+
}
|
|
863
|
+
return subCommand;
|
|
864
|
+
}
|
|
865
|
+
async parseGlobalOptionsAndEnvVars(ctx) {
|
|
866
|
+
const isHelpOption = this.getHelpOption()?.flags.includes(ctx.unknown[0]);
|
|
867
|
+
// Parse global env vars.
|
|
868
|
+
const envVars = [
|
|
869
|
+
...this.envVars.filter((envVar) => envVar.global),
|
|
870
|
+
...this.getGlobalEnvVars(true),
|
|
871
|
+
];
|
|
872
|
+
await this.parseEnvVars(ctx, envVars, !isHelpOption);
|
|
873
|
+
// Parse global options.
|
|
874
|
+
const options = [
|
|
875
|
+
...this.options.filter((option) => option.global),
|
|
876
|
+
...this.getGlobalOptions(true),
|
|
877
|
+
];
|
|
878
|
+
this.parseOptions(ctx, options, {
|
|
879
|
+
stopEarly: true,
|
|
880
|
+
stopOnUnknown: true,
|
|
881
|
+
dotted: false,
|
|
882
|
+
});
|
|
883
|
+
}
|
|
884
|
+
async parseOptionsAndEnvVars(ctx, preParseGlobals) {
|
|
885
|
+
const helpOption = this.getHelpOption();
|
|
886
|
+
const isVersionOption = this._versionOption?.flags.includes(ctx.unknown[0]);
|
|
887
|
+
const isHelpOption = helpOption && ctx.flags?.[helpOption.name] === true;
|
|
888
|
+
// Parse env vars.
|
|
889
|
+
const envVars = preParseGlobals
|
|
890
|
+
? this.envVars.filter((envVar) => !envVar.global)
|
|
891
|
+
: this.getEnvVars(true);
|
|
892
|
+
await this.parseEnvVars(ctx, envVars, !isHelpOption && !isVersionOption);
|
|
893
|
+
// Parse options.
|
|
894
|
+
const options = this.getOptions(true);
|
|
895
|
+
this.parseOptions(ctx, options);
|
|
896
|
+
}
|
|
897
|
+
/** Register default options like `--version` and `--help`. */
|
|
898
|
+
registerDefaults() {
|
|
899
|
+
if (this.hasDefaults || this.getParent()) {
|
|
900
|
+
return this;
|
|
901
|
+
}
|
|
902
|
+
this.hasDefaults = true;
|
|
903
|
+
this.reset();
|
|
904
|
+
!this.types.has("string") &&
|
|
905
|
+
this.type("string", new StringType(), { global: true });
|
|
906
|
+
!this.types.has("number") &&
|
|
907
|
+
this.type("number", new NumberType(), { global: true });
|
|
908
|
+
!this.types.has("integer") &&
|
|
909
|
+
this.type("integer", new IntegerType(), { global: true });
|
|
910
|
+
!this.types.has("boolean") &&
|
|
911
|
+
this.type("boolean", new BooleanType(), { global: true });
|
|
912
|
+
!this.types.has("file") &&
|
|
913
|
+
this.type("file", new FileType(), { global: true });
|
|
914
|
+
if (!this._help) {
|
|
915
|
+
this.help({});
|
|
916
|
+
}
|
|
917
|
+
if (this._versionOptions !== false && (this._versionOptions || this.ver)) {
|
|
918
|
+
this.option(this._versionOptions?.flags || "-V, --version", this._versionOptions?.desc ||
|
|
919
|
+
"Show the version number for this program.", {
|
|
920
|
+
standalone: true,
|
|
921
|
+
prepend: true,
|
|
922
|
+
action: async function () {
|
|
923
|
+
const long = this.getRawArgs().includes(`--${this._versionOption?.name}`);
|
|
924
|
+
if (long) {
|
|
925
|
+
await checkVersion(this);
|
|
926
|
+
this.showLongVersion();
|
|
927
|
+
}
|
|
928
|
+
else {
|
|
929
|
+
this.showVersion();
|
|
930
|
+
}
|
|
931
|
+
this.exit();
|
|
932
|
+
},
|
|
933
|
+
...(this._versionOptions?.opts ?? {}),
|
|
934
|
+
});
|
|
935
|
+
this._versionOption = this.options[0];
|
|
936
|
+
}
|
|
937
|
+
if (this._helpOptions !== false) {
|
|
938
|
+
this.option(this._helpOptions?.flags || "-h, --help", this._helpOptions?.desc || "Show this help.", {
|
|
939
|
+
standalone: true,
|
|
940
|
+
global: true,
|
|
941
|
+
prepend: true,
|
|
942
|
+
action: async function () {
|
|
943
|
+
const long = this.getRawArgs().includes(`--${this.getHelpOption()?.name}`);
|
|
944
|
+
await checkVersion(this);
|
|
945
|
+
this.showHelp({ long });
|
|
946
|
+
this.exit();
|
|
947
|
+
},
|
|
948
|
+
...(this._helpOptions?.opts ?? {}),
|
|
949
|
+
});
|
|
950
|
+
this._helpOption = this.options[0];
|
|
951
|
+
}
|
|
952
|
+
return this;
|
|
953
|
+
}
|
|
954
|
+
/**
|
|
955
|
+
* Execute command.
|
|
956
|
+
* @param options A map of options.
|
|
957
|
+
* @param args Command arguments.
|
|
958
|
+
*/
|
|
959
|
+
async execute(options, args) {
|
|
960
|
+
if (this.defaultCommand) {
|
|
961
|
+
const cmd = this.getCommand(this.defaultCommand, true);
|
|
962
|
+
if (!cmd) {
|
|
963
|
+
throw new DefaultCommandNotFoundError(this.defaultCommand, this.getCommands());
|
|
964
|
+
}
|
|
965
|
+
cmd._globalParent = this;
|
|
966
|
+
return cmd.execute(options, args);
|
|
967
|
+
}
|
|
968
|
+
await this.executeGlobalAction(options, args);
|
|
969
|
+
if (this.actionHandler) {
|
|
970
|
+
await this.actionHandler(options, ...args);
|
|
971
|
+
}
|
|
972
|
+
return {
|
|
973
|
+
options,
|
|
974
|
+
args,
|
|
975
|
+
cmd: this,
|
|
976
|
+
literal: this.literalArgs,
|
|
977
|
+
};
|
|
978
|
+
}
|
|
979
|
+
async executeGlobalAction(options, args) {
|
|
980
|
+
if (!this._noGlobals) {
|
|
981
|
+
await this._parent?.executeGlobalAction(options, args);
|
|
982
|
+
}
|
|
983
|
+
await this.globalActionHandler?.(options, ...args);
|
|
984
|
+
}
|
|
985
|
+
/** Parse raw command line arguments. */
|
|
986
|
+
parseOptions(ctx, options, { stopEarly = this._stopEarly, stopOnUnknown = false, dotted = true, } = {}) {
|
|
987
|
+
parseFlags(ctx, {
|
|
988
|
+
stopEarly,
|
|
989
|
+
stopOnUnknown,
|
|
990
|
+
dotted,
|
|
991
|
+
allowEmpty: this._allowEmpty,
|
|
992
|
+
flags: options,
|
|
993
|
+
ignoreDefaults: ctx.env,
|
|
994
|
+
parse: (type) => this.parseType(type),
|
|
995
|
+
option: (option) => {
|
|
996
|
+
if (option.action) {
|
|
997
|
+
ctx.actions.push(option.action);
|
|
998
|
+
}
|
|
999
|
+
},
|
|
1000
|
+
});
|
|
1001
|
+
}
|
|
1002
|
+
/** Parse argument type. */
|
|
1003
|
+
parseType(type) {
|
|
1004
|
+
const typeSettings = this.getType(type.type);
|
|
1005
|
+
if (!typeSettings) {
|
|
1006
|
+
throw new UnknownTypeError(type.type, this.getTypes().map((type) => type.name));
|
|
1007
|
+
}
|
|
1008
|
+
return typeSettings.handler instanceof Type
|
|
1009
|
+
? typeSettings.handler.parse(type)
|
|
1010
|
+
: typeSettings.handler(type);
|
|
1011
|
+
}
|
|
1012
|
+
/**
|
|
1013
|
+
* Read and validate environment variables.
|
|
1014
|
+
* @param ctx Parse context.
|
|
1015
|
+
* @param envVars env vars defined by the command.
|
|
1016
|
+
* @param validate when true, throws an error if a required env var is missing.
|
|
1017
|
+
*/
|
|
1018
|
+
async parseEnvVars(ctx, envVars, validate = true) {
|
|
1019
|
+
for (const envVar of envVars) {
|
|
1020
|
+
const env = await this.findEnvVar(envVar.names);
|
|
1021
|
+
if (env) {
|
|
1022
|
+
const parseType = (value) => {
|
|
1023
|
+
return this.parseType({
|
|
1024
|
+
label: "Environment variable",
|
|
1025
|
+
type: envVar.type,
|
|
1026
|
+
name: env.name,
|
|
1027
|
+
value,
|
|
1028
|
+
});
|
|
1029
|
+
};
|
|
1030
|
+
const propertyName = underscoreToCamelCase(envVar.prefix
|
|
1031
|
+
? envVar.names[0].replace(new RegExp(`^${envVar.prefix}`), "")
|
|
1032
|
+
: envVar.names[0]);
|
|
1033
|
+
if (envVar.details.list) {
|
|
1034
|
+
ctx.env[propertyName] = env.value
|
|
1035
|
+
.split(envVar.details.separator ?? ",")
|
|
1036
|
+
.map(parseType);
|
|
1037
|
+
}
|
|
1038
|
+
else {
|
|
1039
|
+
ctx.env[propertyName] = parseType(env.value);
|
|
1040
|
+
}
|
|
1041
|
+
if (envVar.value && typeof ctx.env[propertyName] !== "undefined") {
|
|
1042
|
+
ctx.env[propertyName] = envVar.value(ctx.env[propertyName]);
|
|
1043
|
+
}
|
|
1044
|
+
}
|
|
1045
|
+
else if (envVar.required && validate) {
|
|
1046
|
+
throw new MissingRequiredEnvVarError(envVar);
|
|
1047
|
+
}
|
|
1048
|
+
}
|
|
1049
|
+
}
|
|
1050
|
+
async findEnvVar(names) {
|
|
1051
|
+
for (const name of names) {
|
|
1052
|
+
const status = await dntShim.dntGlobalThis.Deno?.permissions.query({
|
|
1053
|
+
name: "env",
|
|
1054
|
+
variable: name,
|
|
1055
|
+
});
|
|
1056
|
+
if (!status || status.state === "granted") {
|
|
1057
|
+
const value = getEnv(name);
|
|
1058
|
+
if (value) {
|
|
1059
|
+
return { name, value };
|
|
1060
|
+
}
|
|
1061
|
+
}
|
|
1062
|
+
}
|
|
1063
|
+
return undefined;
|
|
1064
|
+
}
|
|
1065
|
+
/**
|
|
1066
|
+
* Parse command-line arguments.
|
|
1067
|
+
* @param ctx Parse context.
|
|
1068
|
+
* @param options Parsed command line options.
|
|
1069
|
+
*/
|
|
1070
|
+
parseArguments(ctx, options) {
|
|
1071
|
+
const params = [];
|
|
1072
|
+
const args = ctx.unknown.slice();
|
|
1073
|
+
if (!this.hasArguments()) {
|
|
1074
|
+
if (args.length) {
|
|
1075
|
+
if (this.hasCommands(true)) {
|
|
1076
|
+
if (this.hasCommand(args[0], true)) {
|
|
1077
|
+
// e.g: command --global-foo --foo sub-command
|
|
1078
|
+
throw new TooManyArgumentsError(args);
|
|
1079
|
+
}
|
|
1080
|
+
else {
|
|
1081
|
+
throw new UnknownCommandError(args[0], this.getCommands());
|
|
1082
|
+
}
|
|
1083
|
+
}
|
|
1084
|
+
else {
|
|
1085
|
+
throw new NoArgumentsAllowedError(this.getPath());
|
|
1086
|
+
}
|
|
1087
|
+
}
|
|
1088
|
+
}
|
|
1089
|
+
else {
|
|
1090
|
+
if (!args.length) {
|
|
1091
|
+
const required = this.getArguments()
|
|
1092
|
+
.filter((expectedArg) => !expectedArg.optional)
|
|
1093
|
+
.map((expectedArg) => expectedArg.name);
|
|
1094
|
+
if (required.length) {
|
|
1095
|
+
const optionNames = Object.keys(options);
|
|
1096
|
+
const hasStandaloneOption = !!optionNames.find((name) => this.getOption(name, true)?.standalone);
|
|
1097
|
+
if (!hasStandaloneOption) {
|
|
1098
|
+
throw new MissingArgumentsError(required);
|
|
1099
|
+
}
|
|
1100
|
+
}
|
|
1101
|
+
}
|
|
1102
|
+
else {
|
|
1103
|
+
for (const expectedArg of this.getArguments()) {
|
|
1104
|
+
if (!args.length) {
|
|
1105
|
+
if (expectedArg.optional) {
|
|
1106
|
+
break;
|
|
1107
|
+
}
|
|
1108
|
+
throw new MissingArgumentError(expectedArg.name);
|
|
1109
|
+
}
|
|
1110
|
+
let arg;
|
|
1111
|
+
const parseArgValue = (value) => {
|
|
1112
|
+
return expectedArg.list
|
|
1113
|
+
? value.split(",").map((value) => parseArgType(value))
|
|
1114
|
+
: parseArgType(value);
|
|
1115
|
+
};
|
|
1116
|
+
const parseArgType = (value) => {
|
|
1117
|
+
return this.parseType({
|
|
1118
|
+
label: "Argument",
|
|
1119
|
+
type: expectedArg.type,
|
|
1120
|
+
name: expectedArg.name,
|
|
1121
|
+
value,
|
|
1122
|
+
});
|
|
1123
|
+
};
|
|
1124
|
+
if (expectedArg.variadic) {
|
|
1125
|
+
arg = args.splice(0, args.length).map((value) => parseArgValue(value));
|
|
1126
|
+
}
|
|
1127
|
+
else {
|
|
1128
|
+
arg = parseArgValue(args.shift());
|
|
1129
|
+
}
|
|
1130
|
+
if (expectedArg.variadic && Array.isArray(arg)) {
|
|
1131
|
+
params.push(...arg);
|
|
1132
|
+
}
|
|
1133
|
+
else if (typeof arg !== "undefined") {
|
|
1134
|
+
params.push(arg);
|
|
1135
|
+
}
|
|
1136
|
+
}
|
|
1137
|
+
if (args.length) {
|
|
1138
|
+
throw new TooManyArgumentsError(args);
|
|
1139
|
+
}
|
|
1140
|
+
}
|
|
1141
|
+
}
|
|
1142
|
+
return params;
|
|
1143
|
+
}
|
|
1144
|
+
handleError(error) {
|
|
1145
|
+
this.throw(error instanceof FlagsValidationError
|
|
1146
|
+
? new ValidationError(error.message)
|
|
1147
|
+
: error instanceof Error
|
|
1148
|
+
? error
|
|
1149
|
+
: new Error(`[non-error-thrown] ${error}`));
|
|
1150
|
+
}
|
|
1151
|
+
/**
|
|
1152
|
+
* Handle error. If `throwErrors` is enabled the error will be thrown,
|
|
1153
|
+
* otherwise a formatted error message will be printed and `exit(1)`
|
|
1154
|
+
* will be called. This will also trigger registered error handlers.
|
|
1155
|
+
*
|
|
1156
|
+
* @param error The error to handle.
|
|
1157
|
+
*/
|
|
1158
|
+
throw(error) {
|
|
1159
|
+
if (error instanceof ValidationError) {
|
|
1160
|
+
error.cmd = this;
|
|
1161
|
+
}
|
|
1162
|
+
this.getErrorHandler()?.(error, this);
|
|
1163
|
+
if (this.shouldThrowErrors() || !(error instanceof ValidationError)) {
|
|
1164
|
+
throw error;
|
|
1165
|
+
}
|
|
1166
|
+
this.showHelp();
|
|
1167
|
+
console.error(red(` ${bold("error")}: ${error.message}\n`));
|
|
1168
|
+
exit(error instanceof ValidationError ? error.exitCode : 1);
|
|
1169
|
+
}
|
|
1170
|
+
/*****************************************************************************
|
|
1171
|
+
**** GETTER *****************************************************************
|
|
1172
|
+
*****************************************************************************/
|
|
1173
|
+
/** Get command name. */
|
|
1174
|
+
getName() {
|
|
1175
|
+
return this._name;
|
|
1176
|
+
}
|
|
1177
|
+
/** Get parent command. */
|
|
1178
|
+
getParent() {
|
|
1179
|
+
return this._parent;
|
|
1180
|
+
}
|
|
1181
|
+
/**
|
|
1182
|
+
* Get parent command from global executed command.
|
|
1183
|
+
* Be sure, to call this method only inside an action handler. Unless this or any child command was executed,
|
|
1184
|
+
* this method returns always undefined.
|
|
1185
|
+
*/
|
|
1186
|
+
getGlobalParent() {
|
|
1187
|
+
return this._globalParent;
|
|
1188
|
+
}
|
|
1189
|
+
/** Get main command. */
|
|
1190
|
+
getMainCommand() {
|
|
1191
|
+
return this._parent?.getMainCommand() ?? this;
|
|
1192
|
+
}
|
|
1193
|
+
/** Get command name aliases. */
|
|
1194
|
+
getAliases() {
|
|
1195
|
+
return this.aliases;
|
|
1196
|
+
}
|
|
1197
|
+
/**
|
|
1198
|
+
* Get full command path.
|
|
1199
|
+
*
|
|
1200
|
+
* @param name Override the main command name.
|
|
1201
|
+
*/
|
|
1202
|
+
getPath(name) {
|
|
1203
|
+
return this._parent
|
|
1204
|
+
? this._parent.getPath(name) + " " + this._name
|
|
1205
|
+
: name || this._name;
|
|
1206
|
+
}
|
|
1207
|
+
/** Get arguments definition. E.g: <input-file:string> <output-file:string> */
|
|
1208
|
+
getArgsDefinition() {
|
|
1209
|
+
return this.argsDefinition;
|
|
1210
|
+
}
|
|
1211
|
+
/**
|
|
1212
|
+
* Get argument by name.
|
|
1213
|
+
*
|
|
1214
|
+
* @param name Name of the argument.
|
|
1215
|
+
*/
|
|
1216
|
+
getArgument(name) {
|
|
1217
|
+
return this.getArguments().find((arg) => arg.name === name);
|
|
1218
|
+
}
|
|
1219
|
+
/** Get arguments. */
|
|
1220
|
+
getArguments() {
|
|
1221
|
+
if (!this.args.length && this.argsDefinition) {
|
|
1222
|
+
this.args = parseArgumentsDefinition(this.argsDefinition);
|
|
1223
|
+
}
|
|
1224
|
+
return this.args;
|
|
1225
|
+
}
|
|
1226
|
+
/** Check if command has arguments. */
|
|
1227
|
+
hasArguments() {
|
|
1228
|
+
return !!this.argsDefinition;
|
|
1229
|
+
}
|
|
1230
|
+
/** Get command version. */
|
|
1231
|
+
getVersion() {
|
|
1232
|
+
return this.getVersionHandler()?.call(this, this);
|
|
1233
|
+
}
|
|
1234
|
+
/** Get help handler method. */
|
|
1235
|
+
getVersionHandler() {
|
|
1236
|
+
return this.ver ?? this._parent?.getVersionHandler();
|
|
1237
|
+
}
|
|
1238
|
+
/** Get command description. */
|
|
1239
|
+
getDescription() {
|
|
1240
|
+
// call description method only once
|
|
1241
|
+
return typeof this.desc === "function"
|
|
1242
|
+
? this.desc = this.desc()
|
|
1243
|
+
: this.desc;
|
|
1244
|
+
}
|
|
1245
|
+
/** Get auto generated command usage. */
|
|
1246
|
+
getUsage() {
|
|
1247
|
+
return this._usage ??
|
|
1248
|
+
[this.getArgsDefinition(), this.getRequiredOptionsDefinition()]
|
|
1249
|
+
.join(" ")
|
|
1250
|
+
.trim();
|
|
1251
|
+
}
|
|
1252
|
+
getRequiredOptionsDefinition() {
|
|
1253
|
+
return this.getOptions()
|
|
1254
|
+
.filter((option) => option.required)
|
|
1255
|
+
.map((option) => [findFlag(option.flags), option.typeDefinition].filter((v) => v)
|
|
1256
|
+
.join(" ")
|
|
1257
|
+
.trim())
|
|
1258
|
+
.join(" ");
|
|
1259
|
+
}
|
|
1260
|
+
/** Get short command description. This is the first line of the description. */
|
|
1261
|
+
getShortDescription() {
|
|
1262
|
+
return getDescription(this.getDescription(), true);
|
|
1263
|
+
}
|
|
1264
|
+
/** Get original command-line arguments. */
|
|
1265
|
+
getRawArgs() {
|
|
1266
|
+
return this.rawArgs;
|
|
1267
|
+
}
|
|
1268
|
+
/** Get all arguments defined after the double dash. */
|
|
1269
|
+
getLiteralArgs() {
|
|
1270
|
+
return this.literalArgs;
|
|
1271
|
+
}
|
|
1272
|
+
/** Output generated help without exiting. */
|
|
1273
|
+
showVersion() {
|
|
1274
|
+
console.log(this.getVersion());
|
|
1275
|
+
}
|
|
1276
|
+
/** Returns command name, version and meta data. */
|
|
1277
|
+
getLongVersion() {
|
|
1278
|
+
return `${bold(this.getMainCommand().getName())} ${brightBlue(this.getVersion() ?? "")}` +
|
|
1279
|
+
Object.entries(this.getMeta()).map(([k, v]) => `\n${bold(k)} ${brightBlue(v)}`).join("");
|
|
1280
|
+
}
|
|
1281
|
+
/** Outputs command name, version and meta data. */
|
|
1282
|
+
showLongVersion() {
|
|
1283
|
+
console.log(this.getLongVersion());
|
|
1284
|
+
}
|
|
1285
|
+
/** Output generated help without exiting. */
|
|
1286
|
+
showHelp(options) {
|
|
1287
|
+
console.log(this.getHelp(options));
|
|
1288
|
+
}
|
|
1289
|
+
/** Get generated help. */
|
|
1290
|
+
getHelp(options) {
|
|
1291
|
+
this.registerDefaults();
|
|
1292
|
+
return this.getHelpHandler().call(this, this, options ?? {});
|
|
1293
|
+
}
|
|
1294
|
+
/** Get help handler method. */
|
|
1295
|
+
getHelpHandler() {
|
|
1296
|
+
return this._help ?? this._parent?.getHelpHandler();
|
|
1297
|
+
}
|
|
1298
|
+
exit(code = 0) {
|
|
1299
|
+
if (this.shouldExit()) {
|
|
1300
|
+
exit(code);
|
|
1301
|
+
}
|
|
1302
|
+
}
|
|
1303
|
+
/*****************************************************************************
|
|
1304
|
+
**** Options GETTER *********************************************************
|
|
1305
|
+
*****************************************************************************/
|
|
1306
|
+
/**
|
|
1307
|
+
* Checks whether the command has options or not.
|
|
1308
|
+
*
|
|
1309
|
+
* @param hidden Include hidden options.
|
|
1310
|
+
*/
|
|
1311
|
+
hasOptions(hidden) {
|
|
1312
|
+
return this.getOptions(hidden).length > 0;
|
|
1313
|
+
}
|
|
1314
|
+
/**
|
|
1315
|
+
* Get options.
|
|
1316
|
+
*
|
|
1317
|
+
* @param hidden Include hidden options.
|
|
1318
|
+
*/
|
|
1319
|
+
getOptions(hidden) {
|
|
1320
|
+
return this.getGlobalOptions(hidden).concat(this.getBaseOptions(hidden));
|
|
1321
|
+
}
|
|
1322
|
+
/**
|
|
1323
|
+
* Get base options.
|
|
1324
|
+
*
|
|
1325
|
+
* @param hidden Include hidden options.
|
|
1326
|
+
*/
|
|
1327
|
+
getBaseOptions(hidden) {
|
|
1328
|
+
if (!this.options.length) {
|
|
1329
|
+
return [];
|
|
1330
|
+
}
|
|
1331
|
+
return hidden
|
|
1332
|
+
? this.options.slice(0)
|
|
1333
|
+
: this.options.filter((opt) => !opt.hidden);
|
|
1334
|
+
}
|
|
1335
|
+
/**
|
|
1336
|
+
* Get global options.
|
|
1337
|
+
*
|
|
1338
|
+
* @param hidden Include hidden options.
|
|
1339
|
+
*/
|
|
1340
|
+
getGlobalOptions(hidden) {
|
|
1341
|
+
const helpOption = this.getHelpOption();
|
|
1342
|
+
const getGlobals = (cmd, noGlobals, options = [], names = []) => {
|
|
1343
|
+
if (cmd.options.length) {
|
|
1344
|
+
for (const option of cmd.options) {
|
|
1345
|
+
if (option.global &&
|
|
1346
|
+
!this.options.find((opt) => opt.name === option.name) &&
|
|
1347
|
+
names.indexOf(option.name) === -1 &&
|
|
1348
|
+
(hidden || !option.hidden)) {
|
|
1349
|
+
if (noGlobals && option !== helpOption) {
|
|
1350
|
+
continue;
|
|
1351
|
+
}
|
|
1352
|
+
names.push(option.name);
|
|
1353
|
+
options.push(option);
|
|
1354
|
+
}
|
|
1355
|
+
}
|
|
1356
|
+
}
|
|
1357
|
+
return cmd._parent
|
|
1358
|
+
? getGlobals(cmd._parent, noGlobals || cmd._noGlobals, options, names)
|
|
1359
|
+
: options;
|
|
1360
|
+
};
|
|
1361
|
+
return this._parent ? getGlobals(this._parent, this._noGlobals) : [];
|
|
1362
|
+
}
|
|
1363
|
+
/**
|
|
1364
|
+
* Checks whether the command has an option with given name or not.
|
|
1365
|
+
*
|
|
1366
|
+
* @param name Name of the option. Must be in param-case.
|
|
1367
|
+
* @param hidden Include hidden options.
|
|
1368
|
+
*/
|
|
1369
|
+
hasOption(name, hidden) {
|
|
1370
|
+
return !!this.getOption(name, hidden);
|
|
1371
|
+
}
|
|
1372
|
+
/**
|
|
1373
|
+
* Get option by name.
|
|
1374
|
+
*
|
|
1375
|
+
* @param name Name of the option. Must be in param-case.
|
|
1376
|
+
* @param hidden Include hidden options.
|
|
1377
|
+
*/
|
|
1378
|
+
getOption(name, hidden) {
|
|
1379
|
+
return this.getBaseOption(name, hidden) ??
|
|
1380
|
+
this.getGlobalOption(name, hidden);
|
|
1381
|
+
}
|
|
1382
|
+
/**
|
|
1383
|
+
* Get base option by name.
|
|
1384
|
+
*
|
|
1385
|
+
* @param name Name of the option. Must be in param-case.
|
|
1386
|
+
* @param hidden Include hidden options.
|
|
1387
|
+
*/
|
|
1388
|
+
getBaseOption(name, hidden) {
|
|
1389
|
+
const option = this.options.find((option) => option.name === name || option.aliases?.includes(name));
|
|
1390
|
+
return option && (hidden || !option.hidden) ? option : undefined;
|
|
1391
|
+
}
|
|
1392
|
+
/**
|
|
1393
|
+
* Get global option from parent commands by name.
|
|
1394
|
+
*
|
|
1395
|
+
* @param name Name of the option. Must be in param-case.
|
|
1396
|
+
* @param hidden Include hidden options.
|
|
1397
|
+
*/
|
|
1398
|
+
getGlobalOption(name, hidden) {
|
|
1399
|
+
const helpOption = this.getHelpOption();
|
|
1400
|
+
const getGlobalOption = (parent, noGlobals) => {
|
|
1401
|
+
const option = parent.getBaseOption(name, hidden);
|
|
1402
|
+
if (!option?.global) {
|
|
1403
|
+
return parent._parent && getGlobalOption(parent._parent, noGlobals || parent._noGlobals);
|
|
1404
|
+
}
|
|
1405
|
+
if (noGlobals && option !== helpOption) {
|
|
1406
|
+
return;
|
|
1407
|
+
}
|
|
1408
|
+
return option;
|
|
1409
|
+
};
|
|
1410
|
+
return this._parent && getGlobalOption(this._parent, this._noGlobals);
|
|
1411
|
+
}
|
|
1412
|
+
/**
|
|
1413
|
+
* Remove option by name.
|
|
1414
|
+
*
|
|
1415
|
+
* @param name Name of the option. Must be in param-case.
|
|
1416
|
+
*/
|
|
1417
|
+
removeOption(name) {
|
|
1418
|
+
const index = this.options.findIndex((option) => option.name === name);
|
|
1419
|
+
if (index === -1) {
|
|
1420
|
+
return;
|
|
1421
|
+
}
|
|
1422
|
+
return this.options.splice(index, 1)[0];
|
|
1423
|
+
}
|
|
1424
|
+
/**
|
|
1425
|
+
* Checks whether the command has sub-commands or not.
|
|
1426
|
+
*
|
|
1427
|
+
* @param hidden Include hidden commands.
|
|
1428
|
+
*/
|
|
1429
|
+
hasCommands(hidden) {
|
|
1430
|
+
return this.getCommands(hidden).length > 0;
|
|
1431
|
+
}
|
|
1432
|
+
/**
|
|
1433
|
+
* Get commands.
|
|
1434
|
+
*
|
|
1435
|
+
* @param hidden Include hidden commands.
|
|
1436
|
+
*/
|
|
1437
|
+
getCommands(hidden) {
|
|
1438
|
+
return this.getGlobalCommands(hidden).concat(this.getBaseCommands(hidden));
|
|
1439
|
+
}
|
|
1440
|
+
/**
|
|
1441
|
+
* Get base commands.
|
|
1442
|
+
*
|
|
1443
|
+
* @param hidden Include hidden commands.
|
|
1444
|
+
*/
|
|
1445
|
+
getBaseCommands(hidden) {
|
|
1446
|
+
const commands = Array.from(this.commands.values());
|
|
1447
|
+
return hidden ? commands : commands.filter((cmd) => !cmd.isHidden);
|
|
1448
|
+
}
|
|
1449
|
+
/**
|
|
1450
|
+
* Get global commands.
|
|
1451
|
+
*
|
|
1452
|
+
* @param hidden Include hidden commands.
|
|
1453
|
+
*/
|
|
1454
|
+
getGlobalCommands(hidden) {
|
|
1455
|
+
const getCommands = (command, noGlobals, commands = [], names = []) => {
|
|
1456
|
+
if (command.commands.size) {
|
|
1457
|
+
for (const [_, cmd] of command.commands) {
|
|
1458
|
+
if (cmd.isGlobal &&
|
|
1459
|
+
this !== cmd &&
|
|
1460
|
+
!this.commands.has(cmd._name) &&
|
|
1461
|
+
names.indexOf(cmd._name) === -1 &&
|
|
1462
|
+
(hidden || !cmd.isHidden)) {
|
|
1463
|
+
if (noGlobals && cmd?.getName() !== "help") {
|
|
1464
|
+
continue;
|
|
1465
|
+
}
|
|
1466
|
+
names.push(cmd._name);
|
|
1467
|
+
commands.push(cmd);
|
|
1468
|
+
}
|
|
1469
|
+
}
|
|
1470
|
+
}
|
|
1471
|
+
return command._parent
|
|
1472
|
+
? getCommands(command._parent, noGlobals || command._noGlobals, commands, names)
|
|
1473
|
+
: commands;
|
|
1474
|
+
};
|
|
1475
|
+
return this._parent ? getCommands(this._parent, this._noGlobals) : [];
|
|
1476
|
+
}
|
|
1477
|
+
/**
|
|
1478
|
+
* Checks whether a child command exists by given name or alias.
|
|
1479
|
+
*
|
|
1480
|
+
* @param name Name or alias of the command.
|
|
1481
|
+
* @param hidden Include hidden commands.
|
|
1482
|
+
*/
|
|
1483
|
+
hasCommand(name, hidden) {
|
|
1484
|
+
return !!this.getCommand(name, hidden);
|
|
1485
|
+
}
|
|
1486
|
+
/**
|
|
1487
|
+
* Get command by name or alias.
|
|
1488
|
+
*
|
|
1489
|
+
* @param name Name or alias of the command.
|
|
1490
|
+
* @param hidden Include hidden commands.
|
|
1491
|
+
*/
|
|
1492
|
+
getCommand(name, hidden) {
|
|
1493
|
+
return this.getBaseCommand(name, hidden) ??
|
|
1494
|
+
this.getGlobalCommand(name, hidden);
|
|
1495
|
+
}
|
|
1496
|
+
/**
|
|
1497
|
+
* Get base command by name or alias.
|
|
1498
|
+
*
|
|
1499
|
+
* @param name Name or alias of the command.
|
|
1500
|
+
* @param hidden Include hidden commands.
|
|
1501
|
+
*/
|
|
1502
|
+
getBaseCommand(name, hidden) {
|
|
1503
|
+
for (const cmd of this.commands.values()) {
|
|
1504
|
+
if (cmd._name === name || cmd.aliases.includes(name)) {
|
|
1505
|
+
return (cmd && (hidden || !cmd.isHidden) ? cmd : undefined);
|
|
1506
|
+
}
|
|
1507
|
+
}
|
|
1508
|
+
}
|
|
1509
|
+
/**
|
|
1510
|
+
* Get global command by name or alias.
|
|
1511
|
+
*
|
|
1512
|
+
* @param name Name or alias of the command.
|
|
1513
|
+
* @param hidden Include hidden commands.
|
|
1514
|
+
*/
|
|
1515
|
+
getGlobalCommand(name, hidden) {
|
|
1516
|
+
const getGlobalCommand = (parent, noGlobals) => {
|
|
1517
|
+
const cmd = parent.getBaseCommand(name, hidden);
|
|
1518
|
+
if (!cmd?.isGlobal) {
|
|
1519
|
+
return parent._parent &&
|
|
1520
|
+
getGlobalCommand(parent._parent, noGlobals || parent._noGlobals);
|
|
1521
|
+
}
|
|
1522
|
+
if (noGlobals && cmd.getName() !== "help") {
|
|
1523
|
+
return;
|
|
1524
|
+
}
|
|
1525
|
+
return cmd;
|
|
1526
|
+
};
|
|
1527
|
+
return this._parent &&
|
|
1528
|
+
getGlobalCommand(this._parent, this._noGlobals);
|
|
1529
|
+
}
|
|
1530
|
+
/**
|
|
1531
|
+
* Remove sub-command by name or alias.
|
|
1532
|
+
*
|
|
1533
|
+
* @param name Name or alias of the command.
|
|
1534
|
+
*/
|
|
1535
|
+
removeCommand(name) {
|
|
1536
|
+
const command = this.getBaseCommand(name, true);
|
|
1537
|
+
if (command) {
|
|
1538
|
+
this.commands.delete(command._name);
|
|
1539
|
+
}
|
|
1540
|
+
return command;
|
|
1541
|
+
}
|
|
1542
|
+
/** Get types. */
|
|
1543
|
+
getTypes() {
|
|
1544
|
+
return this.getGlobalTypes().concat(this.getBaseTypes());
|
|
1545
|
+
}
|
|
1546
|
+
/** Get base types. */
|
|
1547
|
+
getBaseTypes() {
|
|
1548
|
+
return Array.from(this.types.values());
|
|
1549
|
+
}
|
|
1550
|
+
/** Get global types. */
|
|
1551
|
+
getGlobalTypes() {
|
|
1552
|
+
const getTypes = (cmd, types = [], names = []) => {
|
|
1553
|
+
if (cmd) {
|
|
1554
|
+
if (cmd.types.size) {
|
|
1555
|
+
cmd.types.forEach((type) => {
|
|
1556
|
+
if (type.global &&
|
|
1557
|
+
!this.types.has(type.name) &&
|
|
1558
|
+
names.indexOf(type.name) === -1) {
|
|
1559
|
+
names.push(type.name);
|
|
1560
|
+
types.push(type);
|
|
1561
|
+
}
|
|
1562
|
+
});
|
|
1563
|
+
}
|
|
1564
|
+
return getTypes(cmd._parent, types, names);
|
|
1565
|
+
}
|
|
1566
|
+
return types;
|
|
1567
|
+
};
|
|
1568
|
+
return getTypes(this._parent);
|
|
1569
|
+
}
|
|
1570
|
+
/**
|
|
1571
|
+
* Get type by name.
|
|
1572
|
+
*
|
|
1573
|
+
* @param name Name of the type.
|
|
1574
|
+
*/
|
|
1575
|
+
getType(name) {
|
|
1576
|
+
return this.getBaseType(name) ?? this.getGlobalType(name);
|
|
1577
|
+
}
|
|
1578
|
+
/**
|
|
1579
|
+
* Get base type by name.
|
|
1580
|
+
*
|
|
1581
|
+
* @param name Name of the type.
|
|
1582
|
+
*/
|
|
1583
|
+
getBaseType(name) {
|
|
1584
|
+
return this.types.get(name);
|
|
1585
|
+
}
|
|
1586
|
+
/**
|
|
1587
|
+
* Get global type by name.
|
|
1588
|
+
*
|
|
1589
|
+
* @param name Name of the type.
|
|
1590
|
+
*/
|
|
1591
|
+
getGlobalType(name) {
|
|
1592
|
+
if (!this._parent) {
|
|
1593
|
+
return;
|
|
1594
|
+
}
|
|
1595
|
+
const cmd = this._parent.getBaseType(name);
|
|
1596
|
+
if (!cmd?.global) {
|
|
1597
|
+
return this._parent.getGlobalType(name);
|
|
1598
|
+
}
|
|
1599
|
+
return cmd;
|
|
1600
|
+
}
|
|
1601
|
+
/** Get completions. */
|
|
1602
|
+
getCompletions() {
|
|
1603
|
+
return this.getGlobalCompletions().concat(this.getBaseCompletions());
|
|
1604
|
+
}
|
|
1605
|
+
/** Get base completions. */
|
|
1606
|
+
getBaseCompletions() {
|
|
1607
|
+
return Array.from(this.completions.values());
|
|
1608
|
+
}
|
|
1609
|
+
/** Get global completions. */
|
|
1610
|
+
getGlobalCompletions() {
|
|
1611
|
+
const getCompletions = (cmd, completions = [], names = []) => {
|
|
1612
|
+
if (cmd) {
|
|
1613
|
+
if (cmd.completions.size) {
|
|
1614
|
+
cmd.completions.forEach((completion) => {
|
|
1615
|
+
if (completion.global &&
|
|
1616
|
+
!this.completions.has(completion.name) &&
|
|
1617
|
+
names.indexOf(completion.name) === -1) {
|
|
1618
|
+
names.push(completion.name);
|
|
1619
|
+
completions.push(completion);
|
|
1620
|
+
}
|
|
1621
|
+
});
|
|
1622
|
+
}
|
|
1623
|
+
return getCompletions(cmd._parent, completions, names);
|
|
1624
|
+
}
|
|
1625
|
+
return completions;
|
|
1626
|
+
};
|
|
1627
|
+
return getCompletions(this._parent);
|
|
1628
|
+
}
|
|
1629
|
+
/**
|
|
1630
|
+
* Get completion by name.
|
|
1631
|
+
*
|
|
1632
|
+
* @param name Name of the completion.
|
|
1633
|
+
*/
|
|
1634
|
+
getCompletion(name) {
|
|
1635
|
+
return this.getBaseCompletion(name) ?? this.getGlobalCompletion(name);
|
|
1636
|
+
}
|
|
1637
|
+
/**
|
|
1638
|
+
* Get base completion by name.
|
|
1639
|
+
*
|
|
1640
|
+
* @param name Name of the completion.
|
|
1641
|
+
*/
|
|
1642
|
+
getBaseCompletion(name) {
|
|
1643
|
+
return this.completions.get(name);
|
|
1644
|
+
}
|
|
1645
|
+
/**
|
|
1646
|
+
* Get global completions by name.
|
|
1647
|
+
*
|
|
1648
|
+
* @param name Name of the completion.
|
|
1649
|
+
*/
|
|
1650
|
+
getGlobalCompletion(name) {
|
|
1651
|
+
if (!this._parent) {
|
|
1652
|
+
return;
|
|
1653
|
+
}
|
|
1654
|
+
const completion = this._parent.getBaseCompletion(name);
|
|
1655
|
+
if (!completion?.global) {
|
|
1656
|
+
return this._parent.getGlobalCompletion(name);
|
|
1657
|
+
}
|
|
1658
|
+
return completion;
|
|
1659
|
+
}
|
|
1660
|
+
/**
|
|
1661
|
+
* Checks whether the command has environment variables or not.
|
|
1662
|
+
*
|
|
1663
|
+
* @param hidden Include hidden environment variable.
|
|
1664
|
+
*/
|
|
1665
|
+
hasEnvVars(hidden) {
|
|
1666
|
+
return this.getEnvVars(hidden).length > 0;
|
|
1667
|
+
}
|
|
1668
|
+
/**
|
|
1669
|
+
* Get environment variables.
|
|
1670
|
+
*
|
|
1671
|
+
* @param hidden Include hidden environment variable.
|
|
1672
|
+
*/
|
|
1673
|
+
getEnvVars(hidden) {
|
|
1674
|
+
return this.getGlobalEnvVars(hidden).concat(this.getBaseEnvVars(hidden));
|
|
1675
|
+
}
|
|
1676
|
+
/**
|
|
1677
|
+
* Get base environment variables.
|
|
1678
|
+
*
|
|
1679
|
+
* @param hidden Include hidden environment variable.
|
|
1680
|
+
*/
|
|
1681
|
+
getBaseEnvVars(hidden) {
|
|
1682
|
+
if (!this.envVars.length) {
|
|
1683
|
+
return [];
|
|
1684
|
+
}
|
|
1685
|
+
return hidden
|
|
1686
|
+
? this.envVars.slice(0)
|
|
1687
|
+
: this.envVars.filter((env) => !env.hidden);
|
|
1688
|
+
}
|
|
1689
|
+
/**
|
|
1690
|
+
* Get global environment variables.
|
|
1691
|
+
*
|
|
1692
|
+
* @param hidden Include hidden environment variable.
|
|
1693
|
+
*/
|
|
1694
|
+
getGlobalEnvVars(hidden) {
|
|
1695
|
+
if (this._noGlobals) {
|
|
1696
|
+
return [];
|
|
1697
|
+
}
|
|
1698
|
+
const getEnvVars = (cmd, envVars = [], names = []) => {
|
|
1699
|
+
if (cmd) {
|
|
1700
|
+
if (cmd.envVars.length) {
|
|
1701
|
+
cmd.envVars.forEach((envVar) => {
|
|
1702
|
+
if (envVar.global &&
|
|
1703
|
+
!this.envVars.find((env) => env.names[0] === envVar.names[0]) &&
|
|
1704
|
+
names.indexOf(envVar.names[0]) === -1 &&
|
|
1705
|
+
(hidden || !envVar.hidden)) {
|
|
1706
|
+
names.push(envVar.names[0]);
|
|
1707
|
+
envVars.push(envVar);
|
|
1708
|
+
}
|
|
1709
|
+
});
|
|
1710
|
+
}
|
|
1711
|
+
return getEnvVars(cmd._parent, envVars, names);
|
|
1712
|
+
}
|
|
1713
|
+
return envVars;
|
|
1714
|
+
};
|
|
1715
|
+
return getEnvVars(this._parent);
|
|
1716
|
+
}
|
|
1717
|
+
/**
|
|
1718
|
+
* Checks whether the command has an environment variable with given name or not.
|
|
1719
|
+
*
|
|
1720
|
+
* @param name Name of the environment variable.
|
|
1721
|
+
* @param hidden Include hidden environment variable.
|
|
1722
|
+
*/
|
|
1723
|
+
hasEnvVar(name, hidden) {
|
|
1724
|
+
return !!this.getEnvVar(name, hidden);
|
|
1725
|
+
}
|
|
1726
|
+
/**
|
|
1727
|
+
* Get environment variable by name.
|
|
1728
|
+
*
|
|
1729
|
+
* @param name Name of the environment variable.
|
|
1730
|
+
* @param hidden Include hidden environment variable.
|
|
1731
|
+
*/
|
|
1732
|
+
getEnvVar(name, hidden) {
|
|
1733
|
+
return this.getBaseEnvVar(name, hidden) ??
|
|
1734
|
+
this.getGlobalEnvVar(name, hidden);
|
|
1735
|
+
}
|
|
1736
|
+
/**
|
|
1737
|
+
* Get base environment variable by name.
|
|
1738
|
+
*
|
|
1739
|
+
* @param name Name of the environment variable.
|
|
1740
|
+
* @param hidden Include hidden environment variable.
|
|
1741
|
+
*/
|
|
1742
|
+
getBaseEnvVar(name, hidden) {
|
|
1743
|
+
const envVar = this.envVars.find((env) => env.names.indexOf(name) !== -1);
|
|
1744
|
+
return envVar && (hidden || !envVar.hidden) ? envVar : undefined;
|
|
1745
|
+
}
|
|
1746
|
+
/**
|
|
1747
|
+
* Get global environment variable by name.
|
|
1748
|
+
*
|
|
1749
|
+
* @param name Name of the environment variable.
|
|
1750
|
+
* @param hidden Include hidden environment variable.
|
|
1751
|
+
*/
|
|
1752
|
+
getGlobalEnvVar(name, hidden) {
|
|
1753
|
+
if (!this._parent || this._noGlobals) {
|
|
1754
|
+
return;
|
|
1755
|
+
}
|
|
1756
|
+
const envVar = this._parent.getBaseEnvVar(name, hidden);
|
|
1757
|
+
if (!envVar?.global) {
|
|
1758
|
+
return this._parent.getGlobalEnvVar(name, hidden);
|
|
1759
|
+
}
|
|
1760
|
+
return envVar;
|
|
1761
|
+
}
|
|
1762
|
+
/** Checks whether the command has examples or not. */
|
|
1763
|
+
hasExamples() {
|
|
1764
|
+
return this.examples.length > 0;
|
|
1765
|
+
}
|
|
1766
|
+
/** Get all examples. */
|
|
1767
|
+
getExamples() {
|
|
1768
|
+
return this.examples;
|
|
1769
|
+
}
|
|
1770
|
+
/** Checks whether the command has an example with given name or not. */
|
|
1771
|
+
hasExample(name) {
|
|
1772
|
+
return !!this.getExample(name);
|
|
1773
|
+
}
|
|
1774
|
+
/** Get example with given name. */
|
|
1775
|
+
getExample(name) {
|
|
1776
|
+
return this.examples.find((example) => example.name === name);
|
|
1777
|
+
}
|
|
1778
|
+
getHelpOption() {
|
|
1779
|
+
return this._helpOption ?? this._parent?.getHelpOption();
|
|
1780
|
+
}
|
|
1781
|
+
}
|
|
1782
|
+
function findFlag(flags) {
|
|
1783
|
+
for (const flag of flags) {
|
|
1784
|
+
if (flag.startsWith("--")) {
|
|
1785
|
+
return flag;
|
|
1786
|
+
}
|
|
1787
|
+
}
|
|
1788
|
+
return flags[0];
|
|
1789
|
+
}
|