MCPcopy Create free account
hub / github.com/echoVic/blade-code / initialize

Method initialize

src/context/storage/PersistentStore.ts:20–28  ·  view source on GitHub ↗

* 初始化存储目录

()

Source from the content-addressed store, hash-verified

18 * 初始化存储目录
19 */
20 async initialize(): Promise<void> {
21 try {
22 await fs.mkdir(this.storagePath, { recursive: true });
23 await fs.mkdir(path.join(this.storagePath, 'sessions'), { recursive: true });
24 await fs.mkdir(path.join(this.storagePath, 'conversations'), { recursive: true });
25 } catch (error) {
26 console.warn('警告:无法创建持久化存储目录:', error);
27 }
28 }
29
30 /**
31 * 保存会话上下文

Callers

nothing calls this directly

Calls 1

warnMethod · 0.45

Tested by

no test coverage detected