mirror of
https://github.com/openclaw/openclaw.git
synced 2026-04-27 00:52:05 +00:00
refactor: dedupe cli config cron and install flows
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
import type { OpenClawConfig } from "../config/config.js";
|
||||
import type { PluginInstallRecord } from "../config/types.plugins.js";
|
||||
import type { NpmSpecResolution } from "../infra/install-source-utils.js";
|
||||
import { buildNpmResolutionFields, type NpmSpecResolution } from "../infra/install-source-utils.js";
|
||||
|
||||
export type PluginInstallUpdate = PluginInstallRecord & { pluginId: string };
|
||||
|
||||
@@ -10,14 +10,7 @@ export function buildNpmResolutionInstallFields(
|
||||
PluginInstallRecord,
|
||||
"resolvedName" | "resolvedVersion" | "resolvedSpec" | "integrity" | "shasum" | "resolvedAt"
|
||||
> {
|
||||
return {
|
||||
resolvedName: resolution?.name,
|
||||
resolvedVersion: resolution?.version,
|
||||
resolvedSpec: resolution?.resolvedSpec,
|
||||
integrity: resolution?.integrity,
|
||||
shasum: resolution?.shasum,
|
||||
resolvedAt: resolution?.resolvedAt,
|
||||
};
|
||||
return buildNpmResolutionFields(resolution);
|
||||
}
|
||||
|
||||
export function recordPluginInstall(
|
||||
|
||||
Reference in New Issue
Block a user