stratagem-x7 0.3.12 → 0.3.13
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/dist/cli.mjs +53 -15
- package/package.json +1 -1
package/dist/cli.mjs
CHANGED
|
@@ -121780,7 +121780,11 @@ function parseKey(keypress) {
|
|
|
121780
121780
|
processedAsSpecialSequence = true;
|
|
121781
121781
|
}
|
|
121782
121782
|
if (!processedAsSpecialSequence && keypress.name && nonAlphanumericKeys.includes(keypress.name)) {
|
|
121783
|
-
|
|
121783
|
+
if (/^f\d+$/.test(keypress.name)) {
|
|
121784
|
+
input = keypress.name;
|
|
121785
|
+
} else {
|
|
121786
|
+
input = "";
|
|
121787
|
+
}
|
|
121784
121788
|
}
|
|
121785
121789
|
if (input.length === 1 && typeof input[0] === "string" && input[0] >= "A" && input[0] <= "Z") {
|
|
121786
121790
|
key.shift = true;
|
|
@@ -250552,6 +250556,7 @@ var init_defaultBindings = __esm(() => {
|
|
|
250552
250556
|
"ctrl+g": "chat:externalEditor",
|
|
250553
250557
|
"ctrl+s": "chat:stash",
|
|
250554
250558
|
[IMAGE_PASTE_KEY]: "chat:imagePaste",
|
|
250559
|
+
"ctrl+p": "chat:shellMode",
|
|
250555
250560
|
...{ "shift+up": "chat:messageActions" },
|
|
250556
250561
|
...{}
|
|
250557
250562
|
}
|
|
@@ -251555,6 +251560,8 @@ function getKeyName(input, key) {
|
|
|
251555
251560
|
return "home";
|
|
251556
251561
|
if (key.end)
|
|
251557
251562
|
return "end";
|
|
251563
|
+
if (key.fn && /^f\d+$/.test(input))
|
|
251564
|
+
return input;
|
|
251558
251565
|
if (input.length === 1)
|
|
251559
251566
|
return input.toLowerCase();
|
|
251560
251567
|
return null;
|
|
@@ -382885,7 +382892,7 @@ function getAnthropicEnvMetadata() {
|
|
|
382885
382892
|
function getBuildAgeMinutes() {
|
|
382886
382893
|
if (false)
|
|
382887
382894
|
;
|
|
382888
|
-
const buildTime = new Date("2026-04-
|
|
382895
|
+
const buildTime = new Date("2026-04-25T05:38:00.638Z").getTime();
|
|
382889
382896
|
if (isNaN(buildTime))
|
|
382890
382897
|
return;
|
|
382891
382898
|
return Math.floor((Date.now() - buildTime) / 60000);
|
|
@@ -410062,7 +410069,7 @@ function buildPrimarySection() {
|
|
|
410062
410069
|
}, undefined, false, undefined, this);
|
|
410063
410070
|
return [{
|
|
410064
410071
|
label: "Version",
|
|
410065
|
-
value: "0.3.
|
|
410072
|
+
value: "0.3.13"
|
|
410066
410073
|
}, {
|
|
410067
410074
|
label: "Session name",
|
|
410068
410075
|
value: nameValue
|
|
@@ -449688,7 +449695,7 @@ function getStartupLines(termWidth) {
|
|
|
449688
449695
|
const sLen = ` ● ${sL} buffer ready — /help for breach controls`.length;
|
|
449689
449696
|
out.push(centerAnsiLine(boxRow(sRow, W2, sLen), tw));
|
|
449690
449697
|
out.push(centerAnsiLine(`${rgb3(...BORDER)}└${"─".repeat(W2 - 2)}┘${RESET2}`, tw));
|
|
449691
|
-
out.push(centerAnsiLine(`${rgb3(...DIMCOL)}STRATAGEM X7${RESET2} ${rgb3(...ACCENT)}v${"0.3.
|
|
449698
|
+
out.push(centerAnsiLine(`${rgb3(...DIMCOL)}STRATAGEM X7${RESET2} ${rgb3(...ACCENT)}v${"0.3.13"}${RESET2} ${rgb3(...CYAN)}// breach link stable${RESET2}`, tw));
|
|
449692
449699
|
out.push("");
|
|
449693
449700
|
return out;
|
|
449694
449701
|
}
|
|
@@ -478237,7 +478244,7 @@ var init_bridge_kick = __esm(() => {
|
|
|
478237
478244
|
var call60 = async () => {
|
|
478238
478245
|
return {
|
|
478239
478246
|
type: "text",
|
|
478240
|
-
value: `${"99.0.0"} (built ${"2026-04-
|
|
478247
|
+
value: `${"99.0.0"} (built ${"2026-04-25T05:38:00.638Z"})`
|
|
478241
478248
|
};
|
|
478242
478249
|
}, version2, version_default;
|
|
478243
478250
|
var init_version = __esm(() => {
|
|
@@ -530720,14 +530727,24 @@ function ModeIndicator({
|
|
|
530720
530727
|
}, [voiceEnabled, voiceHintUnderCap]);
|
|
530721
530728
|
const isKillAgentsConfirmShowing = useAppState((s_7) => s_7.notifications.current?.key === "kill-agents-confirm");
|
|
530722
530729
|
const hasTeams = isAgentSwarmsEnabled() && !isInProcessEnabled() && teamContext !== undefined && count2(Object.values(teamContext.teammates), (t_0) => t_0.name !== "team-lead") > 0;
|
|
530730
|
+
const currentMode = toolPermissionContext?.mode;
|
|
530731
|
+
const autonomyMode = useAppState((s_8) => s_8.settings.autonomyMode ?? "off");
|
|
530723
530732
|
if (mode === "bash") {
|
|
530724
530733
|
return /* @__PURE__ */ jsx_dev_runtime429.jsxDEV(ThemedText, {
|
|
530725
530734
|
color: "bashBorder",
|
|
530726
|
-
children:
|
|
530727
|
-
|
|
530735
|
+
children: [
|
|
530736
|
+
/* @__PURE__ */ jsx_dev_runtime429.jsxDEV(ThemedText, {
|
|
530737
|
+
bold: true,
|
|
530738
|
+
children: "SHELL MODE"
|
|
530739
|
+
}, undefined, false, undefined, this),
|
|
530740
|
+
" ",
|
|
530741
|
+
/* @__PURE__ */ jsx_dev_runtime429.jsxDEV(ThemedText, {
|
|
530742
|
+
dimColor: true,
|
|
530743
|
+
children: "[Ctrl+P to exit]"
|
|
530744
|
+
}, undefined, false, undefined, this)
|
|
530745
|
+
]
|
|
530746
|
+
}, undefined, true, undefined, this);
|
|
530728
530747
|
}
|
|
530729
|
-
const currentMode = toolPermissionContext?.mode;
|
|
530730
|
-
const autonomyMode = useAppState((s_8) => s_8.settings.autonomyMode ?? "off");
|
|
530731
530748
|
const hasActiveMode = !isDefaultMode(currentMode);
|
|
530732
530749
|
const viewedTask = viewingAgentTaskId ? tasks2[viewingAgentTaskId] : undefined;
|
|
530733
530750
|
const isViewingTeammate = viewSelectionMode === "viewing-agent" && viewedTask?.type === "in_process_teammate";
|
|
@@ -531313,7 +531330,7 @@ function PromptInputModeIndicator(t0) {
|
|
|
531313
531330
|
}, undefined, false, undefined, this) : mode === "bash" ? /* @__PURE__ */ jsx_dev_runtime431.jsxDEV(ThemedText, {
|
|
531314
531331
|
color: "bashBorder",
|
|
531315
531332
|
dimColor: isLoading,
|
|
531316
|
-
children: "
|
|
531333
|
+
children: "$ "
|
|
531317
531334
|
}, undefined, false, undefined, this) : /* @__PURE__ */ jsx_dev_runtime431.jsxDEV(PromptChar, {
|
|
531318
531335
|
isLoading,
|
|
531319
531336
|
themeColor: isAgentSwarmsEnabled() ? teammateColor : undefined
|
|
@@ -531881,6 +531898,7 @@ function PromptInput({
|
|
|
531881
531898
|
onInputChange,
|
|
531882
531899
|
mode,
|
|
531883
531900
|
onModeChange,
|
|
531901
|
+
onToggleShellMode,
|
|
531884
531902
|
stashedPrompt,
|
|
531885
531903
|
setStashedPrompt,
|
|
531886
531904
|
submitCount,
|
|
@@ -533135,6 +533153,21 @@ function PromptInput({
|
|
|
533135
533153
|
context: "Footer",
|
|
533136
533154
|
isActive: !!footerItemSelected && !isModalOverlayActive
|
|
533137
533155
|
});
|
|
533156
|
+
useKeybinding("chat:shellMode", () => {
|
|
533157
|
+
const nextMode = mode === "bash" ? "prompt" : "bash";
|
|
533158
|
+
onModeChange(nextMode);
|
|
533159
|
+
if (onToggleShellMode)
|
|
533160
|
+
onToggleShellMode();
|
|
533161
|
+
addNotification({
|
|
533162
|
+
key: "shell-mode-toggle",
|
|
533163
|
+
text: nextMode === "bash" ? "⚡ Shell Mode — commands go directly to OS" : "\uD83E\uDD16 Agent Mode — input goes to LLM",
|
|
533164
|
+
priority: "immediate",
|
|
533165
|
+
timeoutMs: 2000
|
|
533166
|
+
});
|
|
533167
|
+
}, {
|
|
533168
|
+
context: "Chat",
|
|
533169
|
+
isActive: !isModalOverlayActive
|
|
533170
|
+
});
|
|
533138
533171
|
use_input_default((char, key) => {
|
|
533139
533172
|
if (showTeamsDialog || showQuickOpen || showGlobalSearch || showHistoryPicker) {
|
|
533140
533173
|
return;
|
|
@@ -549493,6 +549526,9 @@ function REPL({
|
|
|
549493
549526
|
return () => clearTimeout(timer);
|
|
549494
549527
|
}, [inputValue]);
|
|
549495
549528
|
const [inputMode, setInputMode] = import_react316.useState("prompt");
|
|
549529
|
+
const [shellMode, setShellMode] = import_react316.useState(false);
|
|
549530
|
+
const shellModeRef = import_react316.useRef(shellMode);
|
|
549531
|
+
shellModeRef.current = shellMode;
|
|
549496
549532
|
const [stashedPrompt, setStashedPrompt] = import_react316.useState();
|
|
549497
549533
|
const handleRemoteInit = import_react316.useCallback((remoteSlashCommands) => {
|
|
549498
549534
|
const remoteCommandSet = new Set(remoteSlashCommands);
|
|
@@ -550742,7 +550778,8 @@ Error: sandbox required but unavailable: ${reason}
|
|
|
550742
550778
|
setPastedContents({});
|
|
550743
550779
|
}
|
|
550744
550780
|
if (submitsNow) {
|
|
550745
|
-
|
|
550781
|
+
if (!shellModeRef.current)
|
|
550782
|
+
setInputMode("prompt");
|
|
550746
550783
|
setIDESelection(undefined);
|
|
550747
550784
|
setSubmitCount((_) => _ + 1);
|
|
550748
550785
|
helpers.clearBuffer();
|
|
@@ -552118,6 +552155,7 @@ Note: ctrl + z now suspends STRATAGEM X7, ctrl + _ undoes input.
|
|
|
552118
552155
|
setIsSearchingHistory,
|
|
552119
552156
|
helpOpen: isHelpOpen,
|
|
552120
552157
|
setHelpOpen: setIsHelpOpen,
|
|
552158
|
+
onToggleShellMode: () => setShellMode((prev) => !prev),
|
|
552121
552159
|
insertTextRef: undefined,
|
|
552122
552160
|
voiceInterimRange: voice.interimRange
|
|
552123
552161
|
}, undefined, false, undefined, this),
|
|
@@ -553618,7 +553656,7 @@ function WelcomeV2() {
|
|
|
553618
553656
|
dimColor: true,
|
|
553619
553657
|
children: [
|
|
553620
553658
|
"v",
|
|
553621
|
-
"0.3.
|
|
553659
|
+
"0.3.13",
|
|
553622
553660
|
" "
|
|
553623
553661
|
]
|
|
553624
553662
|
}, undefined, true, undefined, this)
|
|
@@ -573635,7 +573673,7 @@ Usage: stx7 --remote "your task description"`, () => gracefulShutdown(1));
|
|
|
573635
573673
|
pendingHookMessages
|
|
573636
573674
|
}, renderAndRun);
|
|
573637
573675
|
}
|
|
573638
|
-
}).version("0.3.
|
|
573676
|
+
}).version("0.3.13 (STRATAGEM X7)", "-v, --version", "Output the version number");
|
|
573639
573677
|
program2.option("-w, --worktree [name]", "Create a new git worktree for this session (optionally specify a name)");
|
|
573640
573678
|
program2.option("--tmux", "Create a tmux session for the worktree (requires --worktree). Uses iTerm2 native panes when available; use --tmux=classic for traditional tmux.");
|
|
573641
573679
|
if (canUserConfigureAdvisor()) {
|
|
@@ -574163,7 +574201,7 @@ if (false) {}
|
|
|
574163
574201
|
async function main2() {
|
|
574164
574202
|
const args = process.argv.slice(2);
|
|
574165
574203
|
if (args.length === 1 && (args[0] === "--version" || args[0] === "-v" || args[0] === "-V")) {
|
|
574166
|
-
console.log(`${"0.3.
|
|
574204
|
+
console.log(`${"0.3.13"} (STRATAGEM X7)`);
|
|
574167
574205
|
return;
|
|
574168
574206
|
}
|
|
574169
574207
|
if (args.includes("--provider")) {
|
|
@@ -574285,4 +574323,4 @@ async function main2() {
|
|
|
574285
574323
|
}
|
|
574286
574324
|
main2();
|
|
574287
574325
|
|
|
574288
|
-
//# debugId=
|
|
574326
|
+
//# debugId=4C7542699EEA5FD964756E2164756E21
|