Skip to content

Commit eea777c

Browse files
committed
chore(deadcode): trim stale facade re-exports
1 parent 0b28a72 commit eea777c

17 files changed

Lines changed: 28 additions & 41 deletions

src/commands/channel-setup/registry.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
1+
import type { ChannelSetupWizardAdapter } from "../../channels/plugins/setup-wizard-types.js";
12
// Adapts declarative and imperative channel setup wizards to the command-facing interface.
23
import { buildChannelSetupWizardAdapterFromSetupWizard } from "../../channels/plugins/setup-wizard.js";
34
import type { ChannelSetupWizard } from "../../channels/plugins/setup-wizard.js";
45
import type { ChannelPlugin } from "../../channels/plugins/types.plugin.js";
5-
import type { ChannelSetupWizardAdapter } from "./types.js";
66

77
const setupWizardAdapters = new WeakMap<object, ChannelSetupWizardAdapter>();
88

src/commands/channel-setup/types.ts

Lines changed: 0 additions & 2 deletions
This file was deleted.

src/commands/gateway-status/helpers.ts

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,6 @@ import { isLoopbackHost } from "../../gateway/net.js";
1010
import type { GatewayProbeCapability, GatewayProbeResult } from "../../gateway/probe.js";
1111
import { inspectBestEffortPrimaryTailnetIPv4 } from "../../infra/network-discovery-display.js";
1212
import { parseStrictInteger } from "../../infra/parse-finite-number.js";
13-
import { pickGatewaySelfPresence } from "../gateway-presence.js";
1413

1514
const MISSING_SCOPE_PATTERN = /\bmissing scope:\s*[a-z0-9._-]+/i;
1615

@@ -183,8 +182,6 @@ export async function resolveAuthForTarget(
183182
});
184183
}
185184

186-
export { pickGatewaySelfPresence };
187-
188185
/** Extracts the config fields displayed by `openclaw gateway status --deep`. */
189186
export function extractConfigSummary(snapshotUnknown: unknown): GatewayConfigSummary {
190187
const snap = snapshotUnknown as Partial<ConfigFileSnapshot> | null;

src/commands/gateway-status/probe-run.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,10 @@ import {
1010
type GatewayBonjourBeacon,
1111
} from "../../infra/bonjour-discovery.js";
1212
import { formatErrorMessage } from "../../infra/errors.js";
13+
import { pickGatewaySelfPresence } from "../gateway-presence.js";
1314
import { pickAutoSshTargetFromDiscovery } from "./discovery.js";
1415
import {
1516
extractConfigSummary,
16-
pickGatewaySelfPresence,
1717
resolveAuthForTarget,
1818
resolveProbeBudgetMs,
1919
type GatewayConfigSummary,

src/commands/models/aliases.ts

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2,13 +2,9 @@
22
import { formatCliCommand } from "../../cli/command-format.js";
33
import { logConfigUpdated } from "../../config/logging.js";
44
import { type RuntimeEnv, writeRuntimeJson } from "../../runtime.js";
5+
import { normalizeAlias } from "./alias-name.js";
56
import { loadModelsConfig } from "./load-config.js";
6-
import {
7-
ensureFlagCompatibility,
8-
normalizeAlias,
9-
resolveModelTarget,
10-
updateConfig,
11-
} from "./shared.js";
7+
import { ensureFlagCompatibility, resolveModelTarget, updateConfig } from "./shared.js";
128

139
/** Lists configured model aliases as JSON, plain pairs, or human-readable rows. */
1410
export async function modelsAliasesListCommand(

src/commands/models/list.auth-overview.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ import {
2020
import type { OpenClawConfig } from "../../config/types.openclaw.js";
2121
import type { ProviderAuthEvidence } from "../../secrets/provider-env-vars.js";
2222
import { shortenHomePath } from "../../utils.js";
23-
import { maskApiKey } from "./list.format.js";
23+
import { maskApiKey } from "../../utils/mask-api-key.js";
2424
import type { ProviderAuthOverview } from "./list.types.js";
2525

2626
function formatMarkerOrSecret(value: string): string {

src/commands/models/list.format.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
/** Formatting helpers for model-list terminal tables. */
22
import { isRich as isRichTerminal, theme } from "../../../packages/terminal-core/src/theme.js";
3-
export { maskApiKey } from "../../utils/mask-api-key.js";
43

54
/** Enables rich formatting only for non-machine-readable output. */
65
export const isRich = (opts?: { json?: boolean; plain?: boolean }) =>

src/commands/models/list.rows.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,11 +15,12 @@ import type { ProviderRuntimeModel } from "../../plugins/provider-runtime-model.
1515
import { normalizeProviderResolvedModelWithPlugin } from "../../plugins/provider-runtime.js";
1616
import { createLazyImportLoader } from "../../shared/lazy-promise.js";
1717
import type { ModelListAuthIndex } from "./list.auth-index.js";
18+
import { isLocalBaseUrl } from "./list.local-url.js";
1819
import type { ListRowModel } from "./list.model-row.js";
1920
import { toModelRow } from "./list.model-row.js";
2021
import type { ConfiguredEntry, ModelRow } from "./list.types.js";
2122
import { canonicalizeModelCatalogProviderAlias } from "./provider-aliases.js";
22-
import { isLocalBaseUrl, modelKey } from "./shared.js";
23+
import { modelKey } from "./shared.js";
2324

2425
type ConfiguredByKey = Map<string, ConfiguredEntry>;
2526
type ModelCatalogModule = typeof import("../../agents/model-catalog.js");

src/commands/models/shared.ts

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,6 @@ import type { AgentModelEntryConfig } from "../../config/types.agent-defaults.js
1919
import type { AgentModelConfig } from "../../config/types.agents-shared.js";
2020
import { normalizeAgentId } from "../../routing/session-key.js";
2121
import { canonicalizeModelCatalogProviderRef } from "./provider-aliases.js";
22-
export { normalizeAlias } from "./alias-name.js";
23-
export { isLocalBaseUrl } from "./list.local-url.js";
2422

2523
export const ensureFlagCompatibility = (opts: { json?: boolean; plain?: boolean }) => {
2624
if (opts.json && opts.plain) {

src/commands/onboard-channels.e2e.test.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
11
// Onboard channels e2e tests cover setup wizard adapters, plugin install hooks, and channel picker behavior.
22
import { beforeEach, describe, expect, it, vi } from "vitest";
33
import type { ChannelPluginCatalogEntry } from "../channels/plugins/catalog.js";
4+
import { getChannelSetupPlugin } from "../channels/plugins/setup-registry.js";
5+
import type { ChannelSetupWizardAdapter } from "../channels/plugins/setup-wizard-types.js";
46
import {
57
ensureChannelSetupPluginInstalled,
68
loadChannelSetupPluginRegistrySnapshotForChannel,
79
} from "../commands/channel-setup/plugin-install.js";
810
import { resolveChannelSetupWizardAdapterForPlugin } from "../commands/channel-setup/registry.js";
9-
import type { ChannelSetupWizardAdapter } from "../commands/channel-setup/types.js";
1011
import type { OpenClawConfig } from "../config/config.js";
11-
import { getChannelSetupPlugin } from "../channels/plugins/setup-registry.js";
1212
import { createEmptyPluginRegistry } from "../plugins/registry.js";
1313
import { setActivePluginRegistry } from "../plugins/runtime.js";
1414
import { createChannelTestPluginBase, createTestRegistry } from "../test-utils/channel-plugins.js";

0 commit comments

Comments
 (0)