mirror of
https://github.com/toeverything/AFFiNE.git
synced 2026-08-03 02:20:19 +08:00
refactor(infra): remove old plugin system (#5411)
plugin system need redesign
This commit is contained in:
@@ -23,14 +23,9 @@
|
||||
"main": "./dist/main.js",
|
||||
"devDependencies": {
|
||||
"@affine-test/kit": "workspace:*",
|
||||
"@affine/copilot-plugin": "workspace:*",
|
||||
"@affine/env": "workspace:*",
|
||||
"@affine/hello-world-plugin": "workspace:*",
|
||||
"@affine/image-preview-plugin": "workspace:*",
|
||||
"@affine/native": "workspace:*",
|
||||
"@affine/sdk": "workspace:*",
|
||||
"@affine/templates": "workspace:*",
|
||||
"@affine/vue-hello-world-plugin": "workspace:*",
|
||||
"@blocksuite/blocks": "0.11.0-nightly-202312220916-e3abcbb",
|
||||
"@blocksuite/lit": "0.11.0-nightly-202312220916-e3abcbb",
|
||||
"@blocksuite/presets": "0.11.0-nightly-202312220916-e3abcbb",
|
||||
|
||||
@@ -7,14 +7,7 @@
|
||||
"targets": {
|
||||
"build": {
|
||||
"executor": "nx:run-script",
|
||||
"dependsOn": [
|
||||
{
|
||||
"projects": ["tag:plugin"],
|
||||
"target": "build",
|
||||
"params": "ignore"
|
||||
},
|
||||
"^build"
|
||||
],
|
||||
"dependsOn": ["^build"],
|
||||
"options": {
|
||||
"script": "build"
|
||||
},
|
||||
|
||||
@@ -28,14 +28,7 @@ export const config = (): BuildOptions => {
|
||||
bundle: true,
|
||||
target: `node${NODE_MAJOR_VERSION}`,
|
||||
platform: 'node',
|
||||
external: [
|
||||
'electron',
|
||||
'electron-updater',
|
||||
'@toeverything/plugin-infra',
|
||||
'yjs',
|
||||
'semver',
|
||||
'tinykeys',
|
||||
],
|
||||
external: ['electron', 'electron-updater', 'yjs', 'semver', 'tinykeys'],
|
||||
format: 'cjs',
|
||||
loader: {
|
||||
'.node': 'copy',
|
||||
|
||||
@@ -43,14 +43,6 @@ const cwd = repoRootDir;
|
||||
const { SKIP_NX_CACHE } = process.env;
|
||||
const nxFlag = SKIP_NX_CACHE ? '--skip-nx-cache' : '';
|
||||
|
||||
if (!process.env.SKIP_PLUGIN_BUILD) {
|
||||
spawnSync('yarn', ['build:plugins'], {
|
||||
stdio: 'inherit',
|
||||
env: process.env,
|
||||
cwd,
|
||||
});
|
||||
}
|
||||
|
||||
// step 1: build web dist
|
||||
if (!process.env.SKIP_WEB_BUILD) {
|
||||
spawnSync('yarn', ['nx', 'build', '@affine/core', nxFlag], {
|
||||
|
||||
@@ -22,9 +22,6 @@
|
||||
{
|
||||
"path": "../../common/infra"
|
||||
},
|
||||
{
|
||||
"path": "../../common/sdk"
|
||||
},
|
||||
{
|
||||
"path": "../../common/env"
|
||||
},
|
||||
|
||||
@@ -12,11 +12,7 @@
|
||||
"types": ["node"],
|
||||
"allowJs": true
|
||||
},
|
||||
"include": [
|
||||
"./scripts",
|
||||
"esbuild.main.config.ts",
|
||||
"esbuild.plugin.config.ts"
|
||||
],
|
||||
"include": ["./scripts"],
|
||||
"ts-node": {
|
||||
"esm": true,
|
||||
"experimentalSpecifierResolution": "node"
|
||||
|
||||
Reference in New Issue
Block a user