dlw-machine-setup 0.11.0 → 0.11.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.
Files changed (2) hide show
  1. package/bin/installer.js +111 -296
  2. package/package.json +1 -1
package/bin/installer.js CHANGED
@@ -60,49 +60,49 @@ var require_yoctocolors_cjs = __commonJS({
60
60
  return result;
61
61
  };
62
62
  };
63
- var colors5 = {};
64
- colors5.reset = format(0, 0);
65
- colors5.bold = format(1, 22);
66
- colors5.dim = format(2, 22);
67
- colors5.italic = format(3, 23);
68
- colors5.underline = format(4, 24);
69
- colors5.overline = format(53, 55);
70
- colors5.inverse = format(7, 27);
71
- colors5.hidden = format(8, 28);
72
- colors5.strikethrough = format(9, 29);
73
- colors5.black = format(30, 39);
74
- colors5.red = format(31, 39);
75
- colors5.green = format(32, 39);
76
- colors5.yellow = format(33, 39);
77
- colors5.blue = format(34, 39);
78
- colors5.magenta = format(35, 39);
79
- colors5.cyan = format(36, 39);
80
- colors5.white = format(37, 39);
81
- colors5.gray = format(90, 39);
82
- colors5.bgBlack = format(40, 49);
83
- colors5.bgRed = format(41, 49);
84
- colors5.bgGreen = format(42, 49);
85
- colors5.bgYellow = format(43, 49);
86
- colors5.bgBlue = format(44, 49);
87
- colors5.bgMagenta = format(45, 49);
88
- colors5.bgCyan = format(46, 49);
89
- colors5.bgWhite = format(47, 49);
90
- colors5.bgGray = format(100, 49);
91
- colors5.redBright = format(91, 39);
92
- colors5.greenBright = format(92, 39);
93
- colors5.yellowBright = format(93, 39);
94
- colors5.blueBright = format(94, 39);
95
- colors5.magentaBright = format(95, 39);
96
- colors5.cyanBright = format(96, 39);
97
- colors5.whiteBright = format(97, 39);
98
- colors5.bgRedBright = format(101, 49);
99
- colors5.bgGreenBright = format(102, 49);
100
- colors5.bgYellowBright = format(103, 49);
101
- colors5.bgBlueBright = format(104, 49);
102
- colors5.bgMagentaBright = format(105, 49);
103
- colors5.bgCyanBright = format(106, 49);
104
- colors5.bgWhiteBright = format(107, 49);
105
- module2.exports = colors5;
63
+ var colors4 = {};
64
+ colors4.reset = format(0, 0);
65
+ colors4.bold = format(1, 22);
66
+ colors4.dim = format(2, 22);
67
+ colors4.italic = format(3, 23);
68
+ colors4.underline = format(4, 24);
69
+ colors4.overline = format(53, 55);
70
+ colors4.inverse = format(7, 27);
71
+ colors4.hidden = format(8, 28);
72
+ colors4.strikethrough = format(9, 29);
73
+ colors4.black = format(30, 39);
74
+ colors4.red = format(31, 39);
75
+ colors4.green = format(32, 39);
76
+ colors4.yellow = format(33, 39);
77
+ colors4.blue = format(34, 39);
78
+ colors4.magenta = format(35, 39);
79
+ colors4.cyan = format(36, 39);
80
+ colors4.white = format(37, 39);
81
+ colors4.gray = format(90, 39);
82
+ colors4.bgBlack = format(40, 49);
83
+ colors4.bgRed = format(41, 49);
84
+ colors4.bgGreen = format(42, 49);
85
+ colors4.bgYellow = format(43, 49);
86
+ colors4.bgBlue = format(44, 49);
87
+ colors4.bgMagenta = format(45, 49);
88
+ colors4.bgCyan = format(46, 49);
89
+ colors4.bgWhite = format(47, 49);
90
+ colors4.bgGray = format(100, 49);
91
+ colors4.redBright = format(91, 39);
92
+ colors4.greenBright = format(92, 39);
93
+ colors4.yellowBright = format(93, 39);
94
+ colors4.blueBright = format(94, 39);
95
+ colors4.magentaBright = format(95, 39);
96
+ colors4.cyanBright = format(96, 39);
97
+ colors4.whiteBright = format(97, 39);
98
+ colors4.bgRedBright = format(101, 49);
99
+ colors4.bgGreenBright = format(102, 49);
100
+ colors4.bgYellowBright = format(103, 49);
101
+ colors4.bgBlueBright = format(104, 49);
102
+ colors4.bgMagentaBright = format(105, 49);
103
+ colors4.bgCyanBright = format(106, 49);
104
+ colors4.bgWhiteBright = format(107, 49);
105
+ module2.exports = colors4;
106
106
  }
107
107
  });
108
108
 
@@ -1612,14 +1612,14 @@ var require_lib = __commonJS({
1612
1612
  var require_ansi_escapes = __commonJS({
1613
1613
  "node_modules/ansi-escapes/index.js"(exports2, module2) {
1614
1614
  "use strict";
1615
- var ansiEscapes5 = module2.exports;
1616
- module2.exports.default = ansiEscapes5;
1615
+ var ansiEscapes4 = module2.exports;
1616
+ module2.exports.default = ansiEscapes4;
1617
1617
  var ESC = "\x1B[";
1618
1618
  var OSC = "\x1B]";
1619
1619
  var BEL = "\x07";
1620
1620
  var SEP = ";";
1621
1621
  var isTerminalApp = process.env.TERM_PROGRAM === "Apple_Terminal";
1622
- ansiEscapes5.cursorTo = (x, y) => {
1622
+ ansiEscapes4.cursorTo = (x, y) => {
1623
1623
  if (typeof x !== "number") {
1624
1624
  throw new TypeError("The `x` argument is required");
1625
1625
  }
@@ -1628,7 +1628,7 @@ var require_ansi_escapes = __commonJS({
1628
1628
  }
1629
1629
  return ESC + (y + 1) + ";" + (x + 1) + "H";
1630
1630
  };
1631
- ansiEscapes5.cursorMove = (x, y) => {
1631
+ ansiEscapes4.cursorMove = (x, y) => {
1632
1632
  if (typeof x !== "number") {
1633
1633
  throw new TypeError("The `x` argument is required");
1634
1634
  }
@@ -1645,46 +1645,46 @@ var require_ansi_escapes = __commonJS({
1645
1645
  }
1646
1646
  return ret;
1647
1647
  };
1648
- ansiEscapes5.cursorUp = (count = 1) => ESC + count + "A";
1649
- ansiEscapes5.cursorDown = (count = 1) => ESC + count + "B";
1650
- ansiEscapes5.cursorForward = (count = 1) => ESC + count + "C";
1651
- ansiEscapes5.cursorBackward = (count = 1) => ESC + count + "D";
1652
- ansiEscapes5.cursorLeft = ESC + "G";
1653
- ansiEscapes5.cursorSavePosition = isTerminalApp ? "\x1B7" : ESC + "s";
1654
- ansiEscapes5.cursorRestorePosition = isTerminalApp ? "\x1B8" : ESC + "u";
1655
- ansiEscapes5.cursorGetPosition = ESC + "6n";
1656
- ansiEscapes5.cursorNextLine = ESC + "E";
1657
- ansiEscapes5.cursorPrevLine = ESC + "F";
1658
- ansiEscapes5.cursorHide = ESC + "?25l";
1659
- ansiEscapes5.cursorShow = ESC + "?25h";
1660
- ansiEscapes5.eraseLines = (count) => {
1648
+ ansiEscapes4.cursorUp = (count = 1) => ESC + count + "A";
1649
+ ansiEscapes4.cursorDown = (count = 1) => ESC + count + "B";
1650
+ ansiEscapes4.cursorForward = (count = 1) => ESC + count + "C";
1651
+ ansiEscapes4.cursorBackward = (count = 1) => ESC + count + "D";
1652
+ ansiEscapes4.cursorLeft = ESC + "G";
1653
+ ansiEscapes4.cursorSavePosition = isTerminalApp ? "\x1B7" : ESC + "s";
1654
+ ansiEscapes4.cursorRestorePosition = isTerminalApp ? "\x1B8" : ESC + "u";
1655
+ ansiEscapes4.cursorGetPosition = ESC + "6n";
1656
+ ansiEscapes4.cursorNextLine = ESC + "E";
1657
+ ansiEscapes4.cursorPrevLine = ESC + "F";
1658
+ ansiEscapes4.cursorHide = ESC + "?25l";
1659
+ ansiEscapes4.cursorShow = ESC + "?25h";
1660
+ ansiEscapes4.eraseLines = (count) => {
1661
1661
  let clear = "";
1662
1662
  for (let i = 0; i < count; i++) {
1663
- clear += ansiEscapes5.eraseLine + (i < count - 1 ? ansiEscapes5.cursorUp() : "");
1663
+ clear += ansiEscapes4.eraseLine + (i < count - 1 ? ansiEscapes4.cursorUp() : "");
1664
1664
  }
1665
1665
  if (count) {
1666
- clear += ansiEscapes5.cursorLeft;
1666
+ clear += ansiEscapes4.cursorLeft;
1667
1667
  }
1668
1668
  return clear;
1669
1669
  };
1670
- ansiEscapes5.eraseEndLine = ESC + "K";
1671
- ansiEscapes5.eraseStartLine = ESC + "1K";
1672
- ansiEscapes5.eraseLine = ESC + "2K";
1673
- ansiEscapes5.eraseDown = ESC + "J";
1674
- ansiEscapes5.eraseUp = ESC + "1J";
1675
- ansiEscapes5.eraseScreen = ESC + "2J";
1676
- ansiEscapes5.scrollUp = ESC + "S";
1677
- ansiEscapes5.scrollDown = ESC + "T";
1678
- ansiEscapes5.clearScreen = "\x1Bc";
1679
- ansiEscapes5.clearTerminal = process.platform === "win32" ? `${ansiEscapes5.eraseScreen}${ESC}0f` : (
1670
+ ansiEscapes4.eraseEndLine = ESC + "K";
1671
+ ansiEscapes4.eraseStartLine = ESC + "1K";
1672
+ ansiEscapes4.eraseLine = ESC + "2K";
1673
+ ansiEscapes4.eraseDown = ESC + "J";
1674
+ ansiEscapes4.eraseUp = ESC + "1J";
1675
+ ansiEscapes4.eraseScreen = ESC + "2J";
1676
+ ansiEscapes4.scrollUp = ESC + "S";
1677
+ ansiEscapes4.scrollDown = ESC + "T";
1678
+ ansiEscapes4.clearScreen = "\x1Bc";
1679
+ ansiEscapes4.clearTerminal = process.platform === "win32" ? `${ansiEscapes4.eraseScreen}${ESC}0f` : (
1680
1680
  // 1. Erases the screen (Only done in case `2` is not supported)
1681
1681
  // 2. Erases the whole screen including scrollback buffer
1682
1682
  // 3. Moves cursor to the top-left position
1683
1683
  // More info: https://www.real-world-systems.com/docs/ANSIcode.html
1684
- `${ansiEscapes5.eraseScreen}${ESC}3J${ESC}H`
1684
+ `${ansiEscapes4.eraseScreen}${ESC}3J${ESC}H`
1685
1685
  );
1686
- ansiEscapes5.beep = BEL;
1687
- ansiEscapes5.link = (text, url) => {
1686
+ ansiEscapes4.beep = BEL;
1687
+ ansiEscapes4.link = (text, url) => {
1688
1688
  return [
1689
1689
  OSC,
1690
1690
  "8",
@@ -1700,7 +1700,7 @@ var require_ansi_escapes = __commonJS({
1700
1700
  BEL
1701
1701
  ].join("");
1702
1702
  };
1703
- ansiEscapes5.image = (buffer, options = {}) => {
1703
+ ansiEscapes4.image = (buffer, options = {}) => {
1704
1704
  let ret = `${OSC}1337;File=inline=1`;
1705
1705
  if (options.width) {
1706
1706
  ret += `;width=${options.width}`;
@@ -1713,7 +1713,7 @@ var require_ansi_escapes = __commonJS({
1713
1713
  }
1714
1714
  return ret + ":" + buffer.toString("base64") + BEL;
1715
1715
  };
1716
- ansiEscapes5.iTerm = {
1716
+ ansiEscapes4.iTerm = {
1717
1717
  setCwd: (cwd = process.cwd()) => `${OSC}50;CurrentDir=${cwd}${BEL}`,
1718
1718
  annotation: (message, options = {}) => {
1719
1719
  let ret = `${OSC}1337;`;
@@ -1748,7 +1748,6 @@ var isDownKey = (key) => (
1748
1748
  key.name === "j" || // Emacs keybinding
1749
1749
  key.ctrl && key.name === "n"
1750
1750
  );
1751
- var isSpaceKey = (key) => key.name === "space";
1752
1751
  var isBackspaceKey = (key) => key.name === "backspace";
1753
1752
  var isNumberKey = (key) => "123456789".includes(key.name);
1754
1753
  var isEnterKey = (key) => key.name === "enter" || key.name === "return";
@@ -2840,179 +2839,8 @@ var Separator = class {
2840
2839
  }
2841
2840
  };
2842
2841
 
2843
- // node_modules/@inquirer/checkbox/dist/esm/index.mjs
2844
- var import_yoctocolors_cjs3 = __toESM(require_yoctocolors_cjs(), 1);
2845
- var import_ansi_escapes2 = __toESM(require_ansi_escapes(), 1);
2846
- var checkboxTheme = {
2847
- icon: {
2848
- checked: import_yoctocolors_cjs3.default.green(esm_default.circleFilled),
2849
- unchecked: esm_default.circle,
2850
- cursor: esm_default.pointer
2851
- },
2852
- style: {
2853
- disabledChoice: (text) => import_yoctocolors_cjs3.default.dim(`- ${text}`),
2854
- renderSelectedChoices: (selectedChoices) => selectedChoices.map((choice) => choice.short).join(", "),
2855
- description: (text) => import_yoctocolors_cjs3.default.cyan(text)
2856
- },
2857
- helpMode: "auto"
2858
- };
2859
- function isSelectable(item) {
2860
- return !Separator.isSeparator(item) && !item.disabled;
2861
- }
2862
- function isChecked(item) {
2863
- return isSelectable(item) && Boolean(item.checked);
2864
- }
2865
- function toggle(item) {
2866
- return isSelectable(item) ? { ...item, checked: !item.checked } : item;
2867
- }
2868
- function check(checked) {
2869
- return function(item) {
2870
- return isSelectable(item) ? { ...item, checked } : item;
2871
- };
2872
- }
2873
- function normalizeChoices(choices) {
2874
- return choices.map((choice) => {
2875
- if (Separator.isSeparator(choice))
2876
- return choice;
2877
- if (typeof choice === "string") {
2878
- return {
2879
- value: choice,
2880
- name: choice,
2881
- short: choice,
2882
- disabled: false,
2883
- checked: false
2884
- };
2885
- }
2886
- const name = choice.name ?? String(choice.value);
2887
- return {
2888
- value: choice.value,
2889
- name,
2890
- short: choice.short ?? name,
2891
- description: choice.description,
2892
- disabled: choice.disabled ?? false,
2893
- checked: choice.checked ?? false
2894
- };
2895
- });
2896
- }
2897
- var esm_default2 = createPrompt((config, done) => {
2898
- const { instructions, pageSize = 7, loop = true, required, validate = () => true } = config;
2899
- const theme = makeTheme(checkboxTheme, config.theme);
2900
- const prefix = usePrefix({ theme });
2901
- const firstRender = useRef(true);
2902
- const [status, setStatus] = useState("pending");
2903
- const [items, setItems] = useState(normalizeChoices(config.choices));
2904
- const bounds = useMemo(() => {
2905
- const first = items.findIndex(isSelectable);
2906
- const last = items.findLastIndex(isSelectable);
2907
- if (first < 0) {
2908
- throw new ValidationError("[checkbox prompt] No selectable choices. All choices are disabled.");
2909
- }
2910
- return { first, last };
2911
- }, [items]);
2912
- const [active, setActive] = useState(bounds.first);
2913
- const [showHelpTip, setShowHelpTip] = useState(true);
2914
- const [errorMsg, setError] = useState();
2915
- useKeypress(async (key) => {
2916
- if (isEnterKey(key)) {
2917
- const selection = items.filter(isChecked);
2918
- const isValid = await validate([...selection]);
2919
- if (required && !items.some(isChecked)) {
2920
- setError("At least one choice must be selected");
2921
- } else if (isValid === true) {
2922
- setStatus("done");
2923
- done(selection.map((choice) => choice.value));
2924
- } else {
2925
- setError(isValid || "You must select a valid value");
2926
- }
2927
- } else if (isUpKey(key) || isDownKey(key)) {
2928
- if (loop || isUpKey(key) && active !== bounds.first || isDownKey(key) && active !== bounds.last) {
2929
- const offset = isUpKey(key) ? -1 : 1;
2930
- let next = active;
2931
- do {
2932
- next = (next + offset + items.length) % items.length;
2933
- } while (!isSelectable(items[next]));
2934
- setActive(next);
2935
- }
2936
- } else if (isSpaceKey(key)) {
2937
- setError(void 0);
2938
- setShowHelpTip(false);
2939
- setItems(items.map((choice, i) => i === active ? toggle(choice) : choice));
2940
- } else if (key.name === "a") {
2941
- const selectAll = items.some((choice) => isSelectable(choice) && !choice.checked);
2942
- setItems(items.map(check(selectAll)));
2943
- } else if (key.name === "i") {
2944
- setItems(items.map(toggle));
2945
- } else if (isNumberKey(key)) {
2946
- const position = Number(key.name) - 1;
2947
- const item = items[position];
2948
- if (item != null && isSelectable(item)) {
2949
- setActive(position);
2950
- setItems(items.map((choice, i) => i === position ? toggle(choice) : choice));
2951
- }
2952
- }
2953
- });
2954
- const message = theme.style.message(config.message);
2955
- let description;
2956
- const page = usePagination({
2957
- items,
2958
- active,
2959
- renderItem({ item, isActive }) {
2960
- if (Separator.isSeparator(item)) {
2961
- return ` ${item.separator}`;
2962
- }
2963
- if (item.disabled) {
2964
- const disabledLabel = typeof item.disabled === "string" ? item.disabled : "(disabled)";
2965
- return theme.style.disabledChoice(`${item.name} ${disabledLabel}`);
2966
- }
2967
- if (isActive) {
2968
- description = item.description;
2969
- }
2970
- const checkbox = item.checked ? theme.icon.checked : theme.icon.unchecked;
2971
- const color = isActive ? theme.style.highlight : (x) => x;
2972
- const cursor = isActive ? theme.icon.cursor : " ";
2973
- return color(`${cursor}${checkbox} ${item.name}`);
2974
- },
2975
- pageSize,
2976
- loop
2977
- });
2978
- if (status === "done") {
2979
- const selection = items.filter(isChecked);
2980
- const answer = theme.style.answer(theme.style.renderSelectedChoices(selection, items));
2981
- return `${prefix} ${message} ${answer}`;
2982
- }
2983
- let helpTipTop = "";
2984
- let helpTipBottom = "";
2985
- if (theme.helpMode === "always" || theme.helpMode === "auto" && showHelpTip && (instructions === void 0 || instructions)) {
2986
- if (typeof instructions === "string") {
2987
- helpTipTop = instructions;
2988
- } else {
2989
- const keys = [
2990
- `${theme.style.key("space")} to select`,
2991
- `${theme.style.key("a")} to toggle all`,
2992
- `${theme.style.key("i")} to invert selection`,
2993
- `and ${theme.style.key("enter")} to proceed`
2994
- ];
2995
- helpTipTop = ` (Press ${keys.join(", ")})`;
2996
- }
2997
- if (items.length > pageSize && (theme.helpMode === "always" || theme.helpMode === "auto" && firstRender.current)) {
2998
- helpTipBottom = `
2999
- ${theme.style.help("(Use arrow keys to reveal more choices)")}`;
3000
- firstRender.current = false;
3001
- }
3002
- }
3003
- const choiceDescription = description ? `
3004
- ${theme.style.description(description)}` : ``;
3005
- let error = "";
3006
- if (errorMsg) {
3007
- error = `
3008
- ${theme.style.error(errorMsg)}`;
3009
- }
3010
- return `${prefix} ${message}${helpTipTop}
3011
- ${page}${helpTipBottom}${choiceDescription}${error}${import_ansi_escapes2.default.cursorHide}`;
3012
- });
3013
-
3014
2842
  // node_modules/@inquirer/confirm/dist/esm/index.mjs
3015
- var esm_default3 = createPrompt((config, done) => {
2843
+ var esm_default2 = createPrompt((config, done) => {
3016
2844
  const { transformer = (answer) => answer ? "yes" : "no" } = config;
3017
2845
  const [status, setStatus] = useState("pending");
3018
2846
  const [value, setValue] = useState("");
@@ -3044,7 +2872,7 @@ var esm_default3 = createPrompt((config, done) => {
3044
2872
  });
3045
2873
 
3046
2874
  // node_modules/@inquirer/input/dist/esm/index.mjs
3047
- var esm_default4 = createPrompt((config, done) => {
2875
+ var esm_default3 = createPrompt((config, done) => {
3048
2876
  const { required, validate = () => true } = config;
3049
2877
  const theme = makeTheme(config.theme);
3050
2878
  const [status, setStatus] = useState("pending");
@@ -3104,8 +2932,8 @@ var esm_default4 = createPrompt((config, done) => {
3104
2932
  });
3105
2933
 
3106
2934
  // node_modules/@inquirer/password/dist/esm/index.mjs
3107
- var import_ansi_escapes3 = __toESM(require_ansi_escapes(), 1);
3108
- var esm_default5 = createPrompt((config, done) => {
2935
+ var import_ansi_escapes2 = __toESM(require_ansi_escapes(), 1);
2936
+ var esm_default4 = createPrompt((config, done) => {
3109
2937
  const { validate = () => true } = config;
3110
2938
  const theme = makeTheme(config.theme);
3111
2939
  const [status, setStatus] = useState("pending");
@@ -3142,7 +2970,7 @@ var esm_default5 = createPrompt((config, done) => {
3142
2970
  const maskChar = typeof config.mask === "string" ? config.mask : "*";
3143
2971
  formattedValue = maskChar.repeat(value.length);
3144
2972
  } else if (status !== "done") {
3145
- helpTip = `${theme.style.help("[input is masked]")}${import_ansi_escapes3.default.cursorHide}`;
2973
+ helpTip = `${theme.style.help("[input is masked]")}${import_ansi_escapes2.default.cursorHide}`;
3146
2974
  }
3147
2975
  if (status === "done") {
3148
2976
  formattedValue = theme.style.answer(formattedValue);
@@ -3155,20 +2983,20 @@ var esm_default5 = createPrompt((config, done) => {
3155
2983
  });
3156
2984
 
3157
2985
  // node_modules/@inquirer/select/dist/esm/index.mjs
3158
- var import_yoctocolors_cjs4 = __toESM(require_yoctocolors_cjs(), 1);
3159
- var import_ansi_escapes4 = __toESM(require_ansi_escapes(), 1);
2986
+ var import_yoctocolors_cjs3 = __toESM(require_yoctocolors_cjs(), 1);
2987
+ var import_ansi_escapes3 = __toESM(require_ansi_escapes(), 1);
3160
2988
  var selectTheme = {
3161
2989
  icon: { cursor: esm_default.pointer },
3162
2990
  style: {
3163
- disabled: (text) => import_yoctocolors_cjs4.default.dim(`- ${text}`),
3164
- description: (text) => import_yoctocolors_cjs4.default.cyan(text)
2991
+ disabled: (text) => import_yoctocolors_cjs3.default.dim(`- ${text}`),
2992
+ description: (text) => import_yoctocolors_cjs3.default.cyan(text)
3165
2993
  },
3166
2994
  helpMode: "auto"
3167
2995
  };
3168
- function isSelectable2(item) {
2996
+ function isSelectable(item) {
3169
2997
  return !Separator.isSeparator(item) && !item.disabled;
3170
2998
  }
3171
- function normalizeChoices2(choices) {
2999
+ function normalizeChoices(choices) {
3172
3000
  return choices.map((choice) => {
3173
3001
  if (Separator.isSeparator(choice))
3174
3002
  return choice;
@@ -3190,17 +3018,17 @@ function normalizeChoices2(choices) {
3190
3018
  };
3191
3019
  });
3192
3020
  }
3193
- var esm_default6 = createPrompt((config, done) => {
3021
+ var esm_default5 = createPrompt((config, done) => {
3194
3022
  const { loop = true, pageSize = 7 } = config;
3195
3023
  const firstRender = useRef(true);
3196
3024
  const theme = makeTheme(selectTheme, config.theme);
3197
3025
  const prefix = usePrefix({ theme });
3198
3026
  const [status, setStatus] = useState("pending");
3199
3027
  const searchTimeoutRef = useRef();
3200
- const items = useMemo(() => normalizeChoices2(config.choices), [config.choices]);
3028
+ const items = useMemo(() => normalizeChoices(config.choices), [config.choices]);
3201
3029
  const bounds = useMemo(() => {
3202
- const first = items.findIndex(isSelectable2);
3203
- const last = items.findLastIndex(isSelectable2);
3030
+ const first = items.findIndex(isSelectable);
3031
+ const last = items.findLastIndex(isSelectable);
3204
3032
  if (first < 0) {
3205
3033
  throw new ValidationError("[select prompt] No selectable choices. All choices are disabled.");
3206
3034
  }
@@ -3209,7 +3037,7 @@ var esm_default6 = createPrompt((config, done) => {
3209
3037
  const defaultItemIndex = useMemo(() => {
3210
3038
  if (!("default" in config))
3211
3039
  return -1;
3212
- return items.findIndex((item) => isSelectable2(item) && item.value === config.default);
3040
+ return items.findIndex((item) => isSelectable(item) && item.value === config.default);
3213
3041
  }, [config.default, items]);
3214
3042
  const [active, setActive] = useState(defaultItemIndex === -1 ? bounds.first : defaultItemIndex);
3215
3043
  const selectedChoice = items[active];
@@ -3225,14 +3053,14 @@ var esm_default6 = createPrompt((config, done) => {
3225
3053
  let next = active;
3226
3054
  do {
3227
3055
  next = (next + offset + items.length) % items.length;
3228
- } while (!isSelectable2(items[next]));
3056
+ } while (!isSelectable(items[next]));
3229
3057
  setActive(next);
3230
3058
  }
3231
3059
  } else if (isNumberKey(key)) {
3232
3060
  rl.clearLine(0);
3233
3061
  const position = Number(key.name) - 1;
3234
3062
  const item = items[position];
3235
- if (item != null && isSelectable2(item)) {
3063
+ if (item != null && isSelectable(item)) {
3236
3064
  setActive(position);
3237
3065
  }
3238
3066
  } else if (isBackspaceKey(key)) {
@@ -3240,7 +3068,7 @@ var esm_default6 = createPrompt((config, done) => {
3240
3068
  } else {
3241
3069
  const searchTerm = rl.line.toLowerCase();
3242
3070
  const matchIndex = items.findIndex((item) => {
3243
- if (Separator.isSeparator(item) || !isSelectable2(item))
3071
+ if (Separator.isSeparator(item) || !isSelectable(item))
3244
3072
  return false;
3245
3073
  return item.name.toLowerCase().startsWith(searchTerm);
3246
3074
  });
@@ -3291,7 +3119,7 @@ ${theme.style.help("(Use arrow keys to reveal more choices)")}`;
3291
3119
  const choiceDescription = selectedChoice.description ? `
3292
3120
  ${theme.style.description(selectedChoice.description)}` : ``;
3293
3121
  return `${[prefix, message, helpTipTop].filter(Boolean).join(" ")}
3294
- ${page}${helpTipBottom}${choiceDescription}${import_ansi_escapes4.default.cursorHide}`;
3122
+ ${page}${helpTipBottom}${choiceDescription}${import_ansi_escapes3.default.cursorHide}`;
3295
3123
  });
3296
3124
 
3297
3125
  // src/index.ts
@@ -5471,8 +5299,8 @@ var run_mcp_install_commands_default = defineStep({
5471
5299
  }
5472
5300
  });
5473
5301
  function isClaudeCliAvailable() {
5474
- const check2 = (0, import_child_process3.spawnSync)("claude --version", { shell: true, stdio: "ignore" });
5475
- return check2.status === 0;
5302
+ const check = (0, import_child_process3.spawnSync)("claude --version", { shell: true, stdio: "ignore" });
5303
+ return check.status === 0;
5476
5304
  }
5477
5305
 
5478
5306
  // src/steps/setup/build-code-index.ts
@@ -5737,7 +5565,7 @@ async function uninstall() {
5737
5565
  console.clear();
5738
5566
  console.log("One-Shot Setup Uninstaller\n");
5739
5567
  try {
5740
- const projectInput = await esm_default4({
5568
+ const projectInput = await esm_default3({
5741
5569
  message: "Project directory to uninstall from:",
5742
5570
  default: (0, import_path16.resolve)(process.cwd())
5743
5571
  });
@@ -5763,7 +5591,7 @@ async function uninstall() {
5763
5591
  console.log(dim(" This file was likely written by an older installer version that"));
5764
5592
  console.log(dim(" did not yet emit a journal. Manual cleanup is required."));
5765
5593
  console.log("");
5766
- const proceed2 = await esm_default3({
5594
+ const proceed2 = await esm_default2({
5767
5595
  message: "Delete the state file anyway?",
5768
5596
  default: false
5769
5597
  });
@@ -5776,7 +5604,7 @@ async function uninstall() {
5776
5604
  }
5777
5605
  const summary = readSummary(statePath);
5778
5606
  printPreview(projectPath, summary, entries.length);
5779
- const proceed = await esm_default3({
5607
+ const proceed = await esm_default2({
5780
5608
  message: "Proceed with uninstall?",
5781
5609
  default: false
5782
5610
  });
@@ -5985,28 +5813,15 @@ async function main() {
5985
5813
  }
5986
5814
  }
5987
5815
  async function collectInputs(options, releaseVersion, factoryAvailable = false, abapHooksAvailable = false) {
5988
- const selectedIds = await esm_default2({
5989
- message: "Technology:",
5990
- instructions: " Space to select \xB7 Enter to confirm",
5991
- choices: [
5992
- ...options.technologies.map((p) => ({
5993
- name: p.name.replace(/ Developer$/, ""),
5994
- value: p.id
5995
- })),
5996
- { name: "None", value: "none" }
5997
- ],
5998
- required: true,
5999
- loop: false
6000
- });
6001
- const selectedTechnologies = options.technologies.filter((p) => selectedIds.includes(p.id));
6002
- const agent = await esm_default6({
5816
+ const selectedTechnologies = options.technologies;
5817
+ const agent = await esm_default5({
6003
5818
  message: "AI coding tool:",
6004
5819
  choices: options.agents,
6005
5820
  loop: false
6006
5821
  });
6007
5822
  let agentTeams = false;
6008
5823
  if (factoryAvailable && agent === "claude-code") {
6009
- const brainstormer = await esm_default6({
5824
+ const brainstormer = await esm_default5({
6010
5825
  message: "Brainstorming mode:",
6011
5826
  default: "solo",
6012
5827
  choices: [
@@ -6020,7 +5835,7 @@ async function collectInputs(options, releaseVersion, factoryAvailable = false,
6020
5835
  const mcpConfig = buildMCPConfiguration(selectedTechnologies, options.baseMcpServers, options.mcpServers);
6021
5836
  let azureDevOpsOrg = "";
6022
5837
  if (mcpConfig["azure-devops"]) {
6023
- const org = await esm_default4({
5838
+ const org = await esm_default3({
6024
5839
  message: "Azure DevOps org (leave empty to skip):"
6025
5840
  });
6026
5841
  azureDevOpsOrg = org.trim();
@@ -6036,13 +5851,13 @@ async function collectInputs(options, releaseVersion, factoryAvailable = false,
6036
5851
  }
6037
5852
  }
6038
5853
  if (mcpConfig["sap_mcp_server"]) {
6039
- const sapUser = (await esm_default4({
5854
+ const sapUser = (await esm_default3({
6040
5855
  message: "SAP MCP (ABAP F4P) username (leave empty to skip):"
6041
5856
  })).trim();
6042
5857
  if (sapUser === "") {
6043
5858
  delete mcpConfig["sap_mcp_server"];
6044
5859
  } else {
6045
- const sapPassword = await esm_default5({
5860
+ const sapPassword = await esm_default4({
6046
5861
  message: "SAP MCP (ABAP F4P) password:",
6047
5862
  mask: "*"
6048
5863
  });
@@ -6056,7 +5871,7 @@ async function collectInputs(options, releaseVersion, factoryAvailable = false,
6056
5871
  }
6057
5872
  }
6058
5873
  }
6059
- const projectInput = await esm_default4({
5874
+ const projectInput = await esm_default3({
6060
5875
  message: "Project directory:",
6061
5876
  default: (0, import_path17.resolve)(process.cwd())
6062
5877
  });
@@ -6076,7 +5891,7 @@ async function collectInputs(options, releaseVersion, factoryAvailable = false,
6076
5891
  };
6077
5892
  }
6078
5893
  async function previewAndConfirm(config, options) {
6079
- const technologyNames = config.technologies.length > 0 ? config.technologies.map((p) => p.name.replace(/ Developer$/, "")).join(", ") : "None";
5894
+ const technologyNames = config.technologies.map((p) => p.name.replace(/ Developer$/, "")).join(", ");
6080
5895
  const agentDisplay = options.agents.find((a) => a.value === config.agent)?.name ?? config.agent;
6081
5896
  const target = getAgentTarget(config.agent);
6082
5897
  const instructionFile = target.instructions;
@@ -6131,7 +5946,7 @@ async function previewAndConfirm(config, options) {
6131
5946
  }
6132
5947
  }
6133
5948
  console.log("\n" + "\u2500".repeat(48));
6134
- return esm_default3({ message: "Proceed?", default: true });
5949
+ return esm_default2({ message: "Proceed?", default: true });
6135
5950
  }
6136
5951
  function printSummary2(result, config) {
6137
5952
  const failed = result.entries.filter((e) => e.result.status === "failed");
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "dlw-machine-setup",
3
- "version": "0.11.0",
3
+ "version": "0.11.1",
4
4
  "description": "One-shot installer for The Machine toolchain",
5
5
  "bin": {
6
6
  "dlw-machine-setup": "bin/installer.js"