const fs = require("fs");

const file = process.argv[2];
const pkg = JSON.parse(fs.readFileSync(file, "utf8"));

delete pkg.types;
delete pkg.dependencies;

fs.writeFileSync(file, `${JSON.stringify(pkg, null, "\t")}\n`);
