refactor: use direct skills imports · openclaw/openclaw@355fb4d
shakkernerd
·
2026-05-30
·
via Recent Commits to openclaw:main
| Original file line number | Diff line number | Diff line change |
|---|
@@ -3,7 +3,7 @@ import fs from "node:fs/promises";
|
3 | 3 | import path from "node:path"; |
4 | 4 | import { resolvePreferredOpenClawTmpDir } from "../../infra/tmp-openclaw-dir.js"; |
5 | 5 | import { normalizeLowercaseStringOrEmpty } from "../../shared/string-coerce.js"; |
6 | | -import type { SkillSnapshot } from "../../skills/index.js"; |
| 6 | +import type { SkillSnapshot } from "../../skills/types.js"; |
7 | 7 | import { cliBackendLog } from "./log.js"; |
8 | 8 | |
9 | 9 | const CLAUDE_CLI_BACKEND_ID = "claude-cli"; |
|
| Original file line number | Diff line number | Diff line change |
|---|
@@ -11,7 +11,7 @@ import { requestHeartbeat as requestHeartbeatImpl } from "../../infra/heartbeat-
|
11 | 11 | import { sanitizeHostExecEnv } from "../../infra/host-env-security.js"; |
12 | 12 | import { enqueueSystemEvent as enqueueSystemEventImpl } from "../../infra/system-events.js"; |
13 | 13 | import { getProcessSupervisor as getProcessSupervisorImpl } from "../../process/supervisor/index.js"; |
14 | | -import { applySkillEnvOverridesFromSnapshot } from "../../skills/index.js"; |
| 14 | +import { applySkillEnvOverridesFromSnapshot } from "../../skills/env-overrides.js"; |
15 | 15 | import { appendBootstrapPromptWarning } from "../bootstrap-budget.js"; |
16 | 16 | import { |
17 | 17 | createCliJsonlStreamingParser, |
|
| Original file line number | Diff line number | Diff line change |
|---|
@@ -21,7 +21,7 @@ import { buildAgentHookContextChannelFields } from "../../plugins/hook-agent-con
|
21 | 21 | import { getGlobalHookRunner } from "../../plugins/hook-runner-global.js"; |
22 | 22 | import { annotateInterSessionPromptText } from "../../sessions/input-provenance.js"; |
23 | 23 | import { uniqueStrings } from "../../shared/string-normalization.js"; |
24 | | -import { resolveSkillsPromptForRun } from "../../skills/index.js"; |
| 24 | +import { resolveSkillsPromptForRun } from "../../skills/workspace.js"; |
25 | 25 | import { resolveUserPath } from "../../utils.js"; |
26 | 26 | import { resolveAgentDir, resolveSessionAgentIds } from "../agent-scope.js"; |
27 | 27 | import { externalCliDiscoveryForProviderAuth } from "../auth-profiles/external-cli-discovery.js"; |
|
| Original file line number | Diff line number | Diff line change |
|---|
@@ -14,7 +14,7 @@ import type {
|
14 | 14 | PersistedUserTurnMessage, |
15 | 15 | UserTurnTranscriptRecorder, |
16 | 16 | } from "../../sessions/user-turn-transcript.js"; |
17 | | -import type { SkillSnapshot } from "../../skills/index.js"; |
| 17 | +import type { SkillSnapshot } from "../../skills/types.js"; |
18 | 18 | import type { BootstrapContextMode } from "../bootstrap-files.js"; |
19 | 19 | import type { ResolvedCliBackend } from "../cli-backends.js"; |
20 | 20 | import type { ContextWindowInfo } from "../context-window-guard.js"; |
|
| Original file line number | Diff line number | Diff line change |
|---|
@@ -19,7 +19,7 @@ import {
|
19 | 19 | appendUserTurnTranscriptMessage, |
20 | 20 | type PersistedUserTurnMessage, |
21 | 21 | } from "../../sessions/user-turn-transcript.js"; |
22 | | -import { buildWorkspaceSkillSnapshot } from "../../skills/index.js"; |
| 22 | +import { buildWorkspaceSkillSnapshot } from "../../skills/service.js"; |
23 | 23 | import { sanitizeForLog } from "../../terminal/ansi.js"; |
24 | 24 | import { resolveMessageChannel } from "../../utils/message-channel.js"; |
25 | 25 | import { resolveAuthProfileOrder } from "../auth-profiles/order.js"; |
|
| Original file line number | Diff line number | Diff line change |
|---|
@@ -5,7 +5,7 @@ import { ensureContextEnginesInitialized as ensureContextEnginesInitializedImpl
|
5 | 5 | import { resolveContextEngine as resolveContextEngineImpl } from "../../context-engine/registry.js"; |
6 | 6 | import type { ContextEngine } from "../../context-engine/types.js"; |
7 | 7 | import { createSubsystemLogger } from "../../logging/subsystem.js"; |
8 | | -import type { SkillSnapshot } from "../../skills/index.js"; |
| 8 | +import type { SkillSnapshot } from "../../skills/types.js"; |
9 | 9 | import { createPreparedEmbeddedAgentSettingsManager as createPreparedEmbeddedAgentSettingsManagerImpl } from "../agent-project-settings.js"; |
10 | 10 | import { OPENCLAW_AGENT_RUNTIME_ID } from "../agent-runtime-id.js"; |
11 | 11 | import { normalizeOptionalAgentRuntimeId } from "../agent-runtime-id.js"; |
|
| Original file line number | Diff line number | Diff line change |
|---|
@@ -28,8 +28,8 @@ import { isCronSessionKey, isSubagentSessionKey } from "../../routing/session-ke
|
28 | 28 | import { |
29 | 29 | applySkillEnvOverrides, |
30 | 30 | applySkillEnvOverridesFromSnapshot, |
31 | | - resolveSkillsPromptForRun, |
32 | | -} from "../../skills/index.js"; |
| 31 | +} from "../../skills/env-overrides.js"; |
| 32 | +import { resolveSkillsPromptForRun } from "../../skills/workspace.js"; |
33 | 33 | import { resolveUserPath } from "../../utils.js"; |
34 | 34 | import { normalizeMessageChannel } from "../../utils/message-channel.js"; |
35 | 35 | import { isReasoningTagProvider } from "../../utils/provider-utils.js"; |
|
| Original file line number | Diff line number | Diff line change |
|---|
@@ -3,7 +3,7 @@ import type { ReasoningLevel, ThinkLevel } from "../../auto-reply/thinking.js";
|
3 | 3 | import type { OpenClawConfig } from "../../config/types.openclaw.js"; |
4 | 4 | import type { ContextEngine, ContextEngineRuntimeContext } from "../../context-engine/types.js"; |
5 | 5 | import type { CommandQueueEnqueueFn } from "../../process/command-queue.types.js"; |
6 | | -import type { SkillSnapshot } from "../../skills/index.js"; |
| 6 | +import type { SkillSnapshot } from "../../skills/types.js"; |
7 | 7 | import type { ExecElevatedDefaults, ExecToolDefaults } from "../bash-tools.exec-types.js"; |
8 | 8 | import type { AgentRuntimePlan } from "../runtime-plan/types.js"; |
9 | 9 | |
|
| Original file line number | Diff line number | Diff line change |
|---|
|
1 | 1 | import type { SourceReplyDeliveryMode } from "../../auto-reply/get-reply-options.types.js"; |
2 | 2 | import type { ReasoningLevel, ThinkLevel } from "../../auto-reply/thinking.js"; |
3 | 3 | import type { OpenClawConfig } from "../../config/types.openclaw.js"; |
4 | | -import type { SkillSnapshot } from "../../skills/index.js"; |
| 4 | +import type { SkillSnapshot } from "../../skills/types.js"; |
5 | 5 | import { |
6 | 6 | listActiveProcessSessionReferences, |
7 | 7 | type ActiveProcessSessionReference, |
|
| Original file line number | Diff line number | Diff line change |
|---|
@@ -55,8 +55,8 @@ import { normalizeOptionalString } from "../../../shared/string-coerce.js";
|
55 | 55 | import { |
56 | 56 | applySkillEnvOverrides, |
57 | 57 | applySkillEnvOverridesFromSnapshot, |
58 | | - resolveSkillsPromptForRun, |
59 | | -} from "../../../skills/index.js"; |
| 58 | +} from "../../../skills/env-overrides.js"; |
| 59 | +import { resolveSkillsPromptForRun } from "../../../skills/workspace.js"; |
60 | 60 | import { |
61 | 61 | buildTrajectoryArtifacts, |
62 | 62 | buildTrajectoryRunMetadata, |
|
此内容由惯性聚合(RSS阅读器)自动聚合整理,仅供阅读参考。 原文来自 — 版权归原作者所有。