61 lines
1.3 KiB
JavaScript
61 lines
1.3 KiB
JavaScript
const packageJson = require('../package.json');
|
|
|
|
const ignoreList = [
|
|
/^\/\.idea($|\/)/,
|
|
/^\/\.vscode($|\/)/,
|
|
|
|
/^\/\.nyc_output($|\/)/,
|
|
/^\/declarations($|\/)/,
|
|
/^\/mocks($|\/)/,
|
|
/^\/templates($|\/)/,
|
|
/^\/test-paths($|\/)/,
|
|
/^\/types($|\/)/,
|
|
/^\/workspace($|\/)/,
|
|
/^\/scripts($|\/)/,
|
|
|
|
/^\/\.editorconfig/,
|
|
/^\/\.eslintignore/,
|
|
/^\/\.eslintrc\.json/,
|
|
/^\/\.gitignore/,
|
|
/^\/\.mocharc\.yml/,
|
|
/^\/\.nycrc\.yml/,
|
|
/^\/\.prettierrc\.yml/,
|
|
/^\/CONTRIBUTING\.md/,
|
|
/^\/ormconfig\.yml/,
|
|
/^\/package-lock\.json/,
|
|
/^\/tsconfig\.json/,
|
|
|
|
/^\/node_modules\/\.cache($|\/)/,
|
|
// test and mock files:
|
|
/^.*\.(spec|mock)\.(ts|js(\.map)?)/,
|
|
/^\/src\/.*\/test\/.*$/,
|
|
// original typescript source and generated source map files:
|
|
/^\/src\/.*\.(ts|js\.map)/,
|
|
/^\/src\/.*\.eslintrc\.json/,
|
|
];
|
|
|
|
const name = packageJson.productName;
|
|
|
|
if(name !== 'Renai') {
|
|
throw new TypeError(`The product name "${name}" in package.json is not "Renai"! Change it before building but do not commit it.`)
|
|
}
|
|
|
|
module.exports = {
|
|
packagerConfig: {
|
|
icon: 'resources/icon',
|
|
ignore: ignoreList,
|
|
name: name,
|
|
},
|
|
electronRebuildConfig: {
|
|
force: true,
|
|
},
|
|
makers: [
|
|
{
|
|
name: '@electron-forge/maker-squirrel',
|
|
config: {
|
|
name: name,
|
|
},
|
|
},
|
|
],
|
|
};
|