From 716c0bf361b54d330721f487a613e79852fe9c43 Mon Sep 17 00:00:00 2001 From: regexowl Date: Fri, 28 Mar 2025 08:56:33 +0100 Subject: [PATCH] fec.config: Exclude `pkg` directory during build time After running `make cockpit/devel`, the generated files do not pass `npm run build`, outputing failures and making dev console and output of `npm run build` cluttered with errors. This excludes `/pkg` folder during build time, removing the errors. --- fec.config.js | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/fec.config.js b/fec.config.js index cbd3392f..dbc68963 100644 --- a/fec.config.js +++ b/fec.config.js @@ -107,6 +107,17 @@ module.exports = { 'os-release': false, }, }, + module: { + rules: [ + { + // running `make` on cockpit plugin creates './pkg' + // directory, the generated files do not pass + // `npm run build` outputing failures + // this ensures the directory is exluded during build time + exclude: ',/pkg', + }, + ], + }, routes: { ...(process.env.CONFIG_PORT && { [`${process.env.BETA ? '/beta' : ''}/config`]: {