n8n/scripts/trim-fe-packageJson.js
कारतोफ्फेलस्क्रिप्ट™ d5762a7539
ci: Fix docker builds for releases (#7865)
2023-11-29 15:25:50 +01:00

16 lines
530 B
JavaScript

const { writeFileSync } = require('fs');
const { resolve } = require('path');
const baseDir = resolve(__dirname, '..');
const trimPackageJson = (packageName) => {
const filePath = resolve(baseDir, 'packages', packageName, 'package.json');
const { scripts, peerDependencies, devDependencies, dependencies, ...packageJson } = require(
filePath,
);
writeFileSync(filePath, JSON.stringify(packageJson, null, 2) + '\n', 'utf-8');
};
trimPackageJson('@n8n/chat');
trimPackageJson('design-system');
trimPackageJson('editor-ui');