@shell-shock/preset-script 0.6.28 → 0.6.29
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/README.md +1 -1
- package/dist/components/bin-entry.cjs +4 -4
- package/dist/components/bin-entry.mjs +3 -3
- package/dist/components/command-entry.cjs +5 -5
- package/dist/components/command-entry.d.mts +1 -1
- package/dist/components/command-entry.mjs +4 -4
- package/dist/components/command-router.cjs +1 -1
- package/dist/components/command-router.mjs +1 -1
- package/dist/components/exit-function-declaration.cjs +1 -1
- package/dist/components/exit-function-declaration.mjs +1 -1
- package/dist/components/virtual-command-entry.cjs +3 -3
- package/dist/components/virtual-command-entry.mjs +3 -3
- package/dist/index.cjs +7 -3
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts.map +1 -1
- package/dist/index.d.mts.map +1 -1
- package/dist/index.mjs +5 -3
- package/dist/index.mjs.map +1 -1
- package/dist/types/plugin.d.cts +6 -5
- package/dist/types/plugin.d.cts.map +1 -1
- package/dist/types/plugin.d.mts +7 -6
- package/dist/types/plugin.d.mts.map +1 -1
- package/package.json +12 -10
- package/dist/plugin-help/dist/components/display.cjs +0 -274
- package/dist/plugin-help/dist/components/display.cjs.map +0 -1
- package/dist/plugin-help/dist/components/display.mjs +0 -268
- package/dist/plugin-help/dist/components/display.mjs.map +0 -1
- package/dist/plugin-help/dist/components/help-builtin.cjs +0 -86
- package/dist/plugin-help/dist/components/help-builtin.cjs.map +0 -1
- package/dist/plugin-help/dist/components/help-builtin.mjs +0 -84
- package/dist/plugin-help/dist/components/help-builtin.mjs.map +0 -1
- package/dist/plugin-help/dist/components/help-command.cjs +0 -97
- package/dist/plugin-help/dist/components/help-command.cjs.map +0 -1
- package/dist/plugin-help/dist/components/help-command.mjs +0 -96
- package/dist/plugin-help/dist/components/help-command.mjs.map +0 -1
- package/dist/plugin-help/dist/components/index.cjs +0 -3
- package/dist/plugin-help/dist/components/index.mjs +0 -5
- package/dist/plugin-help/dist/index.cjs +0 -104
- package/dist/plugin-help/dist/index.cjs.map +0 -1
- package/dist/plugin-help/dist/index.d.cts +0 -2
- package/dist/plugin-help/dist/index.d.mts +0 -2
- package/dist/plugin-help/dist/index.mjs +0 -100
- package/dist/plugin-help/dist/index.mjs.map +0 -1
- package/dist/plugin-help/dist/node_modules/.pnpm/@stryke_string-format@0.17.6/node_modules/@stryke/string-format/dist/constant-case.cjs +0 -18
- package/dist/plugin-help/dist/node_modules/.pnpm/@stryke_string-format@0.17.6/node_modules/@stryke/string-format/dist/constant-case.cjs.map +0 -1
- package/dist/plugin-help/dist/node_modules/.pnpm/@stryke_string-format@0.17.6/node_modules/@stryke/string-format/dist/constant-case.mjs +0 -17
- package/dist/plugin-help/dist/node_modules/.pnpm/@stryke_string-format@0.17.6/node_modules/@stryke/string-format/dist/constant-case.mjs.map +0 -1
- package/dist/plugin-help/dist/node_modules/.pnpm/@stryke_string-format@0.17.6/node_modules/@stryke/string-format/dist/get-words.cjs +0 -39
- package/dist/plugin-help/dist/node_modules/.pnpm/@stryke_string-format@0.17.6/node_modules/@stryke/string-format/dist/get-words.cjs.map +0 -1
- package/dist/plugin-help/dist/node_modules/.pnpm/@stryke_string-format@0.17.6/node_modules/@stryke/string-format/dist/get-words.mjs +0 -38
- package/dist/plugin-help/dist/node_modules/.pnpm/@stryke_string-format@0.17.6/node_modules/@stryke/string-format/dist/get-words.mjs.map +0 -1
- package/dist/plugin-help/dist/node_modules/.pnpm/@stryke_string-format@0.17.6/node_modules/@stryke/string-format/dist/kebab-case.cjs +0 -34
- package/dist/plugin-help/dist/node_modules/.pnpm/@stryke_string-format@0.17.6/node_modules/@stryke/string-format/dist/kebab-case.cjs.map +0 -1
- package/dist/plugin-help/dist/node_modules/.pnpm/@stryke_string-format@0.17.6/node_modules/@stryke/string-format/dist/kebab-case.mjs +0 -34
- package/dist/plugin-help/dist/node_modules/.pnpm/@stryke_string-format@0.17.6/node_modules/@stryke/string-format/dist/kebab-case.mjs.map +0 -1
- package/dist/plugin-help/dist/node_modules/.pnpm/@stryke_string-format@0.17.6/node_modules/@stryke/string-format/dist/snake-case.cjs +0 -41
- package/dist/plugin-help/dist/node_modules/.pnpm/@stryke_string-format@0.17.6/node_modules/@stryke/string-format/dist/snake-case.cjs.map +0 -1
- package/dist/plugin-help/dist/node_modules/.pnpm/@stryke_string-format@0.17.6/node_modules/@stryke/string-format/dist/snake-case.mjs +0 -41
- package/dist/plugin-help/dist/node_modules/.pnpm/@stryke_string-format@0.17.6/node_modules/@stryke/string-format/dist/snake-case.mjs.map +0 -1
- package/dist/plugin-help/dist/node_modules/.pnpm/@stryke_string-format@0.17.6/node_modules/@stryke/string-format/dist/upper-case-first.cjs +0 -18
- package/dist/plugin-help/dist/node_modules/.pnpm/@stryke_string-format@0.17.6/node_modules/@stryke/string-format/dist/upper-case-first.cjs.map +0 -1
- package/dist/plugin-help/dist/node_modules/.pnpm/@stryke_string-format@0.17.6/node_modules/@stryke/string-format/dist/upper-case-first.mjs +0 -17
- package/dist/plugin-help/dist/node_modules/.pnpm/@stryke_string-format@0.17.6/node_modules/@stryke/string-format/dist/upper-case-first.mjs.map +0 -1
- package/dist/plugin-help/dist/node_modules/.pnpm/@stryke_type-checks@0.5.41/node_modules/@stryke/type-checks/dist/is-empty.cjs +0 -21
- package/dist/plugin-help/dist/node_modules/.pnpm/@stryke_type-checks@0.5.41/node_modules/@stryke/type-checks/dist/is-empty.cjs.map +0 -1
- package/dist/plugin-help/dist/node_modules/.pnpm/@stryke_type-checks@0.5.41/node_modules/@stryke/type-checks/dist/is-empty.mjs +0 -21
- package/dist/plugin-help/dist/node_modules/.pnpm/@stryke_type-checks@0.5.41/node_modules/@stryke/type-checks/dist/is-empty.mjs.map +0 -1
- package/dist/plugin-help/dist/node_modules/.pnpm/@stryke_type-checks@0.5.41/node_modules/@stryke/type-checks/dist/is-null.cjs +0 -13
- package/dist/plugin-help/dist/node_modules/.pnpm/@stryke_type-checks@0.5.41/node_modules/@stryke/type-checks/dist/is-null.cjs.map +0 -1
- package/dist/plugin-help/dist/node_modules/.pnpm/@stryke_type-checks@0.5.41/node_modules/@stryke/type-checks/dist/is-null.mjs +0 -12
- package/dist/plugin-help/dist/node_modules/.pnpm/@stryke_type-checks@0.5.41/node_modules/@stryke/type-checks/dist/is-null.mjs.map +0 -1
- package/dist/plugin-help/dist/node_modules/.pnpm/@stryke_type-checks@0.5.41/node_modules/@stryke/type-checks/dist/is-set-string.cjs +0 -21
- package/dist/plugin-help/dist/node_modules/.pnpm/@stryke_type-checks@0.5.41/node_modules/@stryke/type-checks/dist/is-set-string.cjs.map +0 -1
- package/dist/plugin-help/dist/node_modules/.pnpm/@stryke_type-checks@0.5.41/node_modules/@stryke/type-checks/dist/is-set-string.mjs +0 -21
- package/dist/plugin-help/dist/node_modules/.pnpm/@stryke_type-checks@0.5.41/node_modules/@stryke/type-checks/dist/is-set-string.mjs.map +0 -1
- package/dist/plugin-help/dist/node_modules/.pnpm/@stryke_type-checks@0.5.41/node_modules/@stryke/type-checks/dist/is-set.cjs +0 -20
- package/dist/plugin-help/dist/node_modules/.pnpm/@stryke_type-checks@0.5.41/node_modules/@stryke/type-checks/dist/is-set.cjs.map +0 -1
- package/dist/plugin-help/dist/node_modules/.pnpm/@stryke_type-checks@0.5.41/node_modules/@stryke/type-checks/dist/is-set.mjs +0 -20
- package/dist/plugin-help/dist/node_modules/.pnpm/@stryke_type-checks@0.5.41/node_modules/@stryke/type-checks/dist/is-set.mjs.map +0 -1
- package/dist/plugin-help/dist/node_modules/.pnpm/@stryke_type-checks@0.5.41/node_modules/@stryke/type-checks/dist/is-string.cjs +0 -13
- package/dist/plugin-help/dist/node_modules/.pnpm/@stryke_type-checks@0.5.41/node_modules/@stryke/type-checks/dist/is-string.cjs.map +0 -1
- package/dist/plugin-help/dist/node_modules/.pnpm/@stryke_type-checks@0.5.41/node_modules/@stryke/type-checks/dist/is-string.mjs +0 -12
- package/dist/plugin-help/dist/node_modules/.pnpm/@stryke_type-checks@0.5.41/node_modules/@stryke/type-checks/dist/is-string.mjs.map +0 -1
- package/dist/plugin-help/dist/node_modules/.pnpm/@stryke_type-checks@0.5.41/node_modules/@stryke/type-checks/dist/is-undefined.cjs +0 -9
- package/dist/plugin-help/dist/node_modules/.pnpm/@stryke_type-checks@0.5.41/node_modules/@stryke/type-checks/dist/is-undefined.cjs.map +0 -1
- package/dist/plugin-help/dist/node_modules/.pnpm/@stryke_type-checks@0.5.41/node_modules/@stryke/type-checks/dist/is-undefined.mjs +0 -8
- package/dist/plugin-help/dist/node_modules/.pnpm/@stryke_type-checks@0.5.41/node_modules/@stryke/type-checks/dist/is-undefined.mjs.map +0 -1
- package/dist/plugin-help/dist/types/plugin.d.cts +0 -62
- package/dist/plugin-help/dist/types/plugin.d.cts.map +0 -1
- package/dist/plugin-help/dist/types/plugin.d.mts +0 -62
- package/dist/plugin-help/dist/types/plugin.d.mts.map +0 -1
package/README.md
CHANGED
|
@@ -27,7 +27,7 @@ This package is part of the ⚡<b>Shell Shock</b> monorepo. The Shell Shock pack
|
|
|
27
27
|
|
|
28
28
|
<h3 align="center">💻 Visit <a href="https://stormsoftware.com" target="_blank">stormsoftware.com</a> to stay up to date with this developer</h3><br />
|
|
29
29
|
|
|
30
|
-
[](https://stormsoftware.com/projects/shell-shock/) [](http://commitizen.github.io/cz-cli/)  
|
|
31
31
|
|
|
32
32
|
<!-- prettier-ignore-start -->
|
|
33
33
|
<!-- markdownlint-disable -->
|
|
@@ -4,17 +4,17 @@ const require_components_exit_function_declaration = require('./exit-function-de
|
|
|
4
4
|
let _alloy_js_core_jsx_runtime = require("@alloy-js/core/jsx-runtime");
|
|
5
5
|
let _alloy_js_core = require("@alloy-js/core");
|
|
6
6
|
let _alloy_js_typescript = require("@alloy-js/typescript");
|
|
7
|
-
let _shell_shock_core_plugin_utils = require("@shell-shock/core/plugin-utils");
|
|
8
7
|
let _powerlines_plugin_alloy_core_components_spacing = require("@powerlines/plugin-alloy/core/components/spacing");
|
|
9
8
|
let _powerlines_plugin_alloy_core_contexts_context = require("@powerlines/plugin-alloy/core/contexts/context");
|
|
10
|
-
let defu = require("defu");
|
|
11
|
-
defu = require_runtime.__toESM(defu);
|
|
12
|
-
let _powerlines_plugin_alloy_typescript_components_tsdoc = require("@powerlines/plugin-alloy/typescript/components/tsdoc");
|
|
13
9
|
let _powerlines_plugin_alloy_typescript_components_entry_file = require("@powerlines/plugin-alloy/typescript/components/entry-file");
|
|
10
|
+
let _powerlines_plugin_alloy_typescript_components_tsdoc = require("@powerlines/plugin-alloy/typescript/components/tsdoc");
|
|
11
|
+
let _shell_shock_core_plugin_utils = require("@shell-shock/core/plugin-utils");
|
|
14
12
|
let _stryke_helpers_get_unique = require("@stryke/helpers/get-unique");
|
|
15
13
|
let _stryke_path_file_path_fns = require("@stryke/path/file-path-fns");
|
|
16
14
|
let _stryke_path_replace = require("@stryke/path/replace");
|
|
17
15
|
let _stryke_string_format_pascal_case = require("@stryke/string-format/pascal-case");
|
|
16
|
+
let defu = require("defu");
|
|
17
|
+
defu = require_runtime.__toESM(defu);
|
|
18
18
|
|
|
19
19
|
//#region src/components/bin-entry.tsx
|
|
20
20
|
/**
|
|
@@ -2,16 +2,16 @@ import { ExitFunctionDeclaration } from "./exit-function-declaration.mjs";
|
|
|
2
2
|
import { createComponent, createIntrinsic, memo, mergeProps } from "@alloy-js/core/jsx-runtime";
|
|
3
3
|
import { For, Show, code, computed } from "@alloy-js/core";
|
|
4
4
|
import { FunctionDeclaration, IfStatement } from "@alloy-js/typescript";
|
|
5
|
-
import { getAppTitle } from "@shell-shock/core/plugin-utils";
|
|
6
5
|
import { Spacing } from "@powerlines/plugin-alloy/core/components/spacing";
|
|
7
6
|
import { usePowerlines } from "@powerlines/plugin-alloy/core/contexts/context";
|
|
8
|
-
import defu from "defu";
|
|
9
|
-
import { TSDoc, TSDocRemarks, TSDocReturns } from "@powerlines/plugin-alloy/typescript/components/tsdoc";
|
|
10
7
|
import { EntryFile } from "@powerlines/plugin-alloy/typescript/components/entry-file";
|
|
8
|
+
import { TSDoc, TSDocRemarks, TSDocReturns } from "@powerlines/plugin-alloy/typescript/components/tsdoc";
|
|
9
|
+
import { getAppTitle } from "@shell-shock/core/plugin-utils";
|
|
11
10
|
import { getUnique } from "@stryke/helpers/get-unique";
|
|
12
11
|
import { findFileName } from "@stryke/path/file-path-fns";
|
|
13
12
|
import { replaceExtension } from "@stryke/path/replace";
|
|
14
13
|
import { pascalCase } from "@stryke/string-format/pascal-case";
|
|
14
|
+
import defu from "defu";
|
|
15
15
|
|
|
16
16
|
//#region src/components/bin-entry.tsx
|
|
17
17
|
/**
|
|
@@ -4,20 +4,20 @@ const require_components_virtual_command_entry = require('./virtual-command-entr
|
|
|
4
4
|
let _alloy_js_core_jsx_runtime = require("@alloy-js/core/jsx-runtime");
|
|
5
5
|
let _alloy_js_core = require("@alloy-js/core");
|
|
6
6
|
let _alloy_js_typescript = require("@alloy-js/typescript");
|
|
7
|
-
let _shell_shock_core_plugin_utils = require("@shell-shock/core/plugin-utils");
|
|
8
7
|
let _powerlines_plugin_alloy_core_components_spacing = require("@powerlines/plugin-alloy/core/components/spacing");
|
|
9
8
|
let _powerlines_plugin_alloy_core_contexts_context = require("@powerlines/plugin-alloy/core/contexts/context");
|
|
10
|
-
let defu = require("defu");
|
|
11
|
-
defu = require_runtime.__toESM(defu);
|
|
12
|
-
let _powerlines_plugin_alloy_typescript_components_tsdoc = require("@powerlines/plugin-alloy/typescript/components/tsdoc");
|
|
13
|
-
let _stryke_path_join = require("@stryke/path/join");
|
|
14
9
|
let _powerlines_plugin_alloy_typescript_components_entry_file = require("@powerlines/plugin-alloy/typescript/components/entry-file");
|
|
10
|
+
let _powerlines_plugin_alloy_typescript_components_tsdoc = require("@powerlines/plugin-alloy/typescript/components/tsdoc");
|
|
11
|
+
let _shell_shock_core_plugin_utils = require("@shell-shock/core/plugin-utils");
|
|
15
12
|
let _stryke_path_replace = require("@stryke/path/replace");
|
|
16
13
|
let _stryke_string_format_pascal_case = require("@stryke/string-format/pascal-case");
|
|
14
|
+
let defu = require("defu");
|
|
15
|
+
defu = require_runtime.__toESM(defu);
|
|
17
16
|
let _shell_shock_core_components_helpers = require("@shell-shock/core/components/helpers");
|
|
18
17
|
let _shell_shock_core_components_command_validation_logic = require("@shell-shock/core/components/command-validation-logic");
|
|
19
18
|
let _shell_shock_core_components_options_parser_logic = require("@shell-shock/core/components/options-parser-logic");
|
|
20
19
|
let _stryke_path_find = require("@stryke/path/find");
|
|
20
|
+
let _stryke_path_join = require("@stryke/path/join");
|
|
21
21
|
let _stryke_string_format_camel_case = require("@stryke/string-format/camel-case");
|
|
22
22
|
let _stryke_string_format_constant_case = require("@stryke/string-format/constant-case");
|
|
23
23
|
let _stryke_string_format_kebab_case = require("@stryke/string-format/kebab-case");
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { Children } from "@alloy-js/core";
|
|
2
|
-
import { CommandTree } from "@shell-shock/core";
|
|
3
2
|
import { EntryFileProps } from "@powerlines/plugin-alloy/typescript/components/entry-file";
|
|
3
|
+
import { CommandTree } from "@shell-shock/core";
|
|
4
4
|
|
|
5
5
|
//#region src/components/command-entry.d.ts
|
|
6
6
|
declare function CommandInvocation(props: {
|
|
@@ -2,19 +2,19 @@ import { VirtualCommandEntry } from "./virtual-command-entry.mjs";
|
|
|
2
2
|
import { createComponent, createIntrinsic, memo, mergeProps } from "@alloy-js/core/jsx-runtime";
|
|
3
3
|
import { For, Show, code, computed } from "@alloy-js/core";
|
|
4
4
|
import { ElseClause, FunctionDeclaration, IfStatement, VarDeclaration } from "@alloy-js/typescript";
|
|
5
|
-
import { getAppBin, getDynamicPathSegmentName, isDynamicPathSegment } from "@shell-shock/core/plugin-utils";
|
|
6
5
|
import { Spacing } from "@powerlines/plugin-alloy/core/components/spacing";
|
|
7
6
|
import { usePowerlines } from "@powerlines/plugin-alloy/core/contexts/context";
|
|
8
|
-
import defu from "defu";
|
|
9
|
-
import { TSDoc, TSDocParam, TSDocRemarks, TSDocTitle } from "@powerlines/plugin-alloy/typescript/components/tsdoc";
|
|
10
|
-
import { joinPaths } from "@stryke/path/join";
|
|
11
7
|
import { EntryFile } from "@powerlines/plugin-alloy/typescript/components/entry-file";
|
|
8
|
+
import { TSDoc, TSDocParam, TSDocRemarks, TSDocTitle } from "@powerlines/plugin-alloy/typescript/components/tsdoc";
|
|
9
|
+
import { getAppBin, getDynamicPathSegmentName, isDynamicPathSegment } from "@shell-shock/core/plugin-utils";
|
|
12
10
|
import { replaceExtension } from "@stryke/path/replace";
|
|
13
11
|
import { pascalCase } from "@stryke/string-format/pascal-case";
|
|
12
|
+
import defu from "defu";
|
|
14
13
|
import { IsDebug } from "@shell-shock/core/components/helpers";
|
|
15
14
|
import { CommandValidationLogic } from "@shell-shock/core/components/command-validation-logic";
|
|
16
15
|
import { CommandParserLogic, OptionsInterfaceDeclaration } from "@shell-shock/core/components/options-parser-logic";
|
|
17
16
|
import { findFilePath, relativePath } from "@stryke/path/find";
|
|
17
|
+
import { joinPaths } from "@stryke/path/join";
|
|
18
18
|
import { camelCase } from "@stryke/string-format/camel-case";
|
|
19
19
|
import { constantCase } from "@stryke/string-format/constant-case";
|
|
20
20
|
import { kebabCase } from "@stryke/string-format/kebab-case";
|
|
@@ -3,9 +3,9 @@ const require_runtime = require('../_virtual/_rolldown/runtime.cjs');
|
|
|
3
3
|
let _alloy_js_core_jsx_runtime = require("@alloy-js/core/jsx-runtime");
|
|
4
4
|
let _alloy_js_core = require("@alloy-js/core");
|
|
5
5
|
let _alloy_js_typescript = require("@alloy-js/typescript");
|
|
6
|
-
let _shell_shock_core_plugin_utils = require("@shell-shock/core/plugin-utils");
|
|
7
6
|
let _powerlines_plugin_alloy_core_components_spacing = require("@powerlines/plugin-alloy/core/components/spacing");
|
|
8
7
|
let _powerlines_plugin_alloy_core_contexts_context = require("@powerlines/plugin-alloy/core/contexts/context");
|
|
8
|
+
let _shell_shock_core_plugin_utils = require("@shell-shock/core/plugin-utils");
|
|
9
9
|
let _stryke_string_format_pascal_case = require("@stryke/string-format/pascal-case");
|
|
10
10
|
let _powerlines_plugin_alloy_typescript_components_dynamic_import_statement = require("@powerlines/plugin-alloy/typescript/components/dynamic-import-statement");
|
|
11
11
|
let _shell_shock_core_contexts_command = require("@shell-shock/core/contexts/command");
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { createComponent, createIntrinsic, memo } from "@alloy-js/core/jsx-runtime";
|
|
2
2
|
import { For, Show, code, computed } from "@alloy-js/core";
|
|
3
3
|
import { ElseIfClause, IfStatement, VarDeclaration } from "@alloy-js/typescript";
|
|
4
|
-
import { isDynamicPathSegment } from "@shell-shock/core/plugin-utils";
|
|
5
4
|
import { Spacing } from "@powerlines/plugin-alloy/core/components/spacing";
|
|
6
5
|
import { usePowerlines } from "@powerlines/plugin-alloy/core/contexts/context";
|
|
6
|
+
import { isDynamicPathSegment } from "@shell-shock/core/plugin-utils";
|
|
7
7
|
import { pascalCase } from "@stryke/string-format/pascal-case";
|
|
8
8
|
import { DynamicImportStatement } from "@powerlines/plugin-alloy/typescript/components/dynamic-import-statement";
|
|
9
9
|
import { CommandContext, useCommand } from "@shell-shock/core/contexts/command";
|
|
@@ -3,9 +3,9 @@ const require_runtime = require('../_virtual/_rolldown/runtime.cjs');
|
|
|
3
3
|
let _alloy_js_core_jsx_runtime = require("@alloy-js/core/jsx-runtime");
|
|
4
4
|
let _alloy_js_core = require("@alloy-js/core");
|
|
5
5
|
let _alloy_js_typescript = require("@alloy-js/typescript");
|
|
6
|
-
let _shell_shock_core_plugin_utils = require("@shell-shock/core/plugin-utils");
|
|
7
6
|
let _powerlines_plugin_alloy_core_components_spacing = require("@powerlines/plugin-alloy/core/components/spacing");
|
|
8
7
|
let _powerlines_plugin_alloy_core_contexts_context = require("@powerlines/plugin-alloy/core/contexts/context");
|
|
8
|
+
let _shell_shock_core_plugin_utils = require("@shell-shock/core/plugin-utils");
|
|
9
9
|
let _shell_shock_core_components_helpers = require("@shell-shock/core/components/helpers");
|
|
10
10
|
|
|
11
11
|
//#region src/components/exit-function-declaration.tsx
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { createComponent, createIntrinsic, memo } from "@alloy-js/core/jsx-runtime";
|
|
2
2
|
import { code } from "@alloy-js/core";
|
|
3
3
|
import { FunctionDeclaration, IfStatement, InterfaceDeclaration, InterfaceMember, VarDeclaration } from "@alloy-js/typescript";
|
|
4
|
-
import { getAppTitle } from "@shell-shock/core/plugin-utils";
|
|
5
4
|
import { Spacing } from "@powerlines/plugin-alloy/core/components/spacing";
|
|
6
5
|
import { usePowerlines } from "@powerlines/plugin-alloy/core/contexts/context";
|
|
6
|
+
import { getAppTitle } from "@shell-shock/core/plugin-utils";
|
|
7
7
|
import { IsVerbose } from "@shell-shock/core/components/helpers";
|
|
8
8
|
|
|
9
9
|
//#region src/components/exit-function-declaration.tsx
|
|
@@ -6,13 +6,13 @@ let _alloy_js_core_jsx_runtime = require("@alloy-js/core/jsx-runtime");
|
|
|
6
6
|
let _alloy_js_core = require("@alloy-js/core");
|
|
7
7
|
let _alloy_js_typescript = require("@alloy-js/typescript");
|
|
8
8
|
let _powerlines_plugin_alloy_core_components = require("@powerlines/plugin-alloy/core/components");
|
|
9
|
-
let _shell_shock_core_plugin_utils = require("@shell-shock/core/plugin-utils");
|
|
10
9
|
let _powerlines_plugin_alloy_core_contexts_context = require("@powerlines/plugin-alloy/core/contexts/context");
|
|
10
|
+
let _powerlines_plugin_alloy_typescript_components_tsdoc = require("@powerlines/plugin-alloy/typescript/components/tsdoc");
|
|
11
|
+
let _shell_shock_core_plugin_utils = require("@shell-shock/core/plugin-utils");
|
|
12
|
+
let _stryke_string_format_pascal_case = require("@stryke/string-format/pascal-case");
|
|
11
13
|
let defu = require("defu");
|
|
12
14
|
defu = require_runtime.__toESM(defu);
|
|
13
|
-
let _powerlines_plugin_alloy_typescript_components_tsdoc = require("@powerlines/plugin-alloy/typescript/components/tsdoc");
|
|
14
15
|
let _stryke_path_join = require("@stryke/path/join");
|
|
15
|
-
let _stryke_string_format_pascal_case = require("@stryke/string-format/pascal-case");
|
|
16
16
|
let _stryke_string_format_constant_case = require("@stryke/string-format/constant-case");
|
|
17
17
|
let _powerlines_plugin_alloy_typescript_components_typescript_file = require("@powerlines/plugin-alloy/typescript/components/typescript-file");
|
|
18
18
|
|
|
@@ -4,12 +4,12 @@ import { createComponent, createIntrinsic, mergeProps } from "@alloy-js/core/jsx
|
|
|
4
4
|
import { For, Show, code, computed } from "@alloy-js/core";
|
|
5
5
|
import { FunctionDeclaration } from "@alloy-js/typescript";
|
|
6
6
|
import { Spacing } from "@powerlines/plugin-alloy/core/components";
|
|
7
|
-
import { getAppBin, getDynamicPathSegmentName, isDynamicPathSegment } from "@shell-shock/core/plugin-utils";
|
|
8
7
|
import { usePowerlines } from "@powerlines/plugin-alloy/core/contexts/context";
|
|
9
|
-
import defu from "defu";
|
|
10
8
|
import { TSDoc, TSDocParam, TSDocRemarks, TSDocTitle } from "@powerlines/plugin-alloy/typescript/components/tsdoc";
|
|
11
|
-
import {
|
|
9
|
+
import { getAppBin, getDynamicPathSegmentName, isDynamicPathSegment } from "@shell-shock/core/plugin-utils";
|
|
12
10
|
import { pascalCase } from "@stryke/string-format/pascal-case";
|
|
11
|
+
import defu from "defu";
|
|
12
|
+
import { joinPaths } from "@stryke/path/join";
|
|
13
13
|
import { constantCase } from "@stryke/string-format/constant-case";
|
|
14
14
|
import { TypescriptFile } from "@powerlines/plugin-alloy/typescript/components/typescript-file";
|
|
15
15
|
|
package/dist/index.cjs
CHANGED
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: 'Module' } });
|
|
2
2
|
const require_runtime = require('./_virtual/_rolldown/runtime.cjs');
|
|
3
|
-
const require_index = require('./plugin-help/dist/index.cjs');
|
|
4
3
|
const require_components_bin_entry = require('./components/bin-entry.cjs');
|
|
5
4
|
const require_components_command_router = require('./components/command-router.cjs');
|
|
6
5
|
const require_components_virtual_command_entry = require('./components/virtual-command-entry.cjs');
|
|
@@ -11,8 +10,12 @@ let _alloy_js_core = require("@alloy-js/core");
|
|
|
11
10
|
let _alloy_js_typescript = require("@alloy-js/typescript");
|
|
12
11
|
let _powerlines_plugin_alloy_core_components = require("@powerlines/plugin-alloy/core/components");
|
|
13
12
|
let _powerlines_plugin_alloy_render = require("@powerlines/plugin-alloy/render");
|
|
13
|
+
let _shell_shock_plugin_banner = require("@shell-shock/plugin-banner");
|
|
14
|
+
_shell_shock_plugin_banner = require_runtime.__toESM(_shell_shock_plugin_banner);
|
|
14
15
|
let _shell_shock_plugin_console = require("@shell-shock/plugin-console");
|
|
15
16
|
_shell_shock_plugin_console = require_runtime.__toESM(_shell_shock_plugin_console);
|
|
17
|
+
let _shell_shock_plugin_help = require("@shell-shock/plugin-help");
|
|
18
|
+
_shell_shock_plugin_help = require_runtime.__toESM(_shell_shock_plugin_help);
|
|
16
19
|
|
|
17
20
|
//#region src/index.tsx
|
|
18
21
|
/**
|
|
@@ -20,8 +23,9 @@ _shell_shock_plugin_console = require_runtime.__toESM(_shell_shock_plugin_consol
|
|
|
20
23
|
*/
|
|
21
24
|
const plugin = (options = {}) => {
|
|
22
25
|
return [
|
|
23
|
-
(0, _shell_shock_plugin_console.default)(options),
|
|
24
|
-
...
|
|
26
|
+
...(0, _shell_shock_plugin_console.default)(options),
|
|
27
|
+
...(0, _shell_shock_plugin_help.default)(options),
|
|
28
|
+
...(0, _shell_shock_plugin_banner.default)(options),
|
|
25
29
|
{
|
|
26
30
|
name: "shell-shock:script-preset",
|
|
27
31
|
config() {
|
package/dist/index.cjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.cjs","names":[],"sources":["../src/index.tsx"],"sourcesContent":["/* -------------------------------------------------------------------\n\n ⚡ Storm Software - Shell Shock\n\n This code was released as part of the Shell Shock project. Shell Shock\n is maintained by Storm Software under the Apache-2.0 license, and is\n free for commercial and private use. For more information, please visit\n our licensing page at https://stormsoftware.com/licenses/projects/shell-shock.\n\n Website: https://stormsoftware.com\n Repository: https://github.com/storm-software/shell-shock\n Documentation: https://docs.stormsoftware.com/projects/shell-shock\n Contact: https://stormsoftware.com/contact\n\n SPDX-License-Identifier: Apache-2.0\n\n ------------------------------------------------------------------- */\n\nimport { code, For, Show } from \"@alloy-js/core\";\nimport { VarDeclaration } from \"@alloy-js/typescript\";\nimport { Spacing } from \"@powerlines/plugin-alloy/core/components\";\nimport { render } from \"@powerlines/plugin-alloy/render\";\nimport console from \"@shell-shock/plugin-console\";\nimport help from \"@shell-shock/plugin-help\";\nimport type { Plugin } from \"powerlines\";\nimport { BinEntry } from \"./components/bin-entry\";\nimport { CommandEntry } from \"./components/command-entry\";\nimport { CommandRouter } from \"./components/command-router\";\nimport { VirtualCommandEntry } from \"./components/virtual-command-entry\";\nimport { getDefaultOptions } from \"./helpers/get-default-options\";\nimport type { ScriptPresetContext, ScriptPresetOptions } from \"./types/plugin\";\n\n/**\n * The Shell Shock base plugin.\n */\nexport const plugin = <\n TContext extends ScriptPresetContext = ScriptPresetContext\n>(\n options: ScriptPresetOptions = {}\n) => {\n return [\n console(options),\n ...help(options),\n {\n name: \"shell-shock:script-preset\",\n config() {\n this.debug(\n \"Providing default configuration for the Shell Shock `script` preset.\"\n );\n\n return {\n defaultOptions: getDefaultOptions,\n isCaseSensitive: false,\n ...options\n };\n }\n },\n {\n name: \"shell-shock:script-preset:generate-entrypoint\",\n prepare: {\n order: \"post\",\n async handler() {\n this.debug(\n \"Rendering entrypoint modules for the Shell Shock `script` preset.\"\n );\n\n return render(\n this,\n <>\n <BinEntry\n builtinImports={{\n console: [\n \"divider\",\n \"stripAnsi\",\n \"writeLine\",\n \"splitText\",\n \"colors\",\n \"help\"\n ],\n utils: [\"useApp\", \"useArgs\", \"isMinimal\"]\n }}>\n <Show when={Object.keys(this.commands).length > 0}>\n <VarDeclaration\n const\n name=\"args\"\n type=\"string[]\"\n initializer={code`useArgs();`}\n />\n <hbr />\n <CommandRouter segments={[]} commands={this.commands ?? {}} />\n <hbr />\n </Show>\n <Spacing />\n {code`await showBanner();`}\n <Spacing />\n {code`return showHelp();`}\n </BinEntry>\n <Show when={Object.values(this.commands).length > 0}>\n <For each={Object.values(this.commands)} doubleHardline>\n {child => (\n <Show\n when={child.isVirtual}\n fallback={<CommandEntry command={child} />}>\n <VirtualCommandEntry command={child} />\n </Show>\n )}\n </For>\n </Show>\n </>\n );\n }\n }\n }\n ] as Plugin<TContext>[];\n};\n\nexport default plugin;\n"],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.cjs","names":[],"sources":["../src/index.tsx"],"sourcesContent":["/* -------------------------------------------------------------------\n\n ⚡ Storm Software - Shell Shock\n\n This code was released as part of the Shell Shock project. Shell Shock\n is maintained by Storm Software under the Apache-2.0 license, and is\n free for commercial and private use. For more information, please visit\n our licensing page at https://stormsoftware.com/licenses/projects/shell-shock.\n\n Website: https://stormsoftware.com\n Repository: https://github.com/storm-software/shell-shock\n Documentation: https://docs.stormsoftware.com/projects/shell-shock\n Contact: https://stormsoftware.com/contact\n\n SPDX-License-Identifier: Apache-2.0\n\n ------------------------------------------------------------------- */\n\nimport { code, For, Show } from \"@alloy-js/core\";\nimport { VarDeclaration } from \"@alloy-js/typescript\";\nimport { Spacing } from \"@powerlines/plugin-alloy/core/components\";\nimport { render } from \"@powerlines/plugin-alloy/render\";\nimport banner from \"@shell-shock/plugin-banner\";\nimport console from \"@shell-shock/plugin-console\";\nimport help from \"@shell-shock/plugin-help\";\nimport type { Plugin } from \"powerlines\";\nimport { BinEntry } from \"./components/bin-entry\";\nimport { CommandEntry } from \"./components/command-entry\";\nimport { CommandRouter } from \"./components/command-router\";\nimport { VirtualCommandEntry } from \"./components/virtual-command-entry\";\nimport { getDefaultOptions } from \"./helpers/get-default-options\";\nimport type { ScriptPresetContext, ScriptPresetOptions } from \"./types/plugin\";\n\n/**\n * The Shell Shock base plugin.\n */\nexport const plugin = <\n TContext extends ScriptPresetContext = ScriptPresetContext\n>(\n options: ScriptPresetOptions = {}\n) => {\n return [\n ...console<TContext>(options),\n ...help<TContext>(options),\n ...banner<TContext>(options),\n {\n name: \"shell-shock:script-preset\",\n config() {\n this.debug(\n \"Providing default configuration for the Shell Shock `script` preset.\"\n );\n\n return {\n defaultOptions: getDefaultOptions,\n isCaseSensitive: false,\n ...options\n };\n }\n },\n {\n name: \"shell-shock:script-preset:generate-entrypoint\",\n prepare: {\n order: \"post\",\n async handler() {\n this.debug(\n \"Rendering entrypoint modules for the Shell Shock `script` preset.\"\n );\n\n return render(\n this,\n <>\n <BinEntry\n builtinImports={{\n console: [\n \"divider\",\n \"stripAnsi\",\n \"writeLine\",\n \"splitText\",\n \"colors\",\n \"help\"\n ],\n utils: [\"useApp\", \"useArgs\", \"isMinimal\"]\n }}>\n <Show when={Object.keys(this.commands).length > 0}>\n <VarDeclaration\n const\n name=\"args\"\n type=\"string[]\"\n initializer={code`useArgs();`}\n />\n <hbr />\n <CommandRouter segments={[]} commands={this.commands ?? {}} />\n <hbr />\n </Show>\n <Spacing />\n {code`await showBanner();`}\n <Spacing />\n {code`return showHelp();`}\n </BinEntry>\n <Show when={Object.values(this.commands).length > 0}>\n <For each={Object.values(this.commands)} doubleHardline>\n {child => (\n <Show\n when={child.isVirtual}\n fallback={<CommandEntry command={child} />}>\n <VirtualCommandEntry command={child} />\n </Show>\n )}\n </For>\n </Show>\n </>\n );\n }\n }\n }\n ] as Plugin<TContext>[];\n};\n\nexport default plugin;\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;AAqCA,MAAW,UAA8B,UAAA,EAAA,KAAA;AACxC,QAAA;EAAA,4CAAA,QAAA;EAAA,yCAAA,QAAA;EAAA,2CAAA,QAAA;EAAA;GACC,MAAQ;GACN,SAAC;AACH,SAAO,MAAA,uEAAA;AACH,WAAC;KACA,gBAAe;KACf,iBAAiB;KACpB,GAAA;KACE;;GAEH;EAAE;GACD,MAAM;GACN,SAAK;;IAEH,MAAE,UAAO;KACP,MAAE,SAAA;AACF,UAAE,MAAA,oEAAsB;AACxB,wDAAK,MAAA,iDAAA,uCAAA;MACJ,gBAAA;OACH,SAAA;QAAA;QAAA;QAAA;QAAA;QAAA;QAAA;QAAA;OACD,OAAA;QAAA;QAAA;QAAA;QAAA;OACD;MACM,IAAG,WAAY;AACnB,cAAS;wDAAA,qBAAA;SACD,IAAE,OAAK;AACP,iBAAS,OAAC,KAAA,OAAA,SAAA,CAAA,SAAA;;SAEX,IAAA,WAAU;AACZ,iBAAA;2DAAA,qCAAA;;YAEM,MAAM;YACP,MAAA;YACH,aAAA,mBAAA;YACE,CAAA;2DAAA,OAAA,EAAA,CAAA;2DAAA,iDAAA;YACC,UAAA,EAAc;YACZ,IAAA,WAAS;AACP,oBAAC,OAAQ,YAAA,EAAA;;YAEZ,CAAC;2DAAa,OAAA,EAAA,CAAA;WAAA;;SAElB,CAAC;wDAAc,kDAAA,EAAA,CAAA;QAAA,mBAAA;wDAAA,kDAAA,EAAA,CAAA;QAAA,mBAAA;QAAA;;MAEnB,CAAC,kDAAS,qBAAA;MACT,IAAI,OAAI;AACN,cAAM,OAAA,OAAA,OAAA,SAAA,CAAA,SAAA;;MAER,IAAI,WAAK;AACP,8DAAQ,oBAAA;QACN,IAAI,OAAO;AACT,gBAAI,OAAM,OAAQ,OAAA,SAAA;;QAEpB,gBAAK;QACL,WAAU,0DAAA,qBAAA;SACR,IAAG,OAAA;AACD,iBAAM,MAAA;;SAER,IAAC,WAAS;AACT,iEAAyB,+CAAA,EACzB,SAAS,OACT,CAAA;;SAEF,IAAK,WAAM;AACT,iEAAwB,8DAAgB,EACtC,SAAS,OACT,CAAC;;SAEL,CAAC;QACH,CAAC;;MAEL,CAAC,CAAC,CAAC;;IAEP;GACF;EAAC"}
|
package/dist/index.d.cts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.cts","names":[],"sources":["../src/index.tsx"],"mappings":";;;;;;
|
|
1
|
+
{"version":3,"file":"index.d.cts","names":[],"sources":["../src/index.tsx"],"mappings":";;;;;;AAoCA;cAAa,MAAA,oBACM,mBAAA,GAAsB,mBAAA,EAEvC,OAAA,GAAS,mBAAA,KA4EJ,MAAA,CAAO,QAAA"}
|
package/dist/index.d.mts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.mts","names":[],"sources":["../src/index.tsx"],"mappings":";;;;;;
|
|
1
|
+
{"version":3,"file":"index.d.mts","names":[],"sources":["../src/index.tsx"],"mappings":";;;;;;AAoCA;cAAa,MAAA,oBACM,mBAAA,GAAsB,mBAAA,EAEvC,OAAA,GAAS,mBAAA,KA4EJ,MAAA,CAAO,QAAA"}
|
package/dist/index.mjs
CHANGED
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import { plugin as plugin$1 } from "./plugin-help/dist/index.mjs";
|
|
2
1
|
import { BinEntry } from "./components/bin-entry.mjs";
|
|
3
2
|
import { CommandRouter } from "./components/command-router.mjs";
|
|
4
3
|
import { VirtualCommandEntry } from "./components/virtual-command-entry.mjs";
|
|
@@ -9,7 +8,9 @@ import { For, Show, code } from "@alloy-js/core";
|
|
|
9
8
|
import { VarDeclaration } from "@alloy-js/typescript";
|
|
10
9
|
import { Spacing } from "@powerlines/plugin-alloy/core/components";
|
|
11
10
|
import { render } from "@powerlines/plugin-alloy/render";
|
|
11
|
+
import banner from "@shell-shock/plugin-banner";
|
|
12
12
|
import console from "@shell-shock/plugin-console";
|
|
13
|
+
import help from "@shell-shock/plugin-help";
|
|
13
14
|
|
|
14
15
|
//#region src/index.tsx
|
|
15
16
|
/**
|
|
@@ -17,8 +18,9 @@ import console from "@shell-shock/plugin-console";
|
|
|
17
18
|
*/
|
|
18
19
|
const plugin = (options = {}) => {
|
|
19
20
|
return [
|
|
20
|
-
console(options),
|
|
21
|
-
...
|
|
21
|
+
...console(options),
|
|
22
|
+
...help(options),
|
|
23
|
+
...banner(options),
|
|
22
24
|
{
|
|
23
25
|
name: "shell-shock:script-preset",
|
|
24
26
|
config() {
|
package/dist/index.mjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.mjs","names":[],"sources":["../src/index.tsx"],"sourcesContent":["/* -------------------------------------------------------------------\n\n ⚡ Storm Software - Shell Shock\n\n This code was released as part of the Shell Shock project. Shell Shock\n is maintained by Storm Software under the Apache-2.0 license, and is\n free for commercial and private use. For more information, please visit\n our licensing page at https://stormsoftware.com/licenses/projects/shell-shock.\n\n Website: https://stormsoftware.com\n Repository: https://github.com/storm-software/shell-shock\n Documentation: https://docs.stormsoftware.com/projects/shell-shock\n Contact: https://stormsoftware.com/contact\n\n SPDX-License-Identifier: Apache-2.0\n\n ------------------------------------------------------------------- */\n\nimport { code, For, Show } from \"@alloy-js/core\";\nimport { VarDeclaration } from \"@alloy-js/typescript\";\nimport { Spacing } from \"@powerlines/plugin-alloy/core/components\";\nimport { render } from \"@powerlines/plugin-alloy/render\";\nimport console from \"@shell-shock/plugin-console\";\nimport help from \"@shell-shock/plugin-help\";\nimport type { Plugin } from \"powerlines\";\nimport { BinEntry } from \"./components/bin-entry\";\nimport { CommandEntry } from \"./components/command-entry\";\nimport { CommandRouter } from \"./components/command-router\";\nimport { VirtualCommandEntry } from \"./components/virtual-command-entry\";\nimport { getDefaultOptions } from \"./helpers/get-default-options\";\nimport type { ScriptPresetContext, ScriptPresetOptions } from \"./types/plugin\";\n\n/**\n * The Shell Shock base plugin.\n */\nexport const plugin = <\n TContext extends ScriptPresetContext = ScriptPresetContext\n>(\n options: ScriptPresetOptions = {}\n) => {\n return [\n console(options),\n ...help(options),\n {\n name: \"shell-shock:script-preset\",\n config() {\n this.debug(\n \"Providing default configuration for the Shell Shock `script` preset.\"\n );\n\n return {\n defaultOptions: getDefaultOptions,\n isCaseSensitive: false,\n ...options\n };\n }\n },\n {\n name: \"shell-shock:script-preset:generate-entrypoint\",\n prepare: {\n order: \"post\",\n async handler() {\n this.debug(\n \"Rendering entrypoint modules for the Shell Shock `script` preset.\"\n );\n\n return render(\n this,\n <>\n <BinEntry\n builtinImports={{\n console: [\n \"divider\",\n \"stripAnsi\",\n \"writeLine\",\n \"splitText\",\n \"colors\",\n \"help\"\n ],\n utils: [\"useApp\", \"useArgs\", \"isMinimal\"]\n }}>\n <Show when={Object.keys(this.commands).length > 0}>\n <VarDeclaration\n const\n name=\"args\"\n type=\"string[]\"\n initializer={code`useArgs();`}\n />\n <hbr />\n <CommandRouter segments={[]} commands={this.commands ?? {}} />\n <hbr />\n </Show>\n <Spacing />\n {code`await showBanner();`}\n <Spacing />\n {code`return showHelp();`}\n </BinEntry>\n <Show when={Object.values(this.commands).length > 0}>\n <For each={Object.values(this.commands)} doubleHardline>\n {child => (\n <Show\n when={child.isVirtual}\n fallback={<CommandEntry command={child} />}>\n <VirtualCommandEntry command={child} />\n </Show>\n )}\n </For>\n </Show>\n </>\n );\n }\n }\n }\n ] as Plugin<TContext>[];\n};\n\nexport default plugin;\n"],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.mjs","names":[],"sources":["../src/index.tsx"],"sourcesContent":["/* -------------------------------------------------------------------\n\n ⚡ Storm Software - Shell Shock\n\n This code was released as part of the Shell Shock project. Shell Shock\n is maintained by Storm Software under the Apache-2.0 license, and is\n free for commercial and private use. For more information, please visit\n our licensing page at https://stormsoftware.com/licenses/projects/shell-shock.\n\n Website: https://stormsoftware.com\n Repository: https://github.com/storm-software/shell-shock\n Documentation: https://docs.stormsoftware.com/projects/shell-shock\n Contact: https://stormsoftware.com/contact\n\n SPDX-License-Identifier: Apache-2.0\n\n ------------------------------------------------------------------- */\n\nimport { code, For, Show } from \"@alloy-js/core\";\nimport { VarDeclaration } from \"@alloy-js/typescript\";\nimport { Spacing } from \"@powerlines/plugin-alloy/core/components\";\nimport { render } from \"@powerlines/plugin-alloy/render\";\nimport banner from \"@shell-shock/plugin-banner\";\nimport console from \"@shell-shock/plugin-console\";\nimport help from \"@shell-shock/plugin-help\";\nimport type { Plugin } from \"powerlines\";\nimport { BinEntry } from \"./components/bin-entry\";\nimport { CommandEntry } from \"./components/command-entry\";\nimport { CommandRouter } from \"./components/command-router\";\nimport { VirtualCommandEntry } from \"./components/virtual-command-entry\";\nimport { getDefaultOptions } from \"./helpers/get-default-options\";\nimport type { ScriptPresetContext, ScriptPresetOptions } from \"./types/plugin\";\n\n/**\n * The Shell Shock base plugin.\n */\nexport const plugin = <\n TContext extends ScriptPresetContext = ScriptPresetContext\n>(\n options: ScriptPresetOptions = {}\n) => {\n return [\n ...console<TContext>(options),\n ...help<TContext>(options),\n ...banner<TContext>(options),\n {\n name: \"shell-shock:script-preset\",\n config() {\n this.debug(\n \"Providing default configuration for the Shell Shock `script` preset.\"\n );\n\n return {\n defaultOptions: getDefaultOptions,\n isCaseSensitive: false,\n ...options\n };\n }\n },\n {\n name: \"shell-shock:script-preset:generate-entrypoint\",\n prepare: {\n order: \"post\",\n async handler() {\n this.debug(\n \"Rendering entrypoint modules for the Shell Shock `script` preset.\"\n );\n\n return render(\n this,\n <>\n <BinEntry\n builtinImports={{\n console: [\n \"divider\",\n \"stripAnsi\",\n \"writeLine\",\n \"splitText\",\n \"colors\",\n \"help\"\n ],\n utils: [\"useApp\", \"useArgs\", \"isMinimal\"]\n }}>\n <Show when={Object.keys(this.commands).length > 0}>\n <VarDeclaration\n const\n name=\"args\"\n type=\"string[]\"\n initializer={code`useArgs();`}\n />\n <hbr />\n <CommandRouter segments={[]} commands={this.commands ?? {}} />\n <hbr />\n </Show>\n <Spacing />\n {code`await showBanner();`}\n <Spacing />\n {code`return showHelp();`}\n </BinEntry>\n <Show when={Object.values(this.commands).length > 0}>\n <For each={Object.values(this.commands)} doubleHardline>\n {child => (\n <Show\n when={child.isVirtual}\n fallback={<CommandEntry command={child} />}>\n <VirtualCommandEntry command={child} />\n </Show>\n )}\n </For>\n </Show>\n </>\n );\n }\n }\n }\n ] as Plugin<TContext>[];\n};\n\nexport default plugin;\n"],"mappings":";;;;;;;;;;;;;;;;;;AAqCA,MAAW,UAA8B,UAAA,EAAA,KAAA;AACxC,QAAA;EAAA,GAAA,QAAA,QAAA;EAAA,GAAA,KAAA,QAAA;EAAA,GAAA,OAAA,QAAA;EAAA;GACC,MAAQ;GACN,SAAC;AACH,SAAO,MAAA,uEAAA;AACH,WAAC;KACA,gBAAe;KACf,iBAAiB;KACpB,GAAA;KACE;;GAEH;EAAE;GACD,MAAM;GACN,SAAK;;IAEH,MAAE,UAAO;KACP,MAAE,SAAA;AACF,UAAE,MAAA,oEAAsB;AACxB,YAAK,OAAA,MAAA,CAAA,gBAAA,UAAA;MACJ,gBAAA;OACH,SAAA;QAAA;QAAA;QAAA;QAAA;QAAA;QAAA;QAAA;OACD,OAAA;QAAA;QAAA;QAAA;QAAA;OACD;MACM,IAAG,WAAY;AACnB,cAAS;QAAA,gBAAA,MAAA;SACD,IAAE,OAAK;AACP,iBAAS,OAAC,KAAA,OAAA,SAAA,CAAA,SAAA;;SAEX,IAAA,WAAU;AACZ,iBAAA;WAAA,gBAAA,gBAAA;;YAEM,MAAM;YACP,MAAA;YACH,aAAA,IAAA;YACE,CAAA;WAAA,gBAAA,OAAA,EAAA,CAAA;WAAA,gBAAA,eAAA;YACC,UAAA,EAAc;YACZ,IAAA,WAAS;AACP,oBAAC,OAAQ,YAAA,EAAA;;YAEZ,CAAC;WAAE,gBAAW,OAAA,EAAA,CAAA;WAAA;;SAElB,CAAC;QAAE,gBAAY,SAAA,EAAA,CAAA;QAAA,IAAA;QAAA,gBAAA,SAAA,EAAA,CAAA;QAAA,IAAA;QAAA;;MAEnB,CAAC,EAAE,gBAAO,MAAA;MACT,IAAI,OAAI;AACN,cAAM,OAAA,OAAA,OAAA,SAAA,CAAA,SAAA;;MAER,IAAI,WAAK;AACP,cAAO,gBAAC,KAAA;QACN,IAAI,OAAO;AACT,gBAAI,OAAM,OAAQ,OAAA,SAAA;;QAEpB,gBAAK;QACL,WAAU,UAAA,gBAAA,MAAA;SACR,IAAG,OAAA;AACD,iBAAM,MAAA;;SAER,IAAC,WAAS;AACT,iBAAK,gBAAoB,cAAA,EACzB,SAAS,OACT,CAAA;;SAEF,IAAK,WAAM;AACT,iBAAQ,gBAAgB,qBAAgB,EACtC,SAAS,OACT,CAAC;;SAEL,CAAC;QACH,CAAC;;MAEL,CAAC,CAAC,CAAC;;IAEP;GACF;EAAC"}
|
package/dist/types/plugin.d.cts
CHANGED
|
@@ -1,11 +1,12 @@
|
|
|
1
|
-
import { HelpPluginContext, HelpPluginOptions, HelpPluginResolvedConfig, HelpPluginUserConfig } from "../plugin-help/dist/types/plugin.cjs";
|
|
2
1
|
import { CommandBase, CommandOption, Context, Options, ResolvedConfig, UserConfig } from "@shell-shock/core";
|
|
3
2
|
import { AlloyPluginContext } from "@powerlines/plugin-alloy/types/plugin";
|
|
3
|
+
import { BannerPluginContext, BannerPluginOptions, BannerPluginResolvedConfig, BannerPluginUserConfig } from "@shell-shock/plugin-banner";
|
|
4
4
|
import { ConsolePluginContext, ConsolePluginOptions, ConsolePluginResolvedConfig, ConsolePluginUserConfig } from "@shell-shock/plugin-console";
|
|
5
|
+
import { HelpPluginContext, HelpPluginOptions, HelpPluginResolvedConfig, HelpPluginUserConfig } from "@shell-shock/plugin-help";
|
|
5
6
|
import { ThemePluginContext, ThemePluginOptions, ThemePluginResolvedConfig, ThemePluginUserConfig } from "@shell-shock/plugin-theme";
|
|
6
7
|
|
|
7
8
|
//#region src/types/plugin.d.ts
|
|
8
|
-
type ScriptPresetOptions = Omit<Options, "defaultOptions"> & ThemePluginOptions & ConsolePluginOptions & HelpPluginOptions & {
|
|
9
|
+
type ScriptPresetOptions = Omit<Options, "defaultOptions"> & ThemePluginOptions & ConsolePluginOptions & HelpPluginOptions & BannerPluginOptions & {
|
|
9
10
|
/**
|
|
10
11
|
* A set of default command options to apply to each command.
|
|
11
12
|
*
|
|
@@ -19,9 +20,9 @@ type ScriptPresetOptions = Omit<Options, "defaultOptions"> & ThemePluginOptions
|
|
|
19
20
|
*/
|
|
20
21
|
defaultOptions?: CommandOption[] | ((context: Context, input: CommandBase) => CommandOption[]) | false;
|
|
21
22
|
};
|
|
22
|
-
type ScriptPresetUserConfig = UserConfig & ScriptPresetOptions & ThemePluginUserConfig & ConsolePluginUserConfig & HelpPluginUserConfig;
|
|
23
|
-
type ScriptPresetResolvedConfig = ResolvedConfig & ScriptPresetOptions & ThemePluginResolvedConfig & ConsolePluginResolvedConfig & HelpPluginResolvedConfig;
|
|
24
|
-
type ScriptPresetContext<TResolvedConfig extends ScriptPresetResolvedConfig = ScriptPresetResolvedConfig> = AlloyPluginContext<TResolvedConfig> & Context<TResolvedConfig> & ThemePluginContext<TResolvedConfig> & ConsolePluginContext<TResolvedConfig> & HelpPluginContext<TResolvedConfig>;
|
|
23
|
+
type ScriptPresetUserConfig = UserConfig & ScriptPresetOptions & ThemePluginUserConfig & ConsolePluginUserConfig & HelpPluginUserConfig & BannerPluginUserConfig;
|
|
24
|
+
type ScriptPresetResolvedConfig = ResolvedConfig & ScriptPresetOptions & ThemePluginResolvedConfig & ConsolePluginResolvedConfig & HelpPluginResolvedConfig & BannerPluginResolvedConfig;
|
|
25
|
+
type ScriptPresetContext<TResolvedConfig extends ScriptPresetResolvedConfig = ScriptPresetResolvedConfig> = AlloyPluginContext<TResolvedConfig> & Context<TResolvedConfig> & ThemePluginContext<TResolvedConfig> & ConsolePluginContext<TResolvedConfig> & HelpPluginContext<TResolvedConfig> & BannerPluginContext<TResolvedConfig>;
|
|
25
26
|
//#endregion
|
|
26
27
|
export { ScriptPresetContext, ScriptPresetOptions, ScriptPresetResolvedConfig, ScriptPresetUserConfig };
|
|
27
28
|
//# sourceMappingURL=plugin.d.cts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"plugin.d.cts","names":[],"sources":["../../src/types/plugin.ts"],"mappings":"
|
|
1
|
+
{"version":3,"file":"plugin.d.cts","names":[],"sources":["../../src/types/plugin.ts"],"mappings":";;;;;;;;KAoDY,mBAAA,GAAsB,IAAA,CAAK,OAAA,sBACrC,kBAAA,GACA,oBAAA,GACA,iBAAA,GACA,mBAAA;;AAJF;;;;;;;;;;EAgBI,cAAA,GACI,aAAA,OACE,OAAA,EAAS,OAAA,EAAS,KAAA,EAAO,WAAA,KAAgB,aAAA;AAAA;AAAA,KAIvC,sBAAA,GAAyB,UAAA,GACnC,mBAAA,GACA,qBAAA,GACA,uBAAA,GACA,oBAAA,GACA,sBAAA;AAAA,KAEU,0BAAA,GAA6B,cAAA,GACvC,mBAAA,GACA,yBAAA,GACA,2BAAA,GACA,wBAAA,GACA,0BAAA;AAAA,KAEU,mBAAA,yBACc,0BAAA,GACtB,0BAAA,IACA,kBAAA,CAAmB,eAAA,IACrB,OAAA,CAAQ,eAAA,IACR,kBAAA,CAAmB,eAAA,IACnB,oBAAA,CAAqB,eAAA,IACrB,iBAAA,CAAkB,eAAA,IAClB,mBAAA,CAAoB,eAAA"}
|
package/dist/types/plugin.d.mts
CHANGED
|
@@ -1,11 +1,12 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { BannerPluginContext, BannerPluginOptions, BannerPluginResolvedConfig, BannerPluginUserConfig } from "@shell-shock/plugin-banner";
|
|
2
2
|
import { ConsolePluginContext, ConsolePluginOptions, ConsolePluginResolvedConfig, ConsolePluginUserConfig } from "@shell-shock/plugin-console";
|
|
3
|
+
import { HelpPluginContext, HelpPluginOptions, HelpPluginResolvedConfig, HelpPluginUserConfig } from "@shell-shock/plugin-help";
|
|
3
4
|
import { CommandBase, CommandOption, Context, Options, ResolvedConfig, UserConfig } from "@shell-shock/core";
|
|
4
|
-
import { ThemePluginContext, ThemePluginOptions, ThemePluginResolvedConfig, ThemePluginUserConfig } from "@shell-shock/plugin-theme";
|
|
5
5
|
import { AlloyPluginContext } from "@powerlines/plugin-alloy/types/plugin";
|
|
6
|
+
import { ThemePluginContext, ThemePluginOptions, ThemePluginResolvedConfig, ThemePluginUserConfig } from "@shell-shock/plugin-theme";
|
|
6
7
|
|
|
7
8
|
//#region src/types/plugin.d.ts
|
|
8
|
-
type ScriptPresetOptions = Omit<Options, "defaultOptions"> & ThemePluginOptions & ConsolePluginOptions & HelpPluginOptions & {
|
|
9
|
+
type ScriptPresetOptions = Omit<Options, "defaultOptions"> & ThemePluginOptions & ConsolePluginOptions & HelpPluginOptions & BannerPluginOptions & {
|
|
9
10
|
/**
|
|
10
11
|
* A set of default command options to apply to each command.
|
|
11
12
|
*
|
|
@@ -19,9 +20,9 @@ type ScriptPresetOptions = Omit<Options, "defaultOptions"> & ThemePluginOptions
|
|
|
19
20
|
*/
|
|
20
21
|
defaultOptions?: CommandOption[] | ((context: Context, input: CommandBase) => CommandOption[]) | false;
|
|
21
22
|
};
|
|
22
|
-
type ScriptPresetUserConfig = UserConfig & ScriptPresetOptions & ThemePluginUserConfig & ConsolePluginUserConfig & HelpPluginUserConfig;
|
|
23
|
-
type ScriptPresetResolvedConfig = ResolvedConfig & ScriptPresetOptions & ThemePluginResolvedConfig & ConsolePluginResolvedConfig & HelpPluginResolvedConfig;
|
|
24
|
-
type ScriptPresetContext<TResolvedConfig extends ScriptPresetResolvedConfig = ScriptPresetResolvedConfig> = AlloyPluginContext<TResolvedConfig> & Context<TResolvedConfig> & ThemePluginContext<TResolvedConfig> & ConsolePluginContext<TResolvedConfig> & HelpPluginContext<TResolvedConfig>;
|
|
23
|
+
type ScriptPresetUserConfig = UserConfig & ScriptPresetOptions & ThemePluginUserConfig & ConsolePluginUserConfig & HelpPluginUserConfig & BannerPluginUserConfig;
|
|
24
|
+
type ScriptPresetResolvedConfig = ResolvedConfig & ScriptPresetOptions & ThemePluginResolvedConfig & ConsolePluginResolvedConfig & HelpPluginResolvedConfig & BannerPluginResolvedConfig;
|
|
25
|
+
type ScriptPresetContext<TResolvedConfig extends ScriptPresetResolvedConfig = ScriptPresetResolvedConfig> = AlloyPluginContext<TResolvedConfig> & Context<TResolvedConfig> & ThemePluginContext<TResolvedConfig> & ConsolePluginContext<TResolvedConfig> & HelpPluginContext<TResolvedConfig> & BannerPluginContext<TResolvedConfig>;
|
|
25
26
|
//#endregion
|
|
26
27
|
export { ScriptPresetContext, ScriptPresetOptions, ScriptPresetResolvedConfig, ScriptPresetUserConfig };
|
|
27
28
|
//# sourceMappingURL=plugin.d.mts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"plugin.d.mts","names":[],"sources":["../../src/types/plugin.ts"],"mappings":"
|
|
1
|
+
{"version":3,"file":"plugin.d.mts","names":[],"sources":["../../src/types/plugin.ts"],"mappings":";;;;;;;;KAoDY,mBAAA,GAAsB,IAAA,CAAK,OAAA,sBACrC,kBAAA,GACA,oBAAA,GACA,iBAAA,GACA,mBAAA;;AAJF;;;;;;;;;;EAgBI,cAAA,GACI,aAAA,OACE,OAAA,EAAS,OAAA,EAAS,KAAA,EAAO,WAAA,KAAgB,aAAA;AAAA;AAAA,KAIvC,sBAAA,GAAyB,UAAA,GACnC,mBAAA,GACA,qBAAA,GACA,uBAAA,GACA,oBAAA,GACA,sBAAA;AAAA,KAEU,0BAAA,GAA6B,cAAA,GACvC,mBAAA,GACA,yBAAA,GACA,2BAAA,GACA,wBAAA,GACA,0BAAA;AAAA,KAEU,mBAAA,yBACc,0BAAA,GACtB,0BAAA,IACA,kBAAA,CAAmB,eAAA,IACrB,OAAA,CAAQ,eAAA,IACR,kBAAA,CAAmB,eAAA,IACnB,oBAAA,CAAqB,eAAA,IACrB,iBAAA,CAAkB,eAAA,IAClB,mBAAA,CAAoB,eAAA"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@shell-shock/preset-script",
|
|
3
|
-
"version": "0.6.
|
|
3
|
+
"version": "0.6.29",
|
|
4
4
|
"private": false,
|
|
5
5
|
"description": "A Shell Shock preset that generates a fully-featured script application.",
|
|
6
6
|
"keywords": [
|
|
@@ -195,23 +195,25 @@
|
|
|
195
195
|
"dependencies": {
|
|
196
196
|
"@alloy-js/core": "0.23.0-dev.8",
|
|
197
197
|
"@alloy-js/typescript": "0.23.0-dev.4",
|
|
198
|
-
"@powerlines/deepkit": "^0.6.
|
|
199
|
-
"@powerlines/plugin-alloy": "^0.25.
|
|
200
|
-
"@powerlines/plugin-plugin": "^0.12.
|
|
201
|
-
"@shell-shock/core": "^0.13.
|
|
202
|
-
"@shell-shock/plugin-
|
|
203
|
-
"@shell-shock/plugin-
|
|
198
|
+
"@powerlines/deepkit": "^0.6.147",
|
|
199
|
+
"@powerlines/plugin-alloy": "^0.25.54",
|
|
200
|
+
"@powerlines/plugin-plugin": "^0.12.319",
|
|
201
|
+
"@shell-shock/core": "^0.13.3",
|
|
202
|
+
"@shell-shock/plugin-banner": "^0.1.1",
|
|
203
|
+
"@shell-shock/plugin-help": "^0.1.5",
|
|
204
|
+
"@shell-shock/plugin-console": "^0.1.14",
|
|
205
|
+
"@shell-shock/plugin-theme": "^0.3.18",
|
|
204
206
|
"@stryke/helpers": "^0.10.6",
|
|
205
207
|
"@stryke/path": "^0.27.2",
|
|
206
208
|
"@stryke/string-format": "^0.17.6",
|
|
207
209
|
"defu": "^6.1.4",
|
|
208
|
-
"powerlines": "^0.42.
|
|
210
|
+
"powerlines": "^0.42.9"
|
|
209
211
|
},
|
|
210
212
|
"devDependencies": {
|
|
211
213
|
"@babel/core": "^7.29.0",
|
|
212
|
-
"@powerlines/plugin-alloy": "^0.25.
|
|
214
|
+
"@powerlines/plugin-alloy": "^0.25.54",
|
|
213
215
|
"@types/node": "^25.5.0"
|
|
214
216
|
},
|
|
215
217
|
"publishConfig": { "access": "public" },
|
|
216
|
-
"gitHead": "
|
|
218
|
+
"gitHead": "86ac1c51d3258bded9e493024e6631d241f62dd2"
|
|
217
219
|
}
|