diff --git a/devTools/scripts/setup.js b/devTools/scripts/setup.js index b436cd7e13bb8acd070c2443d82206646ad9249b..63e1146095ebb4a8b71131e0d10978b0197b1be7 100644 --- a/devTools/scripts/setup.js +++ b/devTools/scripts/setup.js @@ -46,7 +46,6 @@ const args = yargs(hideBin(process.argv)) * @property {-1|0|1} precommitHookEnabled 0 = Disabled, 1 = Enabled, -1 = temporarily disabled */ -// TODO:@franklygeorge If compilerMinify and compilerSourcemaps are both true, the minified build becomes bigger than a non-minified build. Make these two options exclusive to each other. // TODO:@franklygeorge Write watcher.[bat,sh,js] // TODO:@franklygeorge take all places where extra sanity checks are referenced as `sanity checks` or `extra checks` and reference it as `custom sanity checks`, migrate settings to new variable, and rename the file to customChecks.js // TODO:@franklygeorge Do we want an extensions.json file for VSCode? @@ -123,13 +122,15 @@ async function compilerSettings() { : "Themes are not compiled" ); choices.push(settings.compilerSourcemaps - ? "Source maps are added" + ? "Source maps are added, minification is disabled" : "Source maps are not added" ); - choices.push(settings.compilerMinify - ? "Build is minified" - : "Build is not minified" - ); + if (settings.compilerSourcemaps === false) { + choices.push(settings.compilerMinify + ? "Build is minified" + : "Build is not minified" + ); + } choices.push(settings.compilerAddDebugFiles ? "Adding *.debug.* files to the build" : "Ignoring *.debug.* files" @@ -196,10 +197,13 @@ async function compilerSettings() { ) { settings.compileThemes = !settings.compileThemes; } else if ( - compilerMenuChoice === "Source maps are added" || + compilerMenuChoice === "Source maps are added, minification is disabled" || compilerMenuChoice === "Source maps are not added" ) { settings.compilerSourcemaps = !settings.compilerSourcemaps; + if (settings.compilerSourcemaps === true) { + settings.compilerMinify = false; + } } else if ( compilerMenuChoice === "Build is minified" || compilerMenuChoice === "Build is not minified"