refactor: rename to openclaw

This commit is contained in:
Peter Steinberger
2026-01-30 03:15:10 +01:00
parent 4583f88626
commit 9a7160786a
2357 changed files with 16688 additions and 16788 deletions

View File

@@ -5,7 +5,7 @@ import { beforeEach, describe, expect, it, vi } from "vitest";
import { withTempHome as withTempHomeBase } from "../../test/helpers/temp-home.js";
import type { CliDeps } from "../cli/deps.js";
import type { MoltbotConfig } from "../config/config.js";
import type { OpenClawConfig } from "../config/config.js";
import type { CronJob } from "./types.js";
vi.mock("../agents/pi-embedded.js", () => ({
@@ -22,11 +22,11 @@ import { runEmbeddedPiAgent } from "../agents/pi-embedded.js";
import { runCronIsolatedAgentTurn } from "./isolated-agent.js";
async function withTempHome<T>(fn: (home: string) => Promise<T>): Promise<T> {
return withTempHomeBase(fn, { prefix: "moltbot-cron-" });
return withTempHomeBase(fn, { prefix: "openclaw-cron-" });
}
async function writeSessionStore(home: string) {
const dir = path.join(home, ".clawdbot", "sessions");
const dir = path.join(home, ".openclaw", "sessions");
await fs.mkdir(dir, { recursive: true });
const storePath = path.join(dir, "sessions.json");
await fs.writeFile(
@@ -57,17 +57,17 @@ async function readSessionEntry(storePath: string, key: string) {
function makeCfg(
home: string,
storePath: string,
overrides: Partial<MoltbotConfig> = {},
): MoltbotConfig {
const base: MoltbotConfig = {
overrides: Partial<OpenClawConfig> = {},
): OpenClawConfig {
const base: OpenClawConfig = {
agents: {
defaults: {
model: "anthropic/claude-opus-4-5",
workspace: path.join(home, "clawd"),
workspace: path.join(home, "openclaw"),
},
},
session: { store: storePath, mainKey: "main" },
} as MoltbotConfig;
} as OpenClawConfig;
return { ...base, ...overrides };
}
@@ -182,7 +182,7 @@ describe("runCronIsolatedAgentTurn", () => {
const cfg = makeCfg(
home,
path.join(home, ".clawdbot", "agents", "{agentId}", "sessions", "sessions.json"),
path.join(home, ".openclaw", "agents", "{agentId}", "sessions", "sessions.json"),
{
agents: {
defaults: { workspace: path.join(home, "default-workspace") },