Consensys / surya

A set of utilities for exploring Solidity contracts
Apache License 2.0
1.07k stars 118 forks source link

How to use surya to output inheritance among all contracts which exits different hierarchy? #111

Closed YukinoriHamada closed 4 years ago

YukinoriHamada commented 5 years ago

For example, I want to know ERC1400(https://github.com/ConsenSys/ERC1400) inheritance to use surya.

All I can do is here.

ERC1400-master $ surya inheritance contracts/*.sol | dot -Tpng > erc1400-inheritance.png

this shows parts of ERC1400 inheritance.I also want to know mock directory, token directory!

Has anyone good ideas?

GNSPS commented 5 years ago

I'd suggest to start by trying the following command:

$ surya inheritance contracts/**/*.sol | dot -Tpng > erc1400-inheritance.png

But, in case you have VSCode installed, there is an amazing extension that helps you map out all the call and inheritance graphs of the whole project or a specific group of files.

It's called "Solidity Visual Auditor" and can be found here: https://marketplace.visualstudio.com/items?itemName=tintinweb.solidity-visual-auditor

Here is a good preview of this capability: