feat: add pure ssh2 remote operations

This commit is contained in:
云服务部-叶林立
2026-08-21 19:51:43 +08:00
parent d3bf562189
commit 0ac50eb581
62 changed files with 3701 additions and 47 deletions
@@ -127,6 +127,25 @@ describe("unifiedConfigSchema", () => {
expect(result.success).toBe(true);
});
it("accepts ask as a shell alias decision floor", () => {
const result = unifiedConfigSchema.safeParse({
shellTools: {
ssh_bash: { commandArgument: "command", decisionFloor: "ask" },
},
});
expect(result.success).toBe(true);
});
it.each(["allow", "deny", "invalid"] as const)(
"rejects %s as a shell alias decision floor",
(decisionFloor) => {
const result = unifiedConfigSchema.safeParse({
shellTools: { ssh_bash: { commandArgument: "command", decisionFloor } },
});
expect(result.success).toBe(false);
},
);
it("rejects an alias missing commandArgument", () => {
const result = unifiedConfigSchema.safeParse({
shellTools: { exec_command: { workdirArgument: "workdir" } },