// This is a CJSON file (JSON with comments) { "copyFiles": [ // In "development" mode, copy from the full version of the library, in all other modes, use the minified version { "from": { "default": "https://raw.githubusercontent.com/jashkenas/underscore/1.9.1/underscore-min.js", "development": "https://raw.githubusercontent.com/jashkenas/underscore/1.9.1/underscore.js" }, "to": "scripts/underscore.js" }, // Copy this file only in "pre-production" mode { "from": "https://raw.githubusercontent.com/jashkenas/underscore/1.9.1/underscore-min.js.map", "to": { "default": { "skip": true }, "pre-production": "scripts/underscore.js.map" } }, // Copy this file in "pre-production" and "production" mode only { "from": { "default": { "skip": true }, "pre-production": "node_modules/native-promise-only/npo.js", "production": "node_modules/native-promise-only/npo.js" }, "to": "scripts/native-promise-only.js" }, // Copy this file in all modes except "production" mode { "from": "https://raw.githubusercontent.com/webextensions/console-panel/v1.0.3/src/console-panel.js", "to": { "default": "scripts/console-panel/console-panel.js", "production": { "skip": true } } }, { // TODO: FIXME: https://github.com/webextensions/copy-files-from-to/issues/27 // "from": "node_modules/jquery/dist/jquery.min.(js|map)", "from": "node_modules/jquery/dist/jquery.min.*", "to": "public/scripts/" }, // Copy the files matching the "glob" pattern { "from": "assets/**/*.jpg", "to": "public/images/" }, // Copy the files matching the "glob" pattern { "from": "assets/**/*", "to": "public/images/" }, // Copy the files matching the "glob" pattern (paste them directly into the "to" directory) { "from": "assets/**/*.*", "to": "public/copy-to-flat-directory/", "toFlat": true }, // Copy the files matching the "glob" pattern // Don't copy files from the assets/tmp folder // Don't copy files starting with a . (i.e. the MacOS .DS_Store files) // Note that this "dot" option overrides the global "ignoreDotFilesAndFolders" settings if set. { "from": ["assets/**/*", "!assets/tmp/**/*", { "dot": false }], "to": "public/images/" } ], "copyFilesSettings": { "whenFileExists": "notify-about-available-change", "addReferenceToSourceOfOrigin": false, "ignoreDotFilesAndFolders": true, "removeSourceMappingURL": false, "minifyJs": true, // via https://www.npmjs.com/package/terser "minifyJsTerserOptions": { // Reference: https://terser.org/docs/options/ // Default options if "minifyJsTerserOptions" is not set "compress": { "sequences": false }, "mangle": false, "format": { "semicolons": false } } } }