mirror of
https://github.com/openclaw/openclaw.git
synced 2026-05-06 06:10:44 +00:00
refactor: trim config helper types
This commit is contained in:
@@ -13,9 +13,9 @@ import {
|
||||
type ToolsBySenderKeyType,
|
||||
} from "./types.tools.js";
|
||||
|
||||
export type GroupPolicyChannel = ChannelId;
|
||||
type GroupPolicyChannel = ChannelId;
|
||||
|
||||
export type ChannelGroupConfig = {
|
||||
type ChannelGroupConfig = {
|
||||
requireMention?: boolean;
|
||||
ingest?: boolean;
|
||||
tools?: GroupToolPolicyConfig;
|
||||
@@ -56,7 +56,7 @@ function resolveChannelGroupConfig(
|
||||
return groups[matchedKey];
|
||||
}
|
||||
|
||||
export type GroupToolPolicySender = {
|
||||
type GroupToolPolicySender = {
|
||||
senderId?: string | null;
|
||||
senderName?: string | null;
|
||||
senderUsername?: string | null;
|
||||
|
||||
@@ -32,7 +32,7 @@ export type IncludeResolver = {
|
||||
parseJson: (raw: string) => unknown;
|
||||
};
|
||||
|
||||
export type IncludeFileReadParams = {
|
||||
type IncludeFileReadParams = {
|
||||
includePath: string;
|
||||
resolvedPath: string;
|
||||
rootRealDir: string;
|
||||
@@ -40,7 +40,7 @@ export type IncludeFileReadParams = {
|
||||
maxBytes?: number;
|
||||
};
|
||||
|
||||
export type ResolveConfigIncludesOptions = {
|
||||
type ResolveConfigIncludesOptions = {
|
||||
/**
|
||||
* Additional directories outside the config directory that `$include` paths
|
||||
* may resolve into. Typically populated from `OPENCLAW_INCLUDE_ROOTS`.
|
||||
|
||||
@@ -135,7 +135,7 @@ const CONFIG_AUDIT_LOG_FILENAME = "config-audit.jsonl";
|
||||
|
||||
export type ConfigWriteAuditResult = "rename" | "copy-fallback" | "failed" | "rejected";
|
||||
|
||||
export type ConfigWriteAuditRecord = {
|
||||
type ConfigWriteAuditRecord = {
|
||||
ts: string;
|
||||
source: "config-io";
|
||||
event: "config.write";
|
||||
@@ -231,9 +231,9 @@ export type ConfigObserveAuditRecord = {
|
||||
restoreErrorMessage: string | null;
|
||||
};
|
||||
|
||||
export type ConfigAuditRecord = ConfigWriteAuditRecord | ConfigObserveAuditRecord;
|
||||
type ConfigAuditRecord = ConfigWriteAuditRecord | ConfigObserveAuditRecord;
|
||||
|
||||
export type ConfigAuditStatMetadata = {
|
||||
type ConfigAuditStatMetadata = {
|
||||
dev: string | null;
|
||||
ino: string | null;
|
||||
mode: number | null;
|
||||
@@ -242,7 +242,7 @@ export type ConfigAuditStatMetadata = {
|
||||
gid: number | null;
|
||||
};
|
||||
|
||||
export type ConfigAuditProcessInfo = {
|
||||
type ConfigAuditProcessInfo = {
|
||||
pid: number;
|
||||
ppid: number;
|
||||
cwd: string;
|
||||
@@ -250,7 +250,7 @@ export type ConfigAuditProcessInfo = {
|
||||
execArgv: string[];
|
||||
};
|
||||
|
||||
export type ConfigWriteAuditRecordBase = Omit<
|
||||
type ConfigWriteAuditRecordBase = Omit<
|
||||
ConfigWriteAuditRecord,
|
||||
| "result"
|
||||
| "nextDev"
|
||||
|
||||
Reference in New Issue
Block a user