mirror of
https://github.com/openclaw/openclaw.git
synced 2026-05-06 08:10:44 +00:00
refactor: trim core barrel exports
This commit is contained in:
@@ -21,14 +21,6 @@ import {
|
||||
shouldStripProviderAuthEnvVarsForAcpServer,
|
||||
} from "./client-helpers.js";
|
||||
|
||||
export {
|
||||
buildAcpClientStripKeys,
|
||||
resolveAcpClientSpawnEnv,
|
||||
resolveAcpClientSpawnInvocation,
|
||||
resolvePermissionRequest,
|
||||
shouldStripProviderAuthEnvVarsForAcpServer,
|
||||
} from "./client-helpers.js";
|
||||
|
||||
type AcpClientOptions = {
|
||||
cwd?: string;
|
||||
serverCommand?: string;
|
||||
|
||||
@@ -7,21 +7,12 @@ import { resolveCodexNativeWebSearchConfig } from "./codex-native-web-search.sha
|
||||
import { resolveDefaultModelForAgent } from "./model-selection.js";
|
||||
export {
|
||||
buildCodexNativeWebSearchTool,
|
||||
type CodexNativeSearchActivation,
|
||||
type CodexNativeSearchPayloadPatchResult,
|
||||
hasAvailableCodexAuth,
|
||||
hasCodexNativeWebSearchTool,
|
||||
isCodexNativeSearchEligibleModel,
|
||||
patchCodexNativeWebSearchPayload,
|
||||
resolveCodexNativeSearchActivation,
|
||||
shouldSuppressManagedWebSearchTool,
|
||||
} from "./codex-native-web-search-core.js";
|
||||
export {
|
||||
type CodexNativeSearchContextSize,
|
||||
type CodexNativeSearchMode,
|
||||
type CodexNativeSearchUserLocation,
|
||||
describeCodexNativeWebSearch,
|
||||
type ResolvedCodexNativeWebSearchConfig,
|
||||
resolveCodexNativeWebSearchConfig,
|
||||
} from "./codex-native-web-search.shared.js";
|
||||
|
||||
|
||||
@@ -35,9 +35,7 @@ import { clearCliSessionInStore } from "./session-store.js";
|
||||
import type { AgentCommandOpts } from "./types.js";
|
||||
|
||||
export {
|
||||
claudeCliSessionTranscriptHasContent,
|
||||
createAcpVisibleTextAccumulator,
|
||||
resolveFallbackRetryPrompt,
|
||||
sessionFileHasContent,
|
||||
} from "./attempt-execution.helpers.js";
|
||||
|
||||
|
||||
@@ -1,12 +1,10 @@
|
||||
import { shouldHandleTextCommands } from "../commands-registry.js";
|
||||
import { emitResetCommandHooks } from "./commands-reset-hooks.js";
|
||||
import { maybeHandleResetCommand } from "./commands-reset.js";
|
||||
import type {
|
||||
CommandHandler,
|
||||
CommandHandlerResult,
|
||||
HandleCommandsParams,
|
||||
} from "./commands-types.js";
|
||||
export { emitResetCommandHooks } from "./commands-reset-hooks.js";
|
||||
let commandHandlersRuntimePromise: Promise<typeof import("./commands-handlers.runtime.js")> | null =
|
||||
null;
|
||||
|
||||
|
||||
@@ -218,5 +218,3 @@ export const formatAuthLabel = (auth: { label: string; source: string }) => {
|
||||
}
|
||||
return `${auth.label} (${auth.source})`;
|
||||
};
|
||||
|
||||
export { resolveProfileOverride } from "./directive-handling.auth-profile.js";
|
||||
|
||||
@@ -1,10 +1,8 @@
|
||||
export type {
|
||||
BlockReplyContext,
|
||||
GetReplyOptions,
|
||||
ModelSelectedContext,
|
||||
ReplyThreadingPolicy,
|
||||
SourceReplyDeliveryMode,
|
||||
TypingPolicy,
|
||||
} from "./get-reply-options.types.js";
|
||||
export { getReplyPayloadMetadata, setReplyPayloadMetadata } from "./reply-payload.js";
|
||||
export type { ReplyPayload, ReplyPayloadMetadata } from "./reply-payload.js";
|
||||
export { setReplyPayloadMetadata } from "./reply-payload.js";
|
||||
export type { ReplyPayload } from "./reply-payload.js";
|
||||
|
||||
@@ -23,8 +23,6 @@ import {
|
||||
} from "./shared.js";
|
||||
import { formatConfigChannelsStatusLines } from "./status-config-format.js";
|
||||
|
||||
export { formatConfigChannelsStatusLines } from "./status-config-format.js";
|
||||
|
||||
export type ChannelsStatusOptions = {
|
||||
json?: boolean;
|
||||
probe?: boolean;
|
||||
|
||||
@@ -10,7 +10,6 @@ import { formatGitInstallLabel, type UpdateCheckResult } from "../../infra/updat
|
||||
import { normalizeOptionalString } from "../../shared/string-coerce.js";
|
||||
import { formatUpdateOneLiner, resolveUpdateAvailability } from "../status.update.js";
|
||||
|
||||
export { formatDurationPrecise } from "../../infra/format-time/format-duration.ts";
|
||||
export { formatTimeAgo } from "../../infra/format-time/format-relative.ts";
|
||||
|
||||
export type StatusOverviewRow = {
|
||||
|
||||
@@ -5,7 +5,7 @@ import { createEmptyTaskAuditSummary } from "../tasks/task-registry.audit.shared
|
||||
import { createEmptyTaskRegistrySummary } from "../tasks/task-registry.summary.js";
|
||||
import { buildTailscaleHttpsUrl, resolveGatewayProbeSnapshot } from "./status.scan.shared.js";
|
||||
|
||||
export function buildColdStartUpdateResult(): UpdateCheckResult {
|
||||
function buildColdStartUpdateResult(): UpdateCheckResult {
|
||||
return {
|
||||
root: null,
|
||||
installKind: "unknown",
|
||||
@@ -13,7 +13,7 @@ export function buildColdStartUpdateResult(): UpdateCheckResult {
|
||||
};
|
||||
}
|
||||
|
||||
export function buildColdStartAgentLocalStatuses() {
|
||||
function buildColdStartAgentLocalStatuses() {
|
||||
return {
|
||||
defaultId: "main",
|
||||
agents: [],
|
||||
@@ -43,7 +43,7 @@ export function buildColdStartStatusSummary() {
|
||||
};
|
||||
}
|
||||
|
||||
export function shouldSkipStatusScanNetworkChecks(params: {
|
||||
function shouldSkipStatusScanNetworkChecks(params: {
|
||||
coldStart: boolean;
|
||||
hasConfiguredChannels: boolean;
|
||||
all?: boolean;
|
||||
|
||||
@@ -159,7 +159,7 @@ async function applyLocalStatusRpcFallback(params: {
|
||||
};
|
||||
}
|
||||
|
||||
export function hasExplicitMemorySearchConfig(cfg: OpenClawConfig, agentId: string): boolean {
|
||||
function hasExplicitMemorySearchConfig(cfg: OpenClawConfig, agentId: string): boolean {
|
||||
if (
|
||||
cfg.agents?.defaults &&
|
||||
Object.prototype.hasOwnProperty.call(cfg.agents.defaults, "memorySearch")
|
||||
|
||||
Reference in New Issue
Block a user