补全日志,修正缓存问题
This commit is contained in:
parent
0c23b591c4
commit
3ab9d53995
@ -51,11 +51,11 @@ export default router.post(
|
|||||||
}
|
}
|
||||||
const tempSkillsPath = u.getPath(["temp", "skills"]);
|
const tempSkillsPath = u.getPath(["temp", "skills"]);
|
||||||
if (fs.existsSync(tempSkillsPath)) {
|
if (fs.existsSync(tempSkillsPath)) {
|
||||||
fs.cpSync(tempSkillsPath, u.getPath(["skills"]), { recursive: true, force: false });
|
fs.cpSync(tempSkillsPath, u.getPath(["skills"]), { recursive: true });
|
||||||
}
|
}
|
||||||
const tempModelsPath = u.getPath(["temp", "models"]);
|
const tempModelsPath = u.getPath(["temp", "models"]);
|
||||||
if (fs.existsSync(tempModelsPath)) {
|
if (fs.existsSync(tempModelsPath)) {
|
||||||
fs.cpSync(tempModelsPath, u.getPath(["models"]), { recursive: true, force: false });
|
fs.cpSync(tempModelsPath, u.getPath(["models"]), { recursive: true });
|
||||||
}
|
}
|
||||||
fs.rmSync(rootDir, { recursive: true, force: true });
|
fs.rmSync(rootDir, { recursive: true, force: true });
|
||||||
res.status(200).send(success("更新成功,5秒后重启"));
|
res.status(200).send(success("更新成功,5秒后重启"));
|
||||||
|
|||||||
@ -124,4 +124,7 @@ export default (nsp: Namespace) => {
|
|||||||
abortController = null;
|
abortController = null;
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
nsp.on("disconnect", (socket: Socket) => {
|
||||||
|
console.log("[productionAgent] 已断开连接:", socket.id);
|
||||||
|
});
|
||||||
};
|
};
|
||||||
|
|||||||
@ -112,4 +112,7 @@ export default (nsp: Namespace) => {
|
|||||||
abortController = null;
|
abortController = null;
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
nsp.on("disconnect", (socket: Socket) => {
|
||||||
|
console.log("[scriptAgent] 已断开连接:", socket.id);
|
||||||
|
});
|
||||||
};
|
};
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user