mirror of
https://github.com/openclaw/openclaw.git
synced 2026-05-08 17:38:27 +00:00
refactor: rename to openclaw
This commit is contained in:
@@ -1,11 +1,11 @@
|
||||
import fs from "node:fs";
|
||||
import path from "node:path";
|
||||
|
||||
import type { BrowserProfileConfig, MoltbotConfig } from "../config/config.js";
|
||||
import type { BrowserProfileConfig, OpenClawConfig } from "../config/config.js";
|
||||
import { loadConfig, writeConfigFile } from "../config/config.js";
|
||||
import { deriveDefaultBrowserCdpPortRange } from "../config/port-defaults.js";
|
||||
import { DEFAULT_BROWSER_DEFAULT_PROFILE_NAME } from "./constants.js";
|
||||
import { resolveClawdUserDataDir } from "./chrome.js";
|
||||
import { resolveOpenClawUserDataDir } from "./chrome.js";
|
||||
import { parseHttpUrl, resolveProfile } from "./config.js";
|
||||
import {
|
||||
allocateCdpPort,
|
||||
@@ -21,7 +21,7 @@ export type CreateProfileParams = {
|
||||
name: string;
|
||||
color?: string;
|
||||
cdpUrl?: string;
|
||||
driver?: "clawd" | "extension";
|
||||
driver?: "openclaw" | "extension";
|
||||
};
|
||||
|
||||
export type CreateProfileResult = {
|
||||
@@ -93,7 +93,7 @@ export function createBrowserProfilesService(ctx: BrowserRouteContext) {
|
||||
};
|
||||
}
|
||||
|
||||
const nextConfig: MoltbotConfig = {
|
||||
const nextConfig: OpenClawConfig = {
|
||||
...cfg,
|
||||
browser: {
|
||||
...cfg.browser,
|
||||
@@ -153,7 +153,7 @@ export function createBrowserProfilesService(ctx: BrowserRouteContext) {
|
||||
// ignore
|
||||
}
|
||||
|
||||
const userDataDir = resolveClawdUserDataDir(name);
|
||||
const userDataDir = resolveOpenClawUserDataDir(name);
|
||||
const profileDir = path.dirname(userDataDir);
|
||||
if (fs.existsSync(profileDir)) {
|
||||
await movePathToTrash(profileDir);
|
||||
@@ -162,7 +162,7 @@ export function createBrowserProfilesService(ctx: BrowserRouteContext) {
|
||||
}
|
||||
|
||||
const { [name]: _removed, ...remainingProfiles } = profiles;
|
||||
const nextConfig: MoltbotConfig = {
|
||||
const nextConfig: OpenClawConfig = {
|
||||
...cfg,
|
||||
browser: {
|
||||
...cfg.browser,
|
||||
|
||||
Reference in New Issue
Block a user