@duckmind/dm-darwin-x64 0.36.5 → 0.36.9
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/dm +0 -0
- package/extensions/.dm-extensions.json +1 -1
- package/extensions/dm-9router-ext/package.json +1 -1
- package/extensions/dm-9router-ext/src/index.ts +1 -1
- package/extensions/dm-ask-user/README.md +3 -3
- package/extensions/dm-ask-user/index.ts +2 -2
- package/extensions/dm-ask-user/package.json +4 -4
- package/extensions/dm-cli-anything/package.json +1 -1
- package/extensions/dm-context/package.json +1 -1
- package/extensions/dm-context/src/context.ts +2 -2
- package/extensions/dm-context/src/index.ts +3 -3
- package/extensions/dm-cua/package.json +2 -2
- package/extensions/dm-goal/package.json +6 -6
- package/extensions/dm-goal/src/commands.ts +1 -1
- package/extensions/dm-goal/src/index.ts +1 -1
- package/extensions/dm-goal/src/tools.ts +2 -2
- package/extensions/dm-goal/test/index.test.ts +1 -1
- package/extensions/dm-image2/index.js +1 -1
- package/extensions/dm-image2/package.json +2 -2
- package/extensions/dm-image2/src/image-lib.mjs +1 -1
- package/extensions/dm-last30days/package.json +1 -1
- package/extensions/dm-subagents/CHANGELOG.md +2 -2
- package/extensions/dm-subagents/node_modules/.package-lock.json +9 -0
- package/extensions/dm-subagents/package-lock.json +136 -2935
- package/extensions/dm-subagents/package.json +6 -6
- package/extensions/dm-subagents/src/agent-manager.ts +2 -2
- package/extensions/dm-subagents/src/agent-record.ts +1 -1
- package/extensions/dm-subagents/src/agent-runner.ts +2 -2
- package/extensions/dm-subagents/src/context.ts +1 -1
- package/extensions/dm-subagents/src/custom-agents.ts +1 -1
- package/extensions/dm-subagents/src/execution-state.ts +1 -1
- package/extensions/dm-subagents/src/index.ts +2 -2
- package/extensions/dm-subagents/src/parent-snapshot.ts +1 -1
- package/extensions/dm-subagents/src/renderer.ts +1 -1
- package/extensions/dm-subagents/src/service-adapter.ts +1 -1
- package/extensions/dm-subagents/src/settings.ts +1 -1
- package/extensions/dm-subagents/src/skill-loader.ts +1 -1
- package/extensions/dm-subagents/src/tools/agent-tool.ts +2 -2
- package/extensions/dm-subagents/src/tools/foreground-runner.ts +1 -1
- package/extensions/dm-subagents/src/tools/get-result-tool.ts +1 -1
- package/extensions/dm-subagents/src/tools/spawn-config.ts +1 -1
- package/extensions/dm-subagents/src/tools/steer-tool.ts +1 -1
- package/extensions/dm-subagents/src/types.ts +1 -1
- package/extensions/dm-subagents/src/ui/agent-config-editor.ts +1 -1
- package/extensions/dm-subagents/src/ui/agent-creation-wizard.ts +1 -1
- package/extensions/dm-subagents/src/ui/agent-menu.ts +1 -1
- package/extensions/dm-subagents/src/ui/conversation-viewer.ts +2 -2
- package/extensions/dm-subagents/src/ui/widget-renderer.ts +1 -1
- package/extensions/dm-subagents/test/agent-runner.test.ts +1 -1
- package/extensions/dm-subagents/test/conversation-viewer.test.ts +6 -6
- package/extensions/dm-subagents/test/custom-agents.test.ts +6 -6
- package/extensions/dm-subagents/test/helpers/mock-session.ts +1 -1
- package/extensions/dm-subagents/test/helpers/stub-ctx.ts +1 -1
- package/extensions/dm-subagents/test/parent-snapshot.test.ts +1 -1
- package/extensions/dm-subagents/test/settings.test.ts +5 -5
- package/extensions/dm-subagents/test/skill-loader.test.ts +5 -5
- package/extensions/dm-subagents/test/unit/subagent-contract.test.ts +5 -3
- package/extensions/dm-tasks/node_modules/.package-lock.json +3 -3
- package/extensions/dm-tasks/node_modules/typebox/build/schema/types/dependencies.mjs +1 -1
- package/extensions/dm-tasks/node_modules/typebox/build/type/action/_add_immutable.d.mts +11 -0
- package/extensions/dm-tasks/node_modules/typebox/build/type/action/_add_immutable.mjs +11 -0
- package/extensions/dm-tasks/node_modules/typebox/build/type/action/_add_optional.d.mts +11 -0
- package/extensions/dm-tasks/node_modules/typebox/build/type/action/_add_optional.mjs +11 -0
- package/extensions/dm-tasks/node_modules/typebox/build/type/action/_add_readonly.d.mts +11 -0
- package/extensions/dm-tasks/node_modules/typebox/build/type/action/_add_readonly.mjs +11 -0
- package/extensions/dm-tasks/node_modules/typebox/build/type/action/_remove_immutable.d.mts +11 -0
- package/extensions/dm-tasks/node_modules/typebox/build/type/action/_remove_immutable.mjs +11 -0
- package/extensions/dm-tasks/node_modules/typebox/build/type/action/_remove_optional.d.mts +11 -0
- package/extensions/dm-tasks/node_modules/typebox/build/type/action/_remove_optional.mjs +11 -0
- package/extensions/dm-tasks/node_modules/typebox/build/type/action/_remove_readonly.d.mts +11 -0
- package/extensions/dm-tasks/node_modules/typebox/build/type/action/_remove_readonly.mjs +11 -0
- package/extensions/dm-tasks/node_modules/typebox/build/type/action/conditional.d.mts +2 -3
- package/extensions/dm-tasks/node_modules/typebox/build/type/action/conditional.mjs +2 -1
- package/extensions/dm-tasks/node_modules/typebox/build/type/action/index.d.mts +6 -2
- package/extensions/dm-tasks/node_modules/typebox/build/type/action/index.mjs +6 -2
- package/extensions/dm-tasks/node_modules/typebox/build/type/action/mapped.d.mts +2 -3
- package/extensions/dm-tasks/node_modules/typebox/build/type/action/mapped.mjs +2 -1
- package/extensions/dm-tasks/node_modules/typebox/build/type/action/module.d.mts +8 -7
- package/extensions/dm-tasks/node_modules/typebox/build/type/action/module.mjs +7 -6
- package/extensions/dm-tasks/node_modules/typebox/build/type/engine/call/instantiate.d.mts +1 -3
- package/extensions/dm-tasks/node_modules/typebox/build/type/engine/call/instantiate.mjs +3 -2
- package/extensions/dm-tasks/node_modules/typebox/build/type/engine/constructor_parameters/instantiate.d.mts +3 -4
- package/extensions/dm-tasks/node_modules/typebox/build/type/engine/constructor_parameters/instantiate.mjs +2 -1
- package/extensions/dm-tasks/node_modules/typebox/build/type/engine/cyclic/instantiate.d.mts +2 -5
- package/extensions/dm-tasks/node_modules/typebox/build/type/engine/cyclic/instantiate.mjs +3 -2
- package/extensions/dm-tasks/node_modules/typebox/build/type/engine/evaluate/composite.d.mts +10 -6
- package/extensions/dm-tasks/node_modules/typebox/build/type/engine/evaluate/composite.mjs +10 -6
- package/extensions/dm-tasks/node_modules/typebox/build/type/engine/immutable/instantiate_add.d.mts +10 -0
- package/extensions/dm-tasks/node_modules/typebox/build/type/engine/immutable/instantiate_add.mjs +14 -0
- package/extensions/dm-tasks/node_modules/typebox/build/type/engine/immutable/instantiate_remove.d.mts +10 -0
- package/extensions/dm-tasks/node_modules/typebox/build/type/engine/immutable/instantiate_remove.mjs +14 -0
- package/extensions/dm-tasks/node_modules/typebox/build/type/engine/instantiate.d.mts +38 -21
- package/extensions/dm-tasks/node_modules/typebox/build/type/engine/instantiate.mjs +65 -62
- package/extensions/dm-tasks/node_modules/typebox/build/type/engine/interface/instantiate.d.mts +3 -6
- package/extensions/dm-tasks/node_modules/typebox/build/type/engine/module/instantiate.d.mts +7 -9
- package/extensions/dm-tasks/node_modules/typebox/build/type/engine/module/instantiate.mjs +17 -15
- package/extensions/dm-tasks/node_modules/typebox/build/type/engine/optional/instantiate_add.d.mts +10 -0
- package/extensions/dm-tasks/node_modules/typebox/build/type/engine/optional/instantiate_add.mjs +14 -0
- package/extensions/dm-tasks/node_modules/typebox/build/type/engine/optional/instantiate_remove.d.mts +10 -0
- package/extensions/dm-tasks/node_modules/typebox/build/type/engine/optional/instantiate_remove.mjs +14 -0
- package/extensions/dm-tasks/node_modules/typebox/build/type/engine/parameters/instantiate.d.mts +3 -4
- package/extensions/dm-tasks/node_modules/typebox/build/type/engine/parameters/instantiate.mjs +2 -1
- package/extensions/dm-tasks/node_modules/typebox/build/type/engine/partial/from_object.d.mts +2 -2
- package/extensions/dm-tasks/node_modules/typebox/build/type/engine/partial/from_object.mjs +2 -2
- package/extensions/dm-tasks/node_modules/typebox/build/type/engine/readonly/instantiate_add.d.mts +10 -0
- package/extensions/dm-tasks/node_modules/typebox/build/type/engine/readonly/instantiate_add.mjs +14 -0
- package/extensions/dm-tasks/node_modules/typebox/build/type/engine/readonly/instantiate_remove.d.mts +10 -0
- package/extensions/dm-tasks/node_modules/typebox/build/type/engine/readonly/instantiate_remove.mjs +14 -0
- package/extensions/dm-tasks/node_modules/typebox/build/type/engine/readonly_object/from_array.d.mts +2 -2
- package/extensions/dm-tasks/node_modules/typebox/build/type/engine/readonly_object/from_array.mjs +2 -2
- package/extensions/dm-tasks/node_modules/typebox/build/type/engine/readonly_object/from_object.d.mts +2 -2
- package/extensions/dm-tasks/node_modules/typebox/build/type/engine/readonly_object/from_object.mjs +2 -2
- package/extensions/dm-tasks/node_modules/typebox/build/type/engine/readonly_object/from_tuple.d.mts +2 -2
- package/extensions/dm-tasks/node_modules/typebox/build/type/engine/readonly_object/from_tuple.mjs +2 -2
- package/extensions/dm-tasks/node_modules/typebox/build/type/engine/ref/instantiate.d.mts +3 -3
- package/extensions/dm-tasks/node_modules/typebox/build/type/engine/ref/instantiate.mjs +6 -6
- package/extensions/dm-tasks/node_modules/typebox/build/type/engine/required/from_object.d.mts +2 -2
- package/extensions/dm-tasks/node_modules/typebox/build/type/engine/required/from_object.mjs +2 -2
- package/extensions/dm-tasks/node_modules/typebox/build/type/engine/template_literal/is_pattern.mjs +1 -0
- package/extensions/dm-tasks/node_modules/typebox/build/type/extends/tuple.d.mts +3 -6
- package/extensions/dm-tasks/node_modules/typebox/build/type/extends/tuple.mjs +3 -2
- package/extensions/dm-tasks/node_modules/typebox/build/type/script/mapping.d.mts +68 -64
- package/extensions/dm-tasks/node_modules/typebox/build/type/script/mapping.mjs +64 -58
- package/extensions/dm-tasks/node_modules/typebox/build/type/script/parser.d.mts +29 -25
- package/extensions/dm-tasks/node_modules/typebox/build/type/script/parser.mjs +15 -13
- package/extensions/dm-tasks/node_modules/typebox/build/type/script/script.d.mts +3 -4
- package/extensions/dm-tasks/node_modules/typebox/build/type/script/script.mjs +3 -2
- package/extensions/dm-tasks/node_modules/typebox/build/type/types/_immutable.d.mts +2 -9
- package/extensions/dm-tasks/node_modules/typebox/build/type/types/_immutable.mjs +2 -10
- package/extensions/dm-tasks/node_modules/typebox/build/type/types/_optional.d.mts +2 -9
- package/extensions/dm-tasks/node_modules/typebox/build/type/types/_optional.mjs +2 -11
- package/extensions/dm-tasks/node_modules/typebox/build/type/types/_readonly.d.mts +2 -9
- package/extensions/dm-tasks/node_modules/typebox/build/type/types/_readonly.mjs +2 -10
- package/extensions/dm-tasks/node_modules/typebox/build/type/types/call.d.mts +3 -3
- package/extensions/dm-tasks/node_modules/typebox/build/type/types/call.mjs +3 -2
- package/extensions/dm-tasks/node_modules/typebox/build/type/types/deferred.d.mts +1 -0
- package/extensions/dm-tasks/node_modules/typebox/build/type/types/deferred.mjs +1 -1
- package/extensions/dm-tasks/node_modules/typebox/package.json +1 -1
- package/extensions/dm-tasks/package-lock.json +3 -3
- package/extensions/dm-tasks/src/index.ts +1 -1
- package/extensions/dm-tasks/src/ui/settings-menu.ts +2 -2
- package/extensions/dm-tasks/src/ui/task-widget.ts +1 -1
- package/extensions/dm-ultradex/AGENTS.md +2 -2
- package/extensions/dm-ultradex/account-manager.test.ts +1 -1
- package/extensions/dm-ultradex/account-manager.ts +1 -1
- package/extensions/dm-ultradex/auth.ts +1 -1
- package/extensions/dm-ultradex/browser.ts +1 -1
- package/extensions/dm-ultradex/commands.ts +4 -4
- package/extensions/dm-ultradex/extension.ts +2 -2
- package/extensions/dm-ultradex/index.test.ts +5 -3
- package/extensions/dm-ultradex/node_modules/.package-lock.json +9 -0
- package/extensions/dm-ultradex/package-lock.json +130 -2526
- package/extensions/dm-ultradex/package.json +7 -7
- package/extensions/dm-ultradex/provider.ts +2 -2
- package/extensions/dm-ultradex/refresh-race.test.ts +2 -2
- package/extensions/dm-ultradex/status.ts +4 -4
- package/extensions/dm-ultradex/stream-wrapper.ts +1 -1
- package/extensions/dm-usage/index.ts +3 -3
- package/extensions/dm-usage/package.json +4 -4
- package/extensions/greedysearch-dm/index.ts +1 -1
- package/extensions/greedysearch-dm/package-lock.json +2 -2
- package/extensions/greedysearch-dm/package.json +2 -2
- package/extensions/greedysearch-dm/src/tools/greedy-search-handler.ts +2 -2
- package/package.json +1 -1
- package/extensions/dm-tasks/node_modules/typebox/build/type/action/_optional.d.mts +0 -19
- package/extensions/dm-tasks/node_modules/typebox/build/type/action/_optional.mjs +0 -40
- package/extensions/dm-tasks/node_modules/typebox/build/type/action/_readonly.d.mts +0 -19
- package/extensions/dm-tasks/node_modules/typebox/build/type/action/_readonly.mjs +0 -40
|
@@ -51,9 +51,9 @@
|
|
|
51
51
|
"@sinclair/typebox": "^0.34.49"
|
|
52
52
|
},
|
|
53
53
|
"peerDependencies": {
|
|
54
|
-
"@
|
|
55
|
-
"@
|
|
56
|
-
"@
|
|
54
|
+
"@earendil-works/pi-ai": ">=0.72.1",
|
|
55
|
+
"@earendil-works/pi-coding-agent": ">=0.72.1",
|
|
56
|
+
"@earendil-works/pi-tui": ">=0.72.1"
|
|
57
57
|
},
|
|
58
58
|
"devDependencies": {
|
|
59
59
|
"@biomejs/biome": "^2.4.14",
|
|
@@ -61,8 +61,8 @@
|
|
|
61
61
|
"rumdl": "^0.1.93",
|
|
62
62
|
"typescript": "^6.0.0",
|
|
63
63
|
"vitest": "^4.0.18",
|
|
64
|
-
"@
|
|
65
|
-
"@
|
|
66
|
-
"@
|
|
64
|
+
"@earendil-works/pi-ai": "file:../../pi-mono/packages/ai",
|
|
65
|
+
"@earendil-works/pi-coding-agent": "file:../../pi-mono/packages/coding-agent",
|
|
66
|
+
"@earendil-works/pi-tui": "file:../../pi-mono/packages/tui"
|
|
67
67
|
}
|
|
68
68
|
}
|
|
@@ -7,8 +7,8 @@
|
|
|
7
7
|
*/
|
|
8
8
|
|
|
9
9
|
import { randomUUID } from "node:crypto";
|
|
10
|
-
import type { Model } from "@
|
|
11
|
-
import type { AgentSession } from "@
|
|
10
|
+
import type { Model } from "@earendil-works/pi-ai";
|
|
11
|
+
import type { AgentSession } from "@earendil-works/pi-coding-agent";
|
|
12
12
|
import { AgentRecord } from "./agent-record.js";
|
|
13
13
|
import type { AgentRunner } from "./agent-runner.js";
|
|
14
14
|
import { AgentTypeRegistry } from "./agent-types.js";
|
|
@@ -12,7 +12,7 @@
|
|
|
12
12
|
* after construction as lifecycle information becomes available.
|
|
13
13
|
*/
|
|
14
14
|
|
|
15
|
-
import type { AgentSession } from "@
|
|
15
|
+
import type { AgentSession } from "@earendil-works/pi-coding-agent";
|
|
16
16
|
import type { ExecutionState } from "./execution-state.js";
|
|
17
17
|
import type { NotificationState } from "./notification-state.js";
|
|
18
18
|
import type { AgentInvocation, SubagentType } from "./types.js";
|
|
@@ -2,12 +2,12 @@
|
|
|
2
2
|
* agent-runner.ts — Core execution engine: creates sessions, runs agents, collects results.
|
|
3
3
|
*/
|
|
4
4
|
|
|
5
|
-
import type { Model } from "@
|
|
5
|
+
import type { Model } from "@earendil-works/pi-ai";
|
|
6
6
|
import {
|
|
7
7
|
type AgentSession,
|
|
8
8
|
type AgentSessionEvent,
|
|
9
9
|
type SettingsManager,
|
|
10
|
-
} from "@
|
|
10
|
+
} from "@earendil-works/pi-coding-agent";
|
|
11
11
|
import type { AgentConfigLookup } from "./agent-types.js";
|
|
12
12
|
import { extractText } from "./context.js";
|
|
13
13
|
import type { EnvInfo } from "./env.js";
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
* context.ts — Extract parent conversation context for subagent inheritance.
|
|
3
3
|
*/
|
|
4
4
|
|
|
5
|
-
import type { ExtensionContext } from "@
|
|
5
|
+
import type { ExtensionContext } from "@earendil-works/pi-coding-agent";
|
|
6
6
|
|
|
7
7
|
/** Extract text from a message content block array. */
|
|
8
8
|
export function extractText(content: unknown[]): string {
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
|
|
5
5
|
import { existsSync, readdirSync, readFileSync } from "node:fs";
|
|
6
6
|
import { basename, join } from "node:path";
|
|
7
|
-
import { getAgentDir, parseFrontmatter } from "@
|
|
7
|
+
import { getAgentDir, parseFrontmatter } from "@earendil-works/pi-coding-agent";
|
|
8
8
|
import { BUILTIN_TOOL_NAMES } from "./agent-types.js";
|
|
9
9
|
import { debugLog } from "./debug.js";
|
|
10
10
|
import type { AgentConfig, MemoryScope, ThinkingLevel } from "./types.js";
|
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
* it is set at a different moment (after runner.run() returns).
|
|
8
8
|
*/
|
|
9
9
|
|
|
10
|
-
import type { AgentSession } from "@
|
|
10
|
+
import type { AgentSession } from "@earendil-works/pi-coding-agent";
|
|
11
11
|
|
|
12
12
|
export interface ExecutionState {
|
|
13
13
|
/** The active agent session — available from the moment the session is created. */
|
|
@@ -19,7 +19,7 @@ import {
|
|
|
19
19
|
getAgentDir,
|
|
20
20
|
SettingsManager as SdkSettingsManager,
|
|
21
21
|
SessionManager,
|
|
22
|
-
} from "@
|
|
22
|
+
} from "@earendil-works/pi-coding-agent";
|
|
23
23
|
import { AgentManager, type AgentManagerObserver } from "./agent-manager.js";
|
|
24
24
|
import { createAgentRunner, getAgentConversation, type RunnerIO, steerAgent } from "./agent-runner.js";
|
|
25
25
|
import { AgentTypeRegistry } from "./agent-types.js";
|
|
@@ -212,7 +212,7 @@ export default function (pi: ExtensionAPI) {
|
|
|
212
212
|
settings,
|
|
213
213
|
buildSnapshot: (inheritContext) =>
|
|
214
214
|
buildParentSnapshot(
|
|
215
|
-
runtime.currentCtx?.ctx as import("@
|
|
215
|
+
runtime.currentCtx?.ctx as import("@earendil-works/pi-coding-agent").ExtensionContext,
|
|
216
216
|
inheritContext,
|
|
217
217
|
),
|
|
218
218
|
getModelInfo: () => ({
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
* parent-snapshot.ts — Capture parent session state as a plain data snapshot.
|
|
3
3
|
*/
|
|
4
4
|
|
|
5
|
-
import type { ExtensionContext } from "@
|
|
5
|
+
import type { ExtensionContext } from "@earendil-works/pi-coding-agent";
|
|
6
6
|
import { buildParentContext } from "./context.js";
|
|
7
7
|
|
|
8
8
|
/**
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
* (stripping non-serializable fields), and session gating.
|
|
6
6
|
*/
|
|
7
7
|
|
|
8
|
-
import type { ExtensionContext } from "@
|
|
8
|
+
import type { ExtensionContext } from "@earendil-works/pi-coding-agent";
|
|
9
9
|
import type { ModelRegistry } from "./model-resolver.js";
|
|
10
10
|
import type { ParentSnapshot } from "./parent-snapshot.js";
|
|
11
11
|
import { buildParentSnapshot } from "./parent-snapshot.js";
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
|
|
5
5
|
import { existsSync, mkdirSync, readFileSync, writeFileSync } from "node:fs";
|
|
6
6
|
import { dirname, join } from "node:path";
|
|
7
|
-
import { getAgentDir } from "@
|
|
7
|
+
import { getAgentDir } from "@earendil-works/pi-coding-agent";
|
|
8
8
|
export interface SubagentsSettings {
|
|
9
9
|
maxConcurrent?: number;
|
|
10
10
|
/**
|
|
@@ -22,7 +22,7 @@ import type { Dirent } from "node:fs";
|
|
|
22
22
|
import { existsSync, readdirSync } from "node:fs";
|
|
23
23
|
import { homedir } from "node:os";
|
|
24
24
|
import { join } from "node:path";
|
|
25
|
-
import { getAgentDir } from "@
|
|
25
|
+
import { getAgentDir } from "@earendil-works/pi-coding-agent";
|
|
26
26
|
import { debugLog } from "./debug.js";
|
|
27
27
|
import { isSymlink, isUnsafeName, safeReadFile } from "./memory.js";
|
|
28
28
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import type { AgentToolResult } from "@
|
|
2
|
-
import { Text } from "@
|
|
1
|
+
import type { AgentToolResult } from "@earendil-works/pi-coding-agent";
|
|
2
|
+
import { Text } from "@earendil-works/pi-tui";
|
|
3
3
|
import { Type } from "@sinclair/typebox";
|
|
4
4
|
import type { AgentSpawnConfig } from "../agent-manager.js";
|
|
5
5
|
import { AgentTypeRegistry } from "../agent-types.js";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { AgentToolResult } from "@
|
|
1
|
+
import type { AgentToolResult } from "@earendil-works/pi-coding-agent";
|
|
2
2
|
import type { AgentSpawnConfig } from "../agent-manager.js";
|
|
3
3
|
import type { ParentSnapshot } from "../parent-snapshot.js";
|
|
4
4
|
import type { AgentRecord } from "../types.js";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { AgentSession } from "@
|
|
1
|
+
import type { AgentSession } from "@earendil-works/pi-coding-agent";
|
|
2
2
|
import { Type } from "@sinclair/typebox";
|
|
3
3
|
import type { AgentConfigLookup } from "../agent-types.js";
|
|
4
4
|
import type { AgentRecord } from "../types.js";
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
* tag building, and detail-base construction.
|
|
7
7
|
*/
|
|
8
8
|
|
|
9
|
-
import type { Model } from "@
|
|
9
|
+
import type { Model } from "@earendil-works/pi-ai";
|
|
10
10
|
import { normalizeMaxTurns } from "../agent-runner.js";
|
|
11
11
|
import type { AgentTypeRegistry } from "../agent-types.js";
|
|
12
12
|
import { resolveAgentInvocationConfig } from "../invocation-config.js";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { AgentSession } from "@
|
|
1
|
+
import type { AgentSession } from "@earendil-works/pi-coding-agent";
|
|
2
2
|
import { Type } from "@sinclair/typebox";
|
|
3
3
|
import type { AgentRecord } from "../types.js";
|
|
4
4
|
import { getSessionContextPercent } from "../usage.js";
|
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
|
|
8
8
|
import { join } from "node:path";
|
|
9
9
|
|
|
10
|
-
import type { ExtensionContext } from "@
|
|
10
|
+
import type { ExtensionContext } from "@earendil-works/pi-coding-agent";
|
|
11
11
|
import type { AgentTypeRegistry } from "../agent-types.js";
|
|
12
12
|
import type { AgentConfig } from "../types.js";
|
|
13
13
|
import type { AgentFileOps } from "./agent-file-ops.js";
|
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
|
|
8
8
|
import { join } from "node:path";
|
|
9
9
|
|
|
10
|
-
import type { ExtensionContext } from "@
|
|
10
|
+
import type { ExtensionContext } from "@earendil-works/pi-coding-agent";
|
|
11
11
|
import { BUILTIN_TOOL_NAMES } from "../agent-types.js";
|
|
12
12
|
import type { AgentRecord } from "../types.js";
|
|
13
13
|
import type { AgentFileOps } from "./agent-file-ops.js";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { ExtensionContext } from "@
|
|
1
|
+
import type { ExtensionContext } from "@earendil-works/pi-coding-agent";
|
|
2
2
|
import type { AgentSpawnConfig } from "../agent-manager.js";
|
|
3
3
|
import { AgentTypeRegistry } from "../agent-types.js";
|
|
4
4
|
import type { ModelRegistry } from "../model-resolver.js";
|
|
@@ -5,8 +5,8 @@
|
|
|
5
5
|
* Subscribes to session events for real-time streaming updates.
|
|
6
6
|
*/
|
|
7
7
|
|
|
8
|
-
import type { AgentSession } from "@
|
|
9
|
-
import { type Component, matchesKey, type TUI, truncateToWidth, visibleWidth, wrapTextWithAnsi } from "@
|
|
8
|
+
import type { AgentSession } from "@earendil-works/pi-coding-agent";
|
|
9
|
+
import { type Component, matchesKey, type TUI, truncateToWidth, visibleWidth, wrapTextWithAnsi } from "@earendil-works/pi-tui";
|
|
10
10
|
import type { AgentConfigLookup } from "../agent-types.js";
|
|
11
11
|
import { extractText } from "../context.js";
|
|
12
12
|
import type { AgentRecord } from "../types.js";
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
* No timers, no SDK types, no side effects. Consumed by AgentWidget.
|
|
6
6
|
*/
|
|
7
7
|
|
|
8
|
-
import { truncateToWidth } from "@
|
|
8
|
+
import { truncateToWidth } from "@earendil-works/pi-tui";
|
|
9
9
|
import type { AgentConfigLookup } from "../agent-types.js";
|
|
10
10
|
import type { SubagentType } from "../types.js";
|
|
11
11
|
import type { LifetimeUsage, SessionLike } from "../usage.js";
|
|
@@ -17,7 +17,7 @@ const mockAgentLookup = {
|
|
|
17
17
|
getToolNamesForType: vi.fn((): string[] => ["read"]),
|
|
18
18
|
};
|
|
19
19
|
|
|
20
|
-
import type { AgentSession } from "@
|
|
20
|
+
import type { AgentSession } from "@earendil-works/pi-coding-agent";
|
|
21
21
|
import { resumeAgent, runAgent } from "../src/agent-runner.js";
|
|
22
22
|
|
|
23
23
|
// ── RunnerIO stub factory ──────────────────────────────────────────────────────
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import type { AgentSession } from "@
|
|
2
|
-
import type { TUI } from "@
|
|
1
|
+
import type { AgentSession } from "@earendil-works/pi-coding-agent";
|
|
2
|
+
import type { TUI } from "@earendil-works/pi-tui";
|
|
3
3
|
import { beforeEach, describe, expect, it, vi } from "vitest";
|
|
4
4
|
import { AgentTypeRegistry } from "../src/agent-types.js";
|
|
5
5
|
import type { AgentActivityTracker } from "../src/ui/agent-activity-tracker.js";
|
|
@@ -16,8 +16,8 @@ const testRegistry = new AgentTypeRegistry(() => new Map());
|
|
|
16
16
|
|
|
17
17
|
let wrapOverride: ((text: string, width: number) => string[]) | null = null;
|
|
18
18
|
|
|
19
|
-
vi.mock("@
|
|
20
|
-
const original = await importOriginal<typeof import("@
|
|
19
|
+
vi.mock("@earendil-works/pi-tui", async (importOriginal) => {
|
|
20
|
+
const original = await importOriginal<typeof import("@earendil-works/pi-tui")>();
|
|
21
21
|
return {
|
|
22
22
|
...original,
|
|
23
23
|
wrapTextWithAnsi: (...args: [string, number]) => {
|
|
@@ -29,7 +29,7 @@ vi.mock("@mariozechner/pi-tui", async (importOriginal) => {
|
|
|
29
29
|
|
|
30
30
|
// Must import AFTER vi.mock declaration (vitest hoists vi.mock but the
|
|
31
31
|
// dynamic import of the test subject must happen after)
|
|
32
|
-
const { visibleWidth } = await import("@
|
|
32
|
+
const { visibleWidth } = await import("@earendil-works/pi-tui");
|
|
33
33
|
const { ConversationViewer } = await import("../src/ui/conversation-viewer.js");
|
|
34
34
|
|
|
35
35
|
// ── Helpers ────────────────────────────────────────────────────────────
|
|
@@ -254,7 +254,7 @@ describe("ConversationViewer", () => {
|
|
|
254
254
|
}
|
|
255
255
|
|
|
256
256
|
it("mock is intercepting wrapTextWithAnsi", async () => {
|
|
257
|
-
const { wrapTextWithAnsi } = await import("@
|
|
257
|
+
const { wrapTextWithAnsi } = await import("@earendil-works/pi-tui");
|
|
258
258
|
wrapOverride = () => ["MOCK_SENTINEL"];
|
|
259
259
|
expect(wrapTextWithAnsi("anything", 10)).toEqual(["MOCK_SENTINEL"]);
|
|
260
260
|
wrapOverride = null;
|
|
@@ -437,10 +437,10 @@ Bad isolation.`);
|
|
|
437
437
|
expect(result.get("bad-isolation")!.isolation).toBeUndefined();
|
|
438
438
|
});
|
|
439
439
|
|
|
440
|
-
it("honors
|
|
440
|
+
it("honors DM_CODING_AGENT_DIR for global custom agent discovery", () => {
|
|
441
441
|
const altAgentDir = mkdtempSync(join(tmpdir(), "pi-alt-agent-"));
|
|
442
|
-
const originalEnv = process.env.
|
|
443
|
-
process.env.
|
|
442
|
+
const originalEnv = process.env.DM_CODING_AGENT_DIR;
|
|
443
|
+
process.env.DM_CODING_AGENT_DIR = altAgentDir;
|
|
444
444
|
try {
|
|
445
445
|
const globalAgentsDir = join(altAgentDir, "agents");
|
|
446
446
|
mkdirSync(globalAgentsDir, { recursive: true });
|
|
@@ -451,12 +451,12 @@ Bad isolation.`);
|
|
|
451
451
|
|
|
452
452
|
const result = loadCustomAgents(tmpDir);
|
|
453
453
|
|
|
454
|
-
// Agent is found at $
|
|
454
|
+
// Agent is found at $DM_CODING_AGENT_DIR/agents, not at $HOME/.dm/agent/agents
|
|
455
455
|
expect(result.has("via-env")).toBe(true);
|
|
456
456
|
expect(result.get("via-env")!.description).toBe("Discovered via env var");
|
|
457
457
|
} finally {
|
|
458
|
-
if (originalEnv == null) delete process.env.
|
|
459
|
-
else process.env.
|
|
458
|
+
if (originalEnv == null) delete process.env.DM_CODING_AGENT_DIR;
|
|
459
|
+
else process.env.DM_CODING_AGENT_DIR = originalEnv;
|
|
460
460
|
rmSync(altAgentDir, { recursive: true, force: true });
|
|
461
461
|
}
|
|
462
462
|
});
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
* injected deps instead — ctx is never inspected. This typed stub avoids
|
|
6
6
|
* 'as any' while documenting the intent.
|
|
7
7
|
*/
|
|
8
|
-
import type { ExtensionContext } from "@
|
|
8
|
+
import type { ExtensionContext } from "@earendil-works/pi-coding-agent";
|
|
9
9
|
import type { ParentSnapshot } from "../../src/parent-snapshot.js";
|
|
10
10
|
|
|
11
11
|
export const STUB_CTX = {} as unknown as ExtensionContext;
|
|
@@ -8,7 +8,7 @@ vi.mock("../src/context.js", () => ({
|
|
|
8
8
|
buildParentContext: buildParentContextMock,
|
|
9
9
|
}));
|
|
10
10
|
|
|
11
|
-
import type { ExtensionContext } from "@
|
|
11
|
+
import type { ExtensionContext } from "@earendil-works/pi-coding-agent";
|
|
12
12
|
import { buildParentSnapshot } from "../src/parent-snapshot.js";
|
|
13
13
|
|
|
14
14
|
function makeCtx(overrides: Record<string, unknown> = {}) {
|
|
@@ -11,7 +11,7 @@ import {
|
|
|
11
11
|
|
|
12
12
|
/**
|
|
13
13
|
* Tests for persistent settings. Uses two tmp directories:
|
|
14
|
-
* - `globalDir`: redirected via
|
|
14
|
+
* - `globalDir`: redirected via DM_CODING_AGENT_DIR so getAgentDir() returns it.
|
|
15
15
|
* Simulates `~/.dm/agent/` — the global scope.
|
|
16
16
|
* - `projectDir`: passed explicitly as cwd to load/save.
|
|
17
17
|
* Simulates the user's project root. Settings live at `<projectDir>/.dm/subagents.json`.
|
|
@@ -27,13 +27,13 @@ describe("settings persistence", () => {
|
|
|
27
27
|
beforeEach(() => {
|
|
28
28
|
globalDir = mkdtempSync(join(tmpdir(), "pi-settings-global-"));
|
|
29
29
|
projectDir = mkdtempSync(join(tmpdir(), "pi-settings-project-"));
|
|
30
|
-
originalAgentDirEnv = process.env.
|
|
31
|
-
process.env.
|
|
30
|
+
originalAgentDirEnv = process.env.DM_CODING_AGENT_DIR;
|
|
31
|
+
process.env.DM_CODING_AGENT_DIR = globalDir;
|
|
32
32
|
});
|
|
33
33
|
|
|
34
34
|
afterEach(() => {
|
|
35
|
-
if (originalAgentDirEnv == null) delete process.env.
|
|
36
|
-
else process.env.
|
|
35
|
+
if (originalAgentDirEnv == null) delete process.env.DM_CODING_AGENT_DIR;
|
|
36
|
+
else process.env.DM_CODING_AGENT_DIR = originalAgentDirEnv;
|
|
37
37
|
rmSync(globalDir, { recursive: true, force: true });
|
|
38
38
|
rmSync(projectDir, { recursive: true, force: true });
|
|
39
39
|
});
|
|
@@ -10,21 +10,21 @@ describe("preloadSkills", () => {
|
|
|
10
10
|
|
|
11
11
|
beforeEach(() => {
|
|
12
12
|
tmpDir = mkdtempSync(join(tmpdir(), "pi-skill-test-"));
|
|
13
|
-
originalAgentDir = process.env.
|
|
14
|
-
process.env.
|
|
13
|
+
originalAgentDir = process.env.DM_CODING_AGENT_DIR;
|
|
14
|
+
process.env.DM_CODING_AGENT_DIR = join(tmpDir, "user-agent-dir");
|
|
15
15
|
});
|
|
16
16
|
|
|
17
17
|
afterEach(() => {
|
|
18
18
|
if (originalAgentDir === undefined) {
|
|
19
|
-
delete process.env.
|
|
19
|
+
delete process.env.DM_CODING_AGENT_DIR;
|
|
20
20
|
} else {
|
|
21
|
-
process.env.
|
|
21
|
+
process.env.DM_CODING_AGENT_DIR = originalAgentDir;
|
|
22
22
|
}
|
|
23
23
|
rmSync(tmpDir, { recursive: true, force: true });
|
|
24
24
|
});
|
|
25
25
|
|
|
26
26
|
const projectRoot = () => join(tmpDir, ".dm", "skills");
|
|
27
|
-
const globalRoot = () => join(process.env.
|
|
27
|
+
const globalRoot = () => join(process.env.DM_CODING_AGENT_DIR!, "skills");
|
|
28
28
|
|
|
29
29
|
function writeFlat(root: string, name: string, content: string, ext = ".md") {
|
|
30
30
|
mkdirSync(root, { recursive: true });
|
|
@@ -26,8 +26,10 @@ describe("dm-subagents source-layout contract", () => {
|
|
|
26
26
|
expect(pkg.name).toBe("dm-subagents");
|
|
27
27
|
expect(pkg.version).toBe("6.16.1");
|
|
28
28
|
expect(pkg.pi.extensions).toEqual(["./src/index.ts"]);
|
|
29
|
-
expect(pkg.peerDependencies["@
|
|
30
|
-
expect(pkg.devDependencies["@
|
|
29
|
+
expect(pkg.peerDependencies["@earendil-works/pi-coding-agent"]).toBe(">=0.72.1");
|
|
30
|
+
expect(pkg.devDependencies["@earendil-works/pi-coding-agent"]).toBe(
|
|
31
|
+
"file:../../pi-mono/packages/coding-agent",
|
|
32
|
+
);
|
|
31
33
|
});
|
|
32
34
|
|
|
33
35
|
it("keeps source-layout tools and /agents command visible", () => {
|
|
@@ -52,7 +54,7 @@ describe("dm-subagents source-layout contract", () => {
|
|
|
52
54
|
const checked = ["README.md", "AGENTS.md", ...walk("src"), ...walk("test")]
|
|
53
55
|
.filter((file) => file !== "test/unit/subagent-contract.test.ts")
|
|
54
56
|
.filter((file) => [".ts", ".md", ".json"].includes(extname(file)));
|
|
55
|
-
const banned = ["@gotgenes/pi-subagents", "@
|
|
57
|
+
const banned = ["@gotgenes/pi-subagents", "@mariozechner/pi", "pi-subagents", "~/.pi", ".pi/", "Pi "];
|
|
56
58
|
const hits: string[] = [];
|
|
57
59
|
for (const file of checked) {
|
|
58
60
|
const text = read(file);
|
|
@@ -5,9 +5,9 @@
|
|
|
5
5
|
"requires": true,
|
|
6
6
|
"packages": {
|
|
7
7
|
"node_modules/typebox": {
|
|
8
|
-
"version": "1.2.
|
|
9
|
-
"resolved": "https://registry.npmjs.org/typebox/-/typebox-1.2.
|
|
10
|
-
"integrity": "sha512-
|
|
8
|
+
"version": "1.2.6",
|
|
9
|
+
"resolved": "https://registry.npmjs.org/typebox/-/typebox-1.2.6.tgz",
|
|
10
|
+
"integrity": "sha512-9LXWA7hsfQTDecP1vDjlT9JFVobJ5x9lgaZ5vrcZuhTJ6wNGxJ5FnqYCgV0pdxSTxGSHEQ+DjA+fCOcWP5+b9g==",
|
|
11
11
|
"license": "MIT"
|
|
12
12
|
}
|
|
13
13
|
}
|
|
@@ -12,5 +12,5 @@ export function IsDependencies(schema) {
|
|
|
12
12
|
return Guard.HasPropertyKey(schema, 'dependencies')
|
|
13
13
|
&& Guard.IsObject(schema.dependencies)
|
|
14
14
|
&& Object.values(schema.dependencies).every(value => IsSchema(value)
|
|
15
|
-
|| Guard.IsArray(value) && value.every(value => Guard.IsString(value)));
|
|
15
|
+
|| (Guard.IsArray(value) && value.every(value => Guard.IsString(value))));
|
|
16
16
|
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { type TSchema, type TSchemaOptions } from '../types/schema.mjs';
|
|
2
|
+
import { type TDeferred } from '../types/deferred.mjs';
|
|
3
|
+
import { type TAddImmutableAction } from '../engine/immutable/instantiate_add.mjs';
|
|
4
|
+
/** Creates a deferred AddImmutable action. */
|
|
5
|
+
export type TAddImmutableDeferred<Type extends TSchema> = (TDeferred<'AddImmutable', [Type]>);
|
|
6
|
+
/** Creates a deferred AddImmutable action. */
|
|
7
|
+
export declare function AddImmutableDeferred<Type extends TSchema>(type: Type, options?: TSchemaOptions): TAddImmutableDeferred<Type>;
|
|
8
|
+
/** Applies an AddImmutable action to a type. */
|
|
9
|
+
export type TAddImmutable<Type extends TSchema> = (TAddImmutableAction<Type>);
|
|
10
|
+
/** Applies an AddImmutable action to a type. */
|
|
11
|
+
export declare function AddImmutable<Type extends TSchema>(type: Type, options?: TSchemaOptions): TAddImmutable<Type>;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
// deno-fmt-ignore-file
|
|
2
|
+
import { Deferred } from '../types/deferred.mjs';
|
|
3
|
+
import { AddImmutableAction } from '../engine/immutable/instantiate_add.mjs';
|
|
4
|
+
/** Creates a deferred AddImmutable action. */
|
|
5
|
+
export function AddImmutableDeferred(type, options = {}) {
|
|
6
|
+
return Deferred('AddImmutable', [type], options);
|
|
7
|
+
}
|
|
8
|
+
/** Applies an AddImmutable action to a type. */
|
|
9
|
+
export function AddImmutable(type, options = {}) {
|
|
10
|
+
return AddImmutableAction(type, options);
|
|
11
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { type TSchema, type TSchemaOptions } from '../types/schema.mjs';
|
|
2
|
+
import { type TDeferred } from '../types/deferred.mjs';
|
|
3
|
+
import { type TAddOptionalAction } from '../engine/optional/instantiate_add.mjs';
|
|
4
|
+
/** Creates a deferred AddOptional action. */
|
|
5
|
+
export type TAddOptionalDeferred<Type extends TSchema> = (TDeferred<'AddOptional', [Type]>);
|
|
6
|
+
/** Creates a deferred AddOptional action. */
|
|
7
|
+
export declare function AddOptionalDeferred<Type extends TSchema>(type: Type, options?: TSchemaOptions): TAddOptionalDeferred<Type>;
|
|
8
|
+
/** Applies an AddOptional action to a type. */
|
|
9
|
+
export type TAddOptional<Type extends TSchema> = (TAddOptionalAction<Type>);
|
|
10
|
+
/** Applies an AddOptional action to a type. */
|
|
11
|
+
export declare function AddOptional<Type extends TSchema>(type: Type, options?: TSchemaOptions): TAddOptional<Type>;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
// deno-fmt-ignore-file
|
|
2
|
+
import { Deferred } from '../types/deferred.mjs';
|
|
3
|
+
import { AddOptionalAction } from '../engine/optional/instantiate_add.mjs';
|
|
4
|
+
/** Creates a deferred AddOptional action. */
|
|
5
|
+
export function AddOptionalDeferred(type, options = {}) {
|
|
6
|
+
return Deferred('AddOptional', [type], options);
|
|
7
|
+
}
|
|
8
|
+
/** Applies an AddOptional action to a type. */
|
|
9
|
+
export function AddOptional(type, options = {}) {
|
|
10
|
+
return AddOptionalAction(type, options);
|
|
11
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { type TSchema, type TSchemaOptions } from '../types/schema.mjs';
|
|
2
|
+
import { type TDeferred } from '../types/deferred.mjs';
|
|
3
|
+
import { type TAddReadonlyAction } from '../engine/readonly/instantiate_add.mjs';
|
|
4
|
+
/** Creates a deferred AddReadonly action. */
|
|
5
|
+
export type TAddReadonlyDeferred<Type extends TSchema> = (TDeferred<'AddReadonly', [Type]>);
|
|
6
|
+
/** Creates a deferred AddReadonly action. */
|
|
7
|
+
export declare function AddReadonlyDeferred<Type extends TSchema>(type: Type, options?: TSchemaOptions): TAddReadonlyDeferred<Type>;
|
|
8
|
+
/** Applies an AddReadonly action to a type. */
|
|
9
|
+
export type TAddReadonly<Type extends TSchema> = (TAddReadonlyAction<Type>);
|
|
10
|
+
/** Applies an AddReadonly action to a type. */
|
|
11
|
+
export declare function AddReadonly<Type extends TSchema>(type: Type, options?: TSchemaOptions): TAddReadonly<Type>;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
// deno-fmt-ignore-file
|
|
2
|
+
import { Deferred } from '../types/deferred.mjs';
|
|
3
|
+
import { AddReadonlyAction } from '../engine/readonly/instantiate_add.mjs';
|
|
4
|
+
/** Creates a deferred AddReadonly action. */
|
|
5
|
+
export function AddReadonlyDeferred(type, options = {}) {
|
|
6
|
+
return Deferred('AddReadonly', [type], options);
|
|
7
|
+
}
|
|
8
|
+
/** Applies an AddReadonly action to a type. */
|
|
9
|
+
export function AddReadonly(type, options = {}) {
|
|
10
|
+
return AddReadonlyAction(type, options);
|
|
11
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { type TSchema, type TSchemaOptions } from '../types/schema.mjs';
|
|
2
|
+
import { type TDeferred } from '../types/deferred.mjs';
|
|
3
|
+
import { type TRemoveImmutableAction } from '../engine/immutable/instantiate_remove.mjs';
|
|
4
|
+
/** Creates a deferred RemoveImmutable action. */
|
|
5
|
+
export type TRemoveImmutableDeferred<Type extends TSchema> = (TDeferred<'RemoveImmutable', [Type]>);
|
|
6
|
+
/** Creates a deferred RemoveImmutable action. */
|
|
7
|
+
export declare function RemoveImmutableDeferred<Type extends TSchema>(type: Type, options?: TSchemaOptions): TRemoveImmutableDeferred<Type>;
|
|
8
|
+
/** Applies an RemoveImmutable action to a type. */
|
|
9
|
+
export type TRemoveImmutable<Type extends TSchema> = (TRemoveImmutableAction<Type>);
|
|
10
|
+
/** Applies an RemoveImmutable action to a type. */
|
|
11
|
+
export declare function RemoveImmutable<Type extends TSchema>(type: Type, options?: TSchemaOptions): TRemoveImmutable<Type>;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
// deno-fmt-ignore-file
|
|
2
|
+
import { Deferred } from '../types/deferred.mjs';
|
|
3
|
+
import { RemoveImmutableAction } from '../engine/immutable/instantiate_remove.mjs';
|
|
4
|
+
/** Creates a deferred RemoveImmutable action. */
|
|
5
|
+
export function RemoveImmutableDeferred(type, options = {}) {
|
|
6
|
+
return Deferred('RemoveImmutable', [type], options);
|
|
7
|
+
}
|
|
8
|
+
/** Applies an RemoveImmutable action to a type. */
|
|
9
|
+
export function RemoveImmutable(type, options = {}) {
|
|
10
|
+
return RemoveImmutableAction(type, options);
|
|
11
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { type TSchema, type TSchemaOptions } from '../types/schema.mjs';
|
|
2
|
+
import { type TDeferred } from '../types/deferred.mjs';
|
|
3
|
+
import { type TRemoveOptionalAction } from '../engine/optional/instantiate_remove.mjs';
|
|
4
|
+
/** Creates a deferred RemoveOptional action. */
|
|
5
|
+
export type TRemoveOptionalDeferred<Type extends TSchema> = (TDeferred<'RemoveOptional', [Type]>);
|
|
6
|
+
/** Creates a deferred RemoveOptional action. */
|
|
7
|
+
export declare function RemoveOptionalDeferred<Type extends TSchema>(type: Type, options?: TSchemaOptions): TRemoveOptionalDeferred<Type>;
|
|
8
|
+
/** Applies an RemoveOptional action to a type. */
|
|
9
|
+
export type TRemoveOptional<Type extends TSchema> = (TRemoveOptionalAction<Type>);
|
|
10
|
+
/** Applies an RemoveOptional action to a type. */
|
|
11
|
+
export declare function RemoveOptional<Type extends TSchema>(type: Type, options?: TSchemaOptions): TRemoveOptional<Type>;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
// deno-fmt-ignore-file
|
|
2
|
+
import { Deferred } from '../types/deferred.mjs';
|
|
3
|
+
import { RemoveOptionalAction } from '../engine/optional/instantiate_remove.mjs';
|
|
4
|
+
/** Creates a deferred RemoveOptional action. */
|
|
5
|
+
export function RemoveOptionalDeferred(type, options = {}) {
|
|
6
|
+
return Deferred('RemoveOptional', [type], options);
|
|
7
|
+
}
|
|
8
|
+
/** Applies an RemoveOptional action to a type. */
|
|
9
|
+
export function RemoveOptional(type, options = {}) {
|
|
10
|
+
return RemoveOptionalAction(type, options);
|
|
11
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { type TSchema, type TSchemaOptions } from '../types/schema.mjs';
|
|
2
|
+
import { type TDeferred } from '../types/deferred.mjs';
|
|
3
|
+
import { type TRemoveReadonlyAction } from '../engine/readonly/instantiate_remove.mjs';
|
|
4
|
+
/** Creates a deferred RemoveReadonly action. */
|
|
5
|
+
export type TRemoveReadonlyDeferred<Type extends TSchema> = (TDeferred<'RemoveReadonly', [Type]>);
|
|
6
|
+
/** Creates a deferred RemoveReadonly action. */
|
|
7
|
+
export declare function RemoveReadonlyDeferred<Type extends TSchema>(type: Type, options?: TSchemaOptions): TRemoveReadonlyDeferred<Type>;
|
|
8
|
+
/** Applies an RemoveReadonly action to a type. */
|
|
9
|
+
export type TRemoveReadonly<Type extends TSchema> = (TRemoveReadonlyAction<Type>);
|
|
10
|
+
/** Applies an RemoveReadonly action to a type. */
|
|
11
|
+
export declare function RemoveReadonly<Type extends TSchema>(type: Type, options?: TSchemaOptions): TRemoveReadonly<Type>;
|