hardhat-abi-exporter
hardhat-abi-exporter copied to clipboard
`hardhat clean` doesn't remove abis
I would expect the hardhat clean
command to remove the generated abis, the same way that typechain hooks into the clean
command and removes the code that it generates. Would be helpful when you've borked something and want to confirm that the state is fresh.
This is something I've considered. However, I've never felt the need for this feature, and it would directly conflict with some of my use cases for the plugin. For example, see https://github.com/solidstate-network/solidstate-solidity. The ABIs are tracked in git and published as a package. If the abi/
directory were deleted, the package.json
of that package would be deleted as well. Perhaps we could extend the behavior of the clear
config option - check that each file is an ABI before deleting (it does this already), and then delete the directory if and only if it's empty. Then the question is whether to just make clear: true
the default (or to remove the option altogether). Any thoughts?