From 308031bdcbb02dcdb604a6cfa31f4b1adc6265ea Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=87=8E=E5=A3=B0?= Date: Wed, 9 Oct 2024 17:18:41 +0800 Subject: [PATCH] build: fix build --- Herebyfile.mjs | 10 +++++++++- package.json | 2 +- src/im/types.ts | 2 +- 3 files changed, 11 insertions(+), 3 deletions(-) diff --git a/Herebyfile.mjs b/Herebyfile.mjs index 9fc0421..469f445 100644 --- a/Herebyfile.mjs +++ b/Herebyfile.mjs @@ -63,7 +63,7 @@ export const tscBuild = task({ export const build = task({ name: 'build', - dependencies: [tscBuild, gen], + dependencies: [clean, tscBuild, gen], run: async () => { await runTask(buildNode); await runTask(buildCfWorker); @@ -124,6 +124,14 @@ export const devWorkerPreview = task({ }, }); +export const clean = task({ + name: 'clean', + run: async () => { + await shell('rm -rf libs/*/lib'); + await shell('lerna run clean'); + }, +}); + export default task({ name: 'npm script', hiddenFromTaskList: true, diff --git a/package.json b/package.json index 98f709d..1d3da65 100644 --- a/package.json +++ b/package.json @@ -35,7 +35,7 @@ "extract-fixtures": "tsx scripts/extract-webhook-example.ts", "generate:json-schemas": "node scripts/generate-json-schemas-all.mjs", "postinstall": "yarn build:libs", - "clean": "rm -rf libs/*/lib" + "clean": "hereby" }, "dependencies": { "@hono/node-server": "^1.11.1", diff --git a/src/im/types.ts b/src/im/types.ts index 816dbf1..da5592e 100644 --- a/src/im/types.ts +++ b/src/im/types.ts @@ -1,5 +1,5 @@ import type { DingKVManager, DingUserKVManager } from '@/kv/ding'; -import { IBotAdapter as _IBotAdapter } from '@opensumi/dingtalk-bot/lib/bot/adapter'; +import { IBotAdapter as _IBotAdapter } from '@opensumi/dingtalk-bot'; export interface IBotAdapter extends _IBotAdapter { kvManager: DingKVManager;