mirror of
https://github.com/n8n-io/n8n.git
synced 2026-10-11 22:50:06 +00:00
chore: Create a lightweight version of pnpm reset (#32125)
This commit is contained in:
@@ -59,6 +59,13 @@ You can inspect the last few lines of the build log file to check for errors:
|
||||
tail -n 20 build.log
|
||||
```
|
||||
|
||||
If build outputs or the turbo cache are stale (e.g. after switching branches
|
||||
or worktrees) but dependencies haven't changed, use `pnpm reset` (lightweight
|
||||
by default) for a fast recovery: it cleans build outputs and force-rebuilds
|
||||
(keeping `node_modules` and untracked files). If that doesn't fix your issue,
|
||||
use `pnpm reset --full`, which also wipes untracked files and reinstalls
|
||||
dependencies.
|
||||
|
||||
### Testing
|
||||
- `pnpm test` - Run all tests
|
||||
- `pnpm test:affected` - Runs tests based on what has changed since the last
|
||||
|
||||
@@ -3,8 +3,7 @@
|
||||
"compilerOptions": {
|
||||
"composite": true,
|
||||
"rootDir": "src",
|
||||
"outDir": "dist",
|
||||
"tsBuildInfoFile": "dist/build.tsbuildinfo"
|
||||
"outDir": "dist"
|
||||
},
|
||||
"include": ["src/**/*.ts"],
|
||||
"exclude": ["src/**/__tests__/**"]
|
||||
|
||||
@@ -1,8 +1,7 @@
|
||||
{
|
||||
"extends": "@n8n/typescript-config/tsconfig.common.json",
|
||||
"compilerOptions": {
|
||||
"types": ["node", "vitest/globals"],
|
||||
"tsBuildInfoFile": "dist/typecheck.tsbuildinfo"
|
||||
"types": ["node", "vitest/globals"]
|
||||
},
|
||||
"include": ["src/**/*.ts"],
|
||||
"exclude": ["dist/**/*", "node_modules/**/*"]
|
||||
|
||||
@@ -3,7 +3,6 @@
|
||||
"compilerOptions": {
|
||||
"rootDir": "src",
|
||||
"outDir": "dist/cjs",
|
||||
"tsBuildInfoFile": "dist/cjs/typecheck.tsbuildinfo",
|
||||
"declaration": true
|
||||
},
|
||||
"include": ["src/**/*.ts"],
|
||||
|
||||
@@ -3,8 +3,7 @@
|
||||
"compilerOptions": {
|
||||
"composite": true,
|
||||
"rootDir": "src",
|
||||
"outDir": "dist",
|
||||
"tsBuildInfoFile": "dist/build.tsbuildinfo"
|
||||
"outDir": "dist"
|
||||
},
|
||||
"include": ["src/**/*.ts"],
|
||||
"exclude": ["src/**/__tests__/**", "src/**/*.test.ts"]
|
||||
|
||||
@@ -4,8 +4,7 @@
|
||||
"@n8n/typescript-config/tsconfig.backend.json"
|
||||
],
|
||||
"compilerOptions": {
|
||||
"types": ["node", "vitest/globals"],
|
||||
"tsBuildInfoFile": "dist/typecheck.tsbuildinfo"
|
||||
"types": ["node", "vitest/globals"]
|
||||
},
|
||||
"include": ["src/**/*.ts"]
|
||||
}
|
||||
|
||||
@@ -8,7 +8,6 @@
|
||||
"src/*": ["./src/*"],
|
||||
"src": ["./src"]
|
||||
},
|
||||
"tsBuildInfoFile": "dist/typecheck.tsbuildinfo",
|
||||
"emitDecoratorMetadata": true,
|
||||
"experimentalDecorators": true,
|
||||
"types": ["node", "vitest/globals"]
|
||||
|
||||
@@ -3,8 +3,7 @@
|
||||
"compilerOptions": {
|
||||
"composite": true,
|
||||
"rootDir": "src",
|
||||
"outDir": "dist",
|
||||
"tsBuildInfoFile": "dist/build.tsbuildinfo"
|
||||
"outDir": "dist"
|
||||
},
|
||||
"include": ["src/**/*.ts"],
|
||||
"exclude": ["src/**/__tests__/**", "src/**/test-utils/**", "**/*.test.ts"]
|
||||
|
||||
@@ -11,7 +11,6 @@
|
||||
"paths": {
|
||||
"@/*": ["./src/*"]
|
||||
},
|
||||
"tsBuildInfoFile": "dist/typecheck.tsbuildinfo",
|
||||
"types": ["node", "vitest/globals"]
|
||||
},
|
||||
"include": ["src/**/*.ts", "test/**/*.ts", "evaluations/**/*.ts", "scripts/**/*.ts"]
|
||||
|
||||
@@ -3,8 +3,7 @@
|
||||
"compilerOptions": {
|
||||
"composite": true,
|
||||
"rootDir": "src",
|
||||
"outDir": "dist",
|
||||
"tsBuildInfoFile": "dist/build.tsbuildinfo"
|
||||
"outDir": "dist"
|
||||
},
|
||||
"include": ["src/**/*.ts"],
|
||||
"exclude": ["src/**/__tests__/**"]
|
||||
|
||||
@@ -1,8 +1,7 @@
|
||||
{
|
||||
"extends": "@n8n/typescript-config/tsconfig.common.json",
|
||||
"compilerOptions": {
|
||||
"types": ["node", "vitest/globals"],
|
||||
"tsBuildInfoFile": "dist/typecheck.tsbuildinfo"
|
||||
"types": ["node", "vitest/globals"]
|
||||
},
|
||||
"include": ["src/**/*.ts"],
|
||||
"references": [
|
||||
|
||||
@@ -3,8 +3,7 @@
|
||||
"compilerOptions": {
|
||||
"composite": true,
|
||||
"rootDir": "src",
|
||||
"outDir": "dist",
|
||||
"tsBuildInfoFile": "dist/build.tsbuildinfo"
|
||||
"outDir": "dist"
|
||||
},
|
||||
"include": ["src/**/*.ts"],
|
||||
"exclude": ["src/**/__tests__/**"]
|
||||
|
||||
@@ -2,7 +2,6 @@
|
||||
"extends": "@n8n/typescript-config/tsconfig.common.json",
|
||||
"compilerOptions": {
|
||||
"types": ["node", "vitest/globals"],
|
||||
"tsBuildInfoFile": "dist/typecheck.tsbuildinfo",
|
||||
"experimentalDecorators": true,
|
||||
"emitDecoratorMetadata": true
|
||||
},
|
||||
|
||||
@@ -3,8 +3,7 @@
|
||||
"compilerOptions": {
|
||||
"composite": true,
|
||||
"rootDir": "src",
|
||||
"outDir": "dist",
|
||||
"tsBuildInfoFile": "dist/build.tsbuildinfo"
|
||||
"outDir": "dist"
|
||||
},
|
||||
"include": ["src/**/*.ts"],
|
||||
"exclude": ["src/**/__tests__/**"]
|
||||
|
||||
@@ -2,7 +2,6 @@
|
||||
"extends": "@n8n/typescript-config/tsconfig.common.json",
|
||||
"compilerOptions": {
|
||||
"types": ["node", "jest"],
|
||||
"tsBuildInfoFile": "dist/typecheck.tsbuildinfo",
|
||||
"experimentalDecorators": true,
|
||||
"emitDecoratorMetadata": true
|
||||
},
|
||||
|
||||
@@ -2,8 +2,7 @@
|
||||
"extends": ["./tsconfig.json", "@n8n/typescript-config/tsconfig.build.json"],
|
||||
"compilerOptions": {
|
||||
"rootDir": "src",
|
||||
"outDir": "dist",
|
||||
"tsBuildInfoFile": "dist/build.tsbuildinfo"
|
||||
"outDir": "dist"
|
||||
},
|
||||
"include": ["src/**/*.ts"]
|
||||
}
|
||||
|
||||
@@ -3,8 +3,7 @@
|
||||
"compilerOptions": {
|
||||
"composite": true,
|
||||
"rootDir": "src",
|
||||
"outDir": "dist",
|
||||
"tsBuildInfoFile": "dist/build.tsbuildinfo"
|
||||
"outDir": "dist"
|
||||
},
|
||||
"include": ["src/**/*.ts"],
|
||||
"exclude": ["src/**/__tests__/**", "src/**/*.test.ts"]
|
||||
|
||||
@@ -1,8 +1,7 @@
|
||||
{
|
||||
"extends": "@n8n/typescript-config/tsconfig.common.json",
|
||||
"compilerOptions": {
|
||||
"types": ["node", "vitest/globals"],
|
||||
"tsBuildInfoFile": "dist/typecheck.tsbuildinfo"
|
||||
"types": ["node", "vitest/globals"]
|
||||
},
|
||||
"include": ["src/**/*.ts"],
|
||||
"references": [{ "path": "../api-types/tsconfig.build.json" }]
|
||||
|
||||
@@ -4,8 +4,7 @@
|
||||
"composite": true,
|
||||
"rootDir": "src",
|
||||
"outDir": "dist",
|
||||
"declaration": true,
|
||||
"tsBuildInfoFile": "dist/build.tsbuildinfo"
|
||||
"declaration": true
|
||||
},
|
||||
"include": ["src/**/*.ts"],
|
||||
"exclude": ["src/**/__tests__/**", "src/**/*.test.ts"]
|
||||
|
||||
@@ -3,8 +3,7 @@
|
||||
"compilerOptions": {
|
||||
"composite": true,
|
||||
"rootDir": "src",
|
||||
"outDir": "dist",
|
||||
"tsBuildInfoFile": "dist/build.tsbuildinfo"
|
||||
"outDir": "dist"
|
||||
},
|
||||
"include": ["src/**/*.ts"],
|
||||
"exclude": ["test/**"]
|
||||
|
||||
@@ -4,8 +4,7 @@
|
||||
"types": ["node", "vitest/globals"],
|
||||
"paths": {
|
||||
"@/*": ["./src/*"]
|
||||
},
|
||||
"tsBuildInfoFile": "dist/typecheck.tsbuildinfo"
|
||||
}
|
||||
},
|
||||
"include": ["src/**/*.ts", "test/**/*.ts"]
|
||||
}
|
||||
|
||||
@@ -2,8 +2,7 @@
|
||||
"extends": ["./tsconfig.json", "@n8n/typescript-config/tsconfig.build.json"],
|
||||
"compilerOptions": {
|
||||
"rootDir": "src",
|
||||
"outDir": "dist",
|
||||
"tsBuildInfoFile": "dist/build.tsbuildinfo"
|
||||
"outDir": "dist"
|
||||
},
|
||||
"include": ["src/**/*.ts"],
|
||||
"exclude": ["test/**"]
|
||||
|
||||
@@ -2,7 +2,6 @@
|
||||
"extends": "@n8n/typescript-config/tsconfig.common.json",
|
||||
"compilerOptions": {
|
||||
"rootDir": ".",
|
||||
"tsBuildInfoFile": "dist/typecheck.tsbuildinfo",
|
||||
"types": ["node", "jest"]
|
||||
},
|
||||
"include": ["src/**/*.ts", "test/**/*.ts"]
|
||||
|
||||
@@ -2,8 +2,7 @@
|
||||
"extends": ["./tsconfig.json", "@n8n/typescript-config/tsconfig.build.json"],
|
||||
"compilerOptions": {
|
||||
"rootDir": "src",
|
||||
"outDir": "dist",
|
||||
"tsBuildInfoFile": "dist/build.tsbuildinfo"
|
||||
"outDir": "dist"
|
||||
},
|
||||
"include": ["src/**/*.ts"],
|
||||
"exclude": ["test/**"]
|
||||
|
||||
@@ -2,7 +2,6 @@
|
||||
"extends": "@n8n/typescript-config/tsconfig.common.json",
|
||||
"compilerOptions": {
|
||||
"rootDir": ".",
|
||||
"tsBuildInfoFile": "dist/typecheck.tsbuildinfo",
|
||||
"types": ["node", "jest"]
|
||||
},
|
||||
"include": ["src/**/*.ts", "test/**/*.ts"]
|
||||
|
||||
@@ -3,8 +3,7 @@
|
||||
"compilerOptions": {
|
||||
"composite": true,
|
||||
"rootDir": "src",
|
||||
"outDir": "dist",
|
||||
"tsBuildInfoFile": "dist/build.tsbuildinfo"
|
||||
"outDir": "dist"
|
||||
},
|
||||
"include": ["src/**/*.ts"],
|
||||
"exclude": ["src/**/__tests__/**", "src/**/__mocks__/**", "src/**/*.test.ts", "src/**/*.spec.ts"]
|
||||
|
||||
@@ -1,8 +1,7 @@
|
||||
{
|
||||
"extends": "@n8n/typescript-config/tsconfig.common.json",
|
||||
"compilerOptions": {
|
||||
"types": ["node", "vitest/globals"],
|
||||
"tsBuildInfoFile": "dist/typecheck.tsbuildinfo"
|
||||
"types": ["node", "vitest/globals"]
|
||||
},
|
||||
"include": ["src/**/*.ts"]
|
||||
}
|
||||
|
||||
@@ -3,8 +3,7 @@
|
||||
"compilerOptions": {
|
||||
"composite": true,
|
||||
"rootDir": "src",
|
||||
"outDir": "dist",
|
||||
"tsBuildInfoFile": "dist/build.tsbuildinfo"
|
||||
"outDir": "dist"
|
||||
},
|
||||
"include": ["src/**/*.ts"],
|
||||
"exclude": ["test/**", "src/**/__tests__/**"]
|
||||
|
||||
@@ -4,8 +4,7 @@
|
||||
"emitDecoratorMetadata": true,
|
||||
"experimentalDecorators": true,
|
||||
"strictPropertyInitialization": false,
|
||||
"types": ["node", "vitest/globals"],
|
||||
"tsBuildInfoFile": "dist/typecheck.tsbuildinfo"
|
||||
"types": ["node", "vitest/globals"]
|
||||
},
|
||||
"include": ["src/**/*.ts", "test/**/*.ts"],
|
||||
"references": [{ "path": "../di/tsconfig.build.json" }]
|
||||
|
||||
@@ -3,8 +3,7 @@
|
||||
"compilerOptions": {
|
||||
"composite": true,
|
||||
"rootDir": "src",
|
||||
"outDir": "dist",
|
||||
"tsBuildInfoFile": "dist/build.tsbuildinfo"
|
||||
"outDir": "dist"
|
||||
},
|
||||
"include": ["src/**/*.ts"]
|
||||
}
|
||||
|
||||
@@ -2,7 +2,6 @@
|
||||
"extends": "@n8n/typescript-config/tsconfig.common.json",
|
||||
"compilerOptions": {
|
||||
"types": ["node", "jest"],
|
||||
"tsBuildInfoFile": "dist/typecheck.tsbuildinfo",
|
||||
"experimentalDecorators": true,
|
||||
"emitDecoratorMetadata": true
|
||||
},
|
||||
|
||||
@@ -3,8 +3,7 @@
|
||||
"compilerOptions": {
|
||||
"composite": true,
|
||||
"rootDir": "src",
|
||||
"outDir": "dist",
|
||||
"tsBuildInfoFile": "dist/build.tsbuildinfo"
|
||||
"outDir": "dist"
|
||||
},
|
||||
"include": ["src/**/*.ts"],
|
||||
"exclude": ["src/**/*.test.ts", "src/__tests__/**"]
|
||||
|
||||
@@ -1,8 +1,7 @@
|
||||
{
|
||||
"extends": "@n8n/typescript-config/tsconfig.common.json",
|
||||
"compilerOptions": {
|
||||
"types": ["node", "vitest/globals"],
|
||||
"tsBuildInfoFile": "dist/typecheck.tsbuildinfo"
|
||||
"types": ["node", "vitest/globals"]
|
||||
},
|
||||
"include": ["src/**/*.ts"]
|
||||
}
|
||||
|
||||
@@ -3,8 +3,7 @@
|
||||
"compilerOptions": {
|
||||
"composite": true,
|
||||
"rootDir": "src",
|
||||
"outDir": "dist",
|
||||
"tsBuildInfoFile": "dist/build.tsbuildinfo"
|
||||
"outDir": "dist"
|
||||
},
|
||||
"include": ["src/**/*.ts"],
|
||||
"exclude": ["src/**/__tests__/**", "src/**/*.test.ts", "src/**/*.spec.ts"]
|
||||
|
||||
@@ -2,7 +2,6 @@
|
||||
"extends": "@n8n/typescript-config/tsconfig.common.json",
|
||||
"compilerOptions": {
|
||||
"types": ["node", "vitest/globals"],
|
||||
"tsBuildInfoFile": "dist/typecheck.tsbuildinfo",
|
||||
"experimentalDecorators": true,
|
||||
"emitDecoratorMetadata": true,
|
||||
|
||||
|
||||
@@ -3,8 +3,7 @@
|
||||
"compilerOptions": {
|
||||
"composite": true,
|
||||
"rootDir": "src",
|
||||
"outDir": "dist",
|
||||
"tsBuildInfoFile": "dist/build.tsbuildinfo"
|
||||
"outDir": "dist"
|
||||
},
|
||||
"include": ["src/**/*.ts"],
|
||||
"exclude": ["src/**/__tests__/**"]
|
||||
|
||||
@@ -2,7 +2,6 @@
|
||||
"extends": "@n8n/typescript-config/tsconfig.common.json",
|
||||
"compilerOptions": {
|
||||
"types": ["node", "vitest/globals"],
|
||||
"tsBuildInfoFile": "dist/typecheck.tsbuildinfo",
|
||||
"experimentalDecorators": true,
|
||||
"emitDecoratorMetadata": true
|
||||
},
|
||||
|
||||
@@ -3,8 +3,7 @@
|
||||
"compilerOptions": {
|
||||
"composite": true,
|
||||
"rootDir": "src",
|
||||
"outDir": "dist",
|
||||
"tsBuildInfoFile": "dist/build.tsbuildinfo"
|
||||
"outDir": "dist"
|
||||
},
|
||||
"include": ["src/**/*.ts"],
|
||||
"exclude": ["src/**/__tests__/**"]
|
||||
|
||||
@@ -2,7 +2,6 @@
|
||||
"extends": "@n8n/typescript-config/tsconfig.common.json",
|
||||
"compilerOptions": {
|
||||
"types": ["node", "vitest/globals"],
|
||||
"tsBuildInfoFile": "dist/typecheck.tsbuildinfo",
|
||||
"experimentalDecorators": true,
|
||||
"emitDecoratorMetadata": true
|
||||
},
|
||||
|
||||
@@ -3,8 +3,7 @@
|
||||
"compilerOptions": {
|
||||
"composite": true,
|
||||
"rootDir": "src",
|
||||
"outDir": "dist",
|
||||
"tsBuildInfoFile": "dist/build.tsbuildinfo"
|
||||
"outDir": "dist"
|
||||
},
|
||||
"include": ["src/**/*.ts"],
|
||||
"exclude": ["src/**/__tests__/**", "**/*.test.ts"]
|
||||
|
||||
@@ -7,7 +7,6 @@
|
||||
"target": "es2023",
|
||||
"lib": ["es2023"],
|
||||
"types": ["node"],
|
||||
"tsBuildInfoFile": "dist/typecheck.tsbuildinfo",
|
||||
"experimentalDecorators": true,
|
||||
"emitDecoratorMetadata": true
|
||||
},
|
||||
|
||||
@@ -3,8 +3,7 @@
|
||||
"compilerOptions": {
|
||||
"composite": true,
|
||||
"rootDir": "src",
|
||||
"outDir": "dist",
|
||||
"tsBuildInfoFile": "dist/build.tsbuildinfo"
|
||||
"outDir": "dist"
|
||||
},
|
||||
"include": ["src/**/*.ts"],
|
||||
"exclude": ["src/**/__tests__/**"]
|
||||
|
||||
@@ -2,7 +2,6 @@
|
||||
"extends": "@n8n/typescript-config/tsconfig.common.json",
|
||||
"compilerOptions": {
|
||||
"types": ["node", "jest"],
|
||||
"tsBuildInfoFile": "dist/typecheck.tsbuildinfo",
|
||||
"experimentalDecorators": true,
|
||||
"emitDecoratorMetadata": true
|
||||
},
|
||||
|
||||
@@ -2,8 +2,7 @@
|
||||
"extends": ["./tsconfig.json", "@n8n/typescript-config/modern/tsconfig.cjs.json"],
|
||||
"compilerOptions": {
|
||||
"rootDir": "src",
|
||||
"outDir": "dist/cjs",
|
||||
"tsBuildInfoFile": "dist/cjs/build.tsbuildinfo"
|
||||
"outDir": "dist/cjs"
|
||||
},
|
||||
"include": ["src/**/*.ts"],
|
||||
"exclude": ["node_modules", "dist", "src/**/__tests__/**"]
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
"compilerOptions": {
|
||||
"composite": true,
|
||||
"declaration": true,
|
||||
"tsBuildInfoFile": "./node_modules/.tmp/tsconfig.backend.tsbuildinfo"
|
||||
"tsBuildInfoFile": "${configDir}/dist/backend.tsbuildinfo"
|
||||
},
|
||||
"include": ["src/backend/**/*.ts"]
|
||||
}
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
"compilerOptions": {
|
||||
"composite": true,
|
||||
"declaration": true,
|
||||
"tsBuildInfoFile": "./node_modules/.tmp/tsconfig.backend.tsbuildinfo"
|
||||
"tsBuildInfoFile": "${configDir}/dist/common.tsbuildinfo"
|
||||
},
|
||||
"include": ["src/*.ts"]
|
||||
}
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
"compilerOptions": {
|
||||
"composite": true,
|
||||
"declaration": true,
|
||||
"tsBuildInfoFile": "./node_modules/.tmp/tsconfig.frontend.tsbuildinfo"
|
||||
"tsBuildInfoFile": "${configDir}/dist/frontend.tsbuildinfo"
|
||||
},
|
||||
"include": ["src/frontend/**/*.ts", "src/frontend/**/*.vue"]
|
||||
}
|
||||
|
||||
@@ -3,8 +3,7 @@
|
||||
"compilerOptions": {
|
||||
"composite": true,
|
||||
"rootDir": "src",
|
||||
"outDir": "dist",
|
||||
"tsBuildInfoFile": "dist/build.tsbuildinfo"
|
||||
"outDir": "dist"
|
||||
},
|
||||
"include": ["src/**/*.ts"],
|
||||
"exclude": ["src/**/*.test.ts"]
|
||||
|
||||
@@ -1,8 +1,7 @@
|
||||
{
|
||||
"extends": "@n8n/typescript-config/tsconfig.common.json",
|
||||
"compilerOptions": {
|
||||
"types": ["node", "vite/client", "vitest/globals"],
|
||||
"tsBuildInfoFile": "dist/typecheck.tsbuildinfo"
|
||||
"types": ["node", "vite/client", "vitest/globals"]
|
||||
},
|
||||
"include": ["src/**/*.ts"]
|
||||
}
|
||||
|
||||
@@ -3,8 +3,7 @@
|
||||
"compilerOptions": {
|
||||
"composite": true,
|
||||
"rootDir": "src",
|
||||
"outDir": "dist",
|
||||
"tsBuildInfoFile": "dist/build.tsbuildinfo"
|
||||
"outDir": "dist"
|
||||
},
|
||||
"include": ["src/**/*.ts"],
|
||||
"exclude": ["src/**/__tests__/**", "src/**/test-utils/**", "**/*.test.ts"]
|
||||
|
||||
@@ -11,7 +11,6 @@
|
||||
"paths": {
|
||||
"@/*": ["./src/*"]
|
||||
},
|
||||
"tsBuildInfoFile": "dist/typecheck.tsbuildinfo",
|
||||
"types": ["node", "vitest/globals"]
|
||||
},
|
||||
"include": ["src/**/*.ts"]
|
||||
|
||||
@@ -5,8 +5,7 @@
|
||||
"types": ["node", "vitest/globals"],
|
||||
"lib": ["es2021", "dom"],
|
||||
"moduleResolution": "nodenext",
|
||||
"module": "nodenext",
|
||||
"tsBuildInfoFile": "dist/typecheck.tsbuildinfo"
|
||||
"module": "nodenext"
|
||||
},
|
||||
"include": ["src/**/*.ts"]
|
||||
}
|
||||
|
||||
@@ -6,8 +6,7 @@
|
||||
"moduleResolution": "node",
|
||||
"noEmit": false,
|
||||
"rootDir": "src",
|
||||
"outDir": "dist",
|
||||
"tsBuildInfoFile": "dist/build.tsbuildinfo"
|
||||
"outDir": "dist"
|
||||
},
|
||||
"include": ["src/server/**/*.ts", "src/apps-manifest.ts", "src/telemetry-contract.ts"],
|
||||
"exclude": ["src/**/*.test.ts"]
|
||||
|
||||
@@ -3,8 +3,7 @@
|
||||
"compilerOptions": {
|
||||
"composite": true,
|
||||
"rootDir": "src",
|
||||
"outDir": "dist",
|
||||
"tsBuildInfoFile": "dist/build.tsbuildinfo"
|
||||
"outDir": "dist"
|
||||
},
|
||||
"include": ["src/**/*.ts"],
|
||||
"exclude": ["src/**/__tests__/**", "src/**/*.test.ts", "src/**/test-helpers.ts"]
|
||||
|
||||
@@ -1,8 +1,7 @@
|
||||
{
|
||||
"extends": "@n8n/typescript-config/tsconfig.common.json",
|
||||
"compilerOptions": {
|
||||
"types": ["node", "vitest/globals"],
|
||||
"tsBuildInfoFile": "dist/typecheck.tsbuildinfo"
|
||||
"types": ["node", "vitest/globals"]
|
||||
},
|
||||
"include": ["src/**/*.ts"]
|
||||
}
|
||||
|
||||
@@ -4,8 +4,7 @@
|
||||
"composite": true,
|
||||
"rootDir": "src",
|
||||
"outDir": "dist",
|
||||
"declaration": true,
|
||||
"tsBuildInfoFile": "dist/build.tsbuildinfo"
|
||||
"declaration": true
|
||||
},
|
||||
"include": ["src/**/*.ts"],
|
||||
"exclude": [
|
||||
|
||||
@@ -8,7 +8,6 @@
|
||||
"@utils/*": ["./utils/*"],
|
||||
"@nodes-testing/*": ["../../core/nodes-testing/*"]
|
||||
},
|
||||
"tsBuildInfoFile": "dist/typecheck.tsbuildinfo",
|
||||
"emitDecoratorMetadata": true,
|
||||
"experimentalDecorators": true,
|
||||
"types": ["node", "vitest/globals"],
|
||||
|
||||
@@ -3,8 +3,7 @@
|
||||
"compilerOptions": {
|
||||
"composite": true,
|
||||
"rootDir": "src",
|
||||
"outDir": "dist",
|
||||
"tsBuildInfoFile": "dist/build.tsbuildinfo"
|
||||
"outDir": "dist"
|
||||
},
|
||||
"include": ["src/**/*.ts"],
|
||||
"exclude": ["src/**/__tests__/**"]
|
||||
|
||||
@@ -4,8 +4,7 @@
|
||||
"types": ["node", "vitest/globals"],
|
||||
"paths": {
|
||||
"@/*": ["./src/*"]
|
||||
},
|
||||
"tsBuildInfoFile": "dist/typecheck.tsbuildinfo"
|
||||
}
|
||||
},
|
||||
"include": ["src/**/*.ts"]
|
||||
}
|
||||
|
||||
@@ -3,8 +3,7 @@
|
||||
"compilerOptions": {
|
||||
"composite": true,
|
||||
"rootDir": "src",
|
||||
"outDir": "dist",
|
||||
"tsBuildInfoFile": "dist/build.tsbuildinfo"
|
||||
"outDir": "dist"
|
||||
},
|
||||
"include": ["src/**/*.ts"],
|
||||
"exclude": ["test/**", "src/**/__tests__/**"]
|
||||
|
||||
@@ -4,8 +4,7 @@
|
||||
"emitDecoratorMetadata": true,
|
||||
"experimentalDecorators": true,
|
||||
"strictPropertyInitialization": false,
|
||||
"types": ["node", "vitest/globals"],
|
||||
"tsBuildInfoFile": "dist/typecheck.tsbuildinfo"
|
||||
"types": ["node", "vitest/globals"]
|
||||
},
|
||||
"include": ["src/**/*.ts", "test/**/*.ts"],
|
||||
"references": [{ "path": "../di/tsconfig.build.json" }]
|
||||
|
||||
@@ -3,8 +3,7 @@
|
||||
"compilerOptions": {
|
||||
"composite": true,
|
||||
"rootDir": "src",
|
||||
"outDir": "dist",
|
||||
"tsBuildInfoFile": "dist/build.tsbuildinfo"
|
||||
"outDir": "dist"
|
||||
},
|
||||
"include": ["src/**/*.ts"],
|
||||
"exclude": ["src/**/__tests__/**"]
|
||||
|
||||
@@ -9,8 +9,7 @@
|
||||
"types": ["node", "vitest/globals"],
|
||||
"paths": {
|
||||
"@/*": ["./src/*"]
|
||||
},
|
||||
"tsBuildInfoFile": "dist/typecheck.tsbuildinfo"
|
||||
}
|
||||
},
|
||||
"include": ["src/**/*.ts"]
|
||||
}
|
||||
|
||||
@@ -20,6 +20,7 @@
|
||||
"declaration": true,
|
||||
"sourceMap": true,
|
||||
"skipLibCheck": true,
|
||||
"tsBuildInfoFile": "dist/typecheck.tsbuildinfo",
|
||||
"types": ["node", "vitest/globals"]
|
||||
},
|
||||
"include": ["src/**/*.ts", "test/**/*.ts"],
|
||||
|
||||
@@ -5,6 +5,7 @@
|
||||
"module": "umd",
|
||||
"moduleResolution": "node",
|
||||
"verbatimModuleSyntax": false,
|
||||
"resolveJsonModule": false
|
||||
"resolveJsonModule": false,
|
||||
"tsBuildInfoFile": "${configDir}/dist/cjs/build.tsbuildinfo"
|
||||
}
|
||||
}
|
||||
|
||||
@@ -24,6 +24,7 @@
|
||||
"composite": true,
|
||||
"declarationMap": true,
|
||||
"sourceMap": true,
|
||||
"tsBuildInfoFile": "${configDir}/dist/typecheck.tsbuildinfo",
|
||||
|
||||
"lib": ["es2022", "dom", "dom.iterable"]
|
||||
}
|
||||
|
||||
@@ -3,7 +3,8 @@
|
||||
"types": ["node"],
|
||||
"noUnusedLocals": false,
|
||||
"noUnusedParameters": false,
|
||||
"declaration": true
|
||||
"declaration": true,
|
||||
"tsBuildInfoFile": "${configDir}/dist/build.tsbuildinfo"
|
||||
},
|
||||
"tsc-alias": {
|
||||
"replacers": {
|
||||
|
||||
@@ -21,7 +21,8 @@
|
||||
"incremental": true,
|
||||
"declaration": false,
|
||||
"sourceMap": true,
|
||||
"skipLibCheck": true
|
||||
"skipLibCheck": true,
|
||||
"tsBuildInfoFile": "${configDir}/dist/typecheck.tsbuildinfo"
|
||||
},
|
||||
"files": ["../../../node_modules/jest-expect-message/types/index.d.ts"]
|
||||
}
|
||||
|
||||
@@ -3,8 +3,7 @@
|
||||
"compilerOptions": {
|
||||
"composite": true,
|
||||
"rootDir": ".",
|
||||
"outDir": "dist",
|
||||
"tsBuildInfoFile": "dist/build.tsbuildinfo"
|
||||
"outDir": "dist"
|
||||
},
|
||||
"include": ["**/*.ts"],
|
||||
"exclude": ["dist", "**/*.test.ts"]
|
||||
|
||||
@@ -3,8 +3,7 @@
|
||||
"compilerOptions": {
|
||||
"types": ["node"],
|
||||
"module": "ESNext",
|
||||
"moduleResolution": "bundler",
|
||||
"tsBuildInfoFile": "dist/typecheck.tsbuildinfo"
|
||||
"moduleResolution": "bundler"
|
||||
},
|
||||
"include": ["**/*.ts"],
|
||||
"exclude": ["dist"]
|
||||
|
||||
@@ -3,8 +3,7 @@
|
||||
"compilerOptions": {
|
||||
"composite": true,
|
||||
"rootDir": "src",
|
||||
"outDir": "dist",
|
||||
"tsBuildInfoFile": "dist/build.tsbuildinfo"
|
||||
"outDir": "dist"
|
||||
},
|
||||
"include": ["src/**/*.ts"],
|
||||
"exclude": ["src/**/__tests__/**", "src/**/*.test.ts"]
|
||||
|
||||
@@ -1,8 +1,7 @@
|
||||
{
|
||||
"extends": "@n8n/typescript-config/tsconfig.common.json",
|
||||
"compilerOptions": {
|
||||
"types": ["node", "vitest/globals"],
|
||||
"tsBuildInfoFile": "dist/typecheck.tsbuildinfo"
|
||||
"types": ["node", "vitest/globals"]
|
||||
},
|
||||
"include": ["src/**/*.ts"],
|
||||
"references": [{ "path": "../../workflow/tsconfig.build.esm.json" }]
|
||||
|
||||
@@ -2,8 +2,7 @@
|
||||
"extends": ["./tsconfig.json", "@n8n/typescript-config/tsconfig.build.json"],
|
||||
"compilerOptions": {
|
||||
"rootDir": "src",
|
||||
"outDir": "dist",
|
||||
"tsBuildInfoFile": "dist/build.tsbuildinfo"
|
||||
"outDir": "dist"
|
||||
},
|
||||
"include": ["src/**/*.ts"],
|
||||
"exclude": ["test/**", "src/**/__tests__/**"]
|
||||
|
||||
@@ -12,7 +12,6 @@
|
||||
"@test/*": ["./test/shared/*"],
|
||||
"@test-integration/*": ["./test/integration/shared/*"]
|
||||
},
|
||||
"tsBuildInfoFile": "dist/typecheck.tsbuildinfo",
|
||||
"strict": true,
|
||||
"strictFunctionTypes": false,
|
||||
"strictPropertyInitialization": false,
|
||||
|
||||
@@ -3,8 +3,7 @@
|
||||
"compilerOptions": {
|
||||
"composite": true,
|
||||
"rootDir": "src",
|
||||
"outDir": "dist",
|
||||
"tsBuildInfoFile": "dist/build.tsbuildinfo"
|
||||
"outDir": "dist"
|
||||
},
|
||||
"include": ["src/**/*.ts"],
|
||||
"exclude": ["test/**", "src/**/__tests__/**"]
|
||||
|
||||
@@ -9,7 +9,6 @@
|
||||
"@/*": ["./src/*"],
|
||||
"@test/*": ["./test/*"]
|
||||
},
|
||||
"tsBuildInfoFile": "dist/typecheck.tsbuildinfo",
|
||||
"emitDecoratorMetadata": true,
|
||||
"experimentalDecorators": true,
|
||||
"types": ["node", "vitest/globals"],
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
{
|
||||
"extends": "@n8n/typescript-config/tsconfig.common.json",
|
||||
"compilerOptions": {
|
||||
"tsBuildInfoFile": "./node_modules/.tmp/tsconfig.app.tsbuildinfo",
|
||||
"moduleResolution": "bundler",
|
||||
"module": "esnext"
|
||||
},
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
{
|
||||
"extends": "@vue/tsconfig/tsconfig.dom.json",
|
||||
"compilerOptions": {
|
||||
"tsBuildInfoFile": "./node_modules/.tmp/tsconfig.app.tsbuildinfo"
|
||||
"tsBuildInfoFile": "dist/tsconfig.app.tsbuildinfo"
|
||||
},
|
||||
"include": ["src/frontend/**/*.ts", "src/frontend/**/*.vue"]
|
||||
}
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
{
|
||||
"compilerOptions": {
|
||||
"composite": true,
|
||||
"tsBuildInfoFile": "./node_modules/.tmp/tsconfig.node.tsbuildinfo",
|
||||
"target": "ES2022",
|
||||
"lib": ["ES2023"],
|
||||
"module": "ESNext",
|
||||
@@ -13,7 +12,8 @@
|
||||
"noUnusedLocals": true,
|
||||
"noUnusedParameters": true,
|
||||
"noFallthroughCasesInSwitch": true,
|
||||
"noUncheckedSideEffectImports": true
|
||||
"noUncheckedSideEffectImports": true,
|
||||
"tsBuildInfoFile": "dist/tsconfig.vite.tsbuildinfo"
|
||||
},
|
||||
"include": ["vite.config.ts", "tsdown.config.ts"]
|
||||
}
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
{
|
||||
"extends": "@n8n/typescript-config/tsconfig.frontend.json",
|
||||
"compilerOptions": {
|
||||
"tsBuildInfoFile": "./node_modules/.tmp/tsconfig.app.tsbuildinfo",
|
||||
"tsBuildInfoFile": "./dist/tsconfig.app.tsbuildinfo",
|
||||
"rootDirs": [".", "../composables/src"],
|
||||
"noEmit": true,
|
||||
"moduleResolution": "bundler",
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"compilerOptions": {
|
||||
"tsBuildInfoFile": "./node_modules/.tmp/tsconfig.node.tsbuildinfo",
|
||||
"tsBuildInfoFile": "./dist/tsconfig.node.tsbuildinfo",
|
||||
"target": "ES2023",
|
||||
"lib": ["ES2023"],
|
||||
"module": "ESNext",
|
||||
|
||||
@@ -221,7 +221,7 @@ export default mergeConfig(
|
||||
base: publicPath,
|
||||
envPrefix: ['VUE', 'N8N_ENV_FEAT'],
|
||||
css: {
|
||||
preprocessorMaxWorkers: true,
|
||||
preprocessorMaxWorkers: 2,
|
||||
preprocessorOptions: {
|
||||
scss: {
|
||||
additionalData: [
|
||||
|
||||
@@ -6,7 +6,6 @@
|
||||
"compilerOptions": {
|
||||
"outDir": "dist",
|
||||
"preserveSymlinks": true,
|
||||
"tsBuildInfoFile": "dist/build.tsbuildinfo",
|
||||
// TODO: remove all options below this line
|
||||
"useUnknownInCatchVariables": false
|
||||
},
|
||||
|
||||
@@ -2,8 +2,7 @@
|
||||
"extends": ["./tsconfig.json", "@n8n/typescript-config/modern/tsconfig.cjs.json"],
|
||||
"compilerOptions": {
|
||||
"outDir": "dist",
|
||||
"module": "commonjs",
|
||||
"tsBuildInfoFile": "dist/typecheck.tsbuildinfo"
|
||||
"module": "commonjs"
|
||||
},
|
||||
"include": [
|
||||
"credentials/**/*.ts",
|
||||
|
||||
@@ -7,7 +7,6 @@
|
||||
"@utils/*": ["./utils/*"],
|
||||
"@nodes-testing/*": ["../core/nodes-testing/*"]
|
||||
},
|
||||
"tsBuildInfoFile": "dist/typecheck.tsbuildinfo",
|
||||
|
||||
"emitDecoratorMetadata": true,
|
||||
"experimentalDecorators": true,
|
||||
|
||||
@@ -2,8 +2,7 @@
|
||||
"extends": ["./tsconfig.json", "@n8n/typescript-config/modern/tsconfig.cjs.json"],
|
||||
"compilerOptions": {
|
||||
"rootDir": "src",
|
||||
"outDir": "dist/cjs",
|
||||
"tsBuildInfoFile": "dist/cjs/typecheck.tsbuildinfo"
|
||||
"outDir": "dist/cjs"
|
||||
},
|
||||
"include": ["src/**/*.ts"],
|
||||
"exclude": ["node_modules"]
|
||||
|
||||
+78
-3
@@ -1,9 +1,79 @@
|
||||
// Resets the repository by deleting all untracked files except for few exceptions.
|
||||
// Resets the repository's build state. Lightweight by default (refresh build
|
||||
// outputs/caches only); pass `--full` to also delete all untracked files
|
||||
// (except a few exceptions) and reinstall dependencies.
|
||||
import { $, argv, echo, fs } from 'zx';
|
||||
|
||||
let failedOnce = false;
|
||||
$.verbose = true;
|
||||
process.env.FORCE_COLOR = '1';
|
||||
|
||||
// By default this runs the lightweight reset: only refresh build
|
||||
// outputs/caches. Keeps node_modules and all untracked files, skips the
|
||||
// confirmation prompt. Use this when build outputs or the turbo cache are
|
||||
// stale (e.g. after switching branches or worktrees) but dependencies haven't
|
||||
// changed. `--no-install` skips the dependency reconcile step.
|
||||
//
|
||||
// `--full`: the heavy reset. Deletes all untracked files (except a few
|
||||
// exceptions), wipes node_modules, reinstalls dependencies, then rebuilds.
|
||||
// Reach for this only when the lightweight reset didn't fix your issue.
|
||||
const full = argv.full;
|
||||
|
||||
// `--mem <MB>` raises the V8 old-space cap for each build process via
|
||||
// NODE_OPTIONS, which turbo passes through to the per-package builds. Bump it if
|
||||
// a build runs out of memory (e.g. the JS `sass` compiler). Default 8192.
|
||||
// Note: this only helps JS-heap OOMs — native `sass-embedded` compilation runs
|
||||
// in a separate Dart process that this limit does not bound; if that OOMs,
|
||||
// lower build concurrency or a better orchestration is needed.
|
||||
const mem = argv.mem ? Number(argv.mem) : 8192;
|
||||
if (!Number.isInteger(mem) || mem <= 0) {
|
||||
echo('❌ --mem must be a positive integer (MB)');
|
||||
process.exit(1);
|
||||
}
|
||||
const nodeOptions = process.env.NODE_OPTIONS
|
||||
? `${process.env.NODE_OPTIONS} --max-old-space-size=${mem}`
|
||||
: `--max-old-space-size=${mem}`;
|
||||
const buildEnv = { ...process.env, NODE_OPTIONS: nodeOptions };
|
||||
|
||||
async function buildWithSingleRetry() {
|
||||
const res = await $({ env: buildEnv })`pnpm build`.nothrow();
|
||||
if (res.exitCode !== 0) {
|
||||
failedOnce = true;
|
||||
// Build failed on the initial full-repo build, most likely due to dart-sass being evicted.
|
||||
// Re-trigger build, already built items are fast-tracked by turbo cache, and building continues
|
||||
console.log("! Build failed, most likely due to memory pressure. Retrying build");
|
||||
await $({ env: buildEnv })`pnpm build`;
|
||||
}
|
||||
}
|
||||
|
||||
if (!full) {
|
||||
const runInstall = argv.install !== false;
|
||||
|
||||
echo(
|
||||
'⚡ Lightweight reset: keeping node_modules and untracked files, refreshing build outputs only.',
|
||||
);
|
||||
|
||||
echo('🧹 Cleaning build outputs (dist, .turbo)...');
|
||||
await $`pnpm clean`;
|
||||
|
||||
if (runInstall) {
|
||||
echo('⏬ Reconciling dependencies (pnpm install)...');
|
||||
await $`pnpm install`;
|
||||
}
|
||||
|
||||
echo(`🏗️ Rebuilding (--max-old-space-size=${mem})...`);
|
||||
await buildWithSingleRetry();
|
||||
|
||||
if (failedOnce) {
|
||||
console.log("🟢 The build script failed once, but was able to recover successfully.")
|
||||
}
|
||||
|
||||
echo('');
|
||||
echo('✅ Lightweight reset done!');
|
||||
echo(
|
||||
"💡 Still seeing issues? Run `pnpm reset --full` for a full reset (wipes untracked files & node_modules, then reinstalls and rebuilds).",
|
||||
);
|
||||
process.exit(0);
|
||||
}
|
||||
const excludePatterns = ['/.vscode/', '/.idea/', '.env', '/.claude/'];
|
||||
const excludeFlags = excludePatterns.map((exclude) => ['-e', exclude]).flat();
|
||||
|
||||
@@ -30,5 +100,10 @@ fs.removeSync('node_modules');
|
||||
echo('⏬ Running pnpm install...');
|
||||
await $`pnpm install`;
|
||||
|
||||
echo('🏗️ Running pnpm build...');
|
||||
await $`pnpm build --concurrency=50%`;
|
||||
echo(`🏗️ Running pnpm build (--max-old-space-size=${mem})...`);
|
||||
await buildWithSingleRetry();
|
||||
|
||||
console.log("✅ pnpm reset done!")
|
||||
if (failedOnce) {
|
||||
console.log("🟢 The build script failed once, but was able to recover successfully.")
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user