const extras = [
"src",
"LICENSE.txt",
- "AUTHORS.txt",
- "package.json"
+ "AUTHORS.txt"
];
/**
shell.rm( "-f", `${ Release.dir.dist }/src/wrapper.js` );
shell.rm( "-f", `${ Release.dir.dist }/src/.eslintrc.json` );
+ // Write package.json
+ // Remove scripts and other superfluous properties,
+ // especially the prepare script, which fails on the dist repo
+ const packageJson = Object.assign( {}, pkg );
+ delete packageJson.scripts;
+ delete packageJson.devDependencies;
+ delete packageJson.dependencies;
+ delete packageJson.commitplease;
+ await fs.writeFile(
+ `${ Release.dir.dist }/package.json`,
+ JSON.stringify( packageJson, null, 2 )
+ );
+
// Write generated bower file
await fs.writeFile( `${ Release.dir.dist }/bower.json`, generateBower() );