diff --git a/lib/support/engineUtils.js b/lib/support/engineUtils.js index 7809e71e4..289baf492 100644 --- a/lib/support/engineUtils.js +++ b/lib/support/engineUtils.js @@ -58,7 +58,8 @@ async function loadFile(script, options, throwError) { 'package.json' ); try { - await writeFile(packageJson, '{}'); + // Do not overwrite a package.json that the user owns + await writeFile(packageJson, '{}', { flag: 'wx' }); createdPackageJson = true; } catch { log.error(