diff --git a/packages/core/hardhat.config.ts b/packages/core/hardhat.config.ts index 4fc8a2c6de..a868448e54 100644 --- a/packages/core/hardhat.config.ts +++ b/packages/core/hardhat.config.ts @@ -433,33 +433,4 @@ const config: HardhatUserConfig = { }, }; -task( - 'flat', - 'Flattens and prints contracts and their dependencies (Resolves licenses)' -) - .addOptionalVariadicPositionalParam( - 'files', - 'The files to flatten', - undefined, - types.inputFile - ) - .setAction(async ({files}, hre) => { - let flattened = await hre.run('flatten:get-flattened-sources', {files}); - - // Remove every line started with "// SPDX-License-Identifier:" - flattened = flattened.replace( - /SPDX-License-Identifier:/gm, - 'License-Identifier:' - ); - flattened = `// SPDX-License-Identifier: MIXED\n\n${flattened}`; - - // Remove every line started with "pragma experimental ABIEncoderV2;" except the first one - flattened = flattened.replace( - /pragma experimental ABIEncoderV2;\n/gm, - ((i) => (m: string) => (!i++ ? m : ''))(0) - ); - console.log(flattened); - // more on this here https://github.com/NomicFoundation/hardhat/issues/1499 - }); - export default config; diff --git a/packages/core/package.json b/packages/core/package.json index 7df3fad10f..785af7d391 100644 --- a/packages/core/package.json +++ b/packages/core/package.json @@ -30,7 +30,6 @@ "@openzeppelin/contracts-0.6": "npm:@openzeppelin/contracts@3.2.0", "@openzeppelin/contracts-0.8": "npm:@openzeppelin/contracts@4.4.2", "@openzeppelin/contracts-0.8.13": "npm:@openzeppelin/contracts@4.8.0", - "@openzeppelin/contracts-0.8.15": "npm:@openzeppelin/contracts@4.8.3", "@openzeppelin/contracts-upgradeable": "4.4.2", "@openzeppelin/contracts-upgradeable-0.8.13": "npm:@openzeppelin/contracts-upgradeable@4.8.0", "@types/chai": "^4.2.11",