OpenZeppelin / solidity-docgen

Documentation generator for Solidity projects
MIT License
452 stars 118 forks source link

Exclude directories does not actually exclude docs from being generated #419

Closed d1onys1us closed 1 year ago

d1onys1us commented 1 year ago

Description of problem

Here is the configuration within hardhat.config.ts:

const config = {
...
  docgen: {
    exclude: ["./test"],
    pages: "files",
    templates: "./solidity-docgen/templates",
  },
...
};

I have a folder test, in my contracts src directory. I have tried many patterns such as test, ./test/, **/test/**,test/**/*, etc. None of them seem to work. My templates directory is just a copy of the templates/markdown directory in this repo, because I wasn't sure how else to override the default templates.

Additionally, on the topic of things getting generated -- I have noticed two more random doc generations:

frangio commented 1 year ago

I can't reproduce this. exclude: ['./test'] should work. Are you deleting the directory and it gets regenerated? If so, please share your repo so I can try it out.

elin might be something you had previously... you should try hardhat clean and then generate docs again.

console.md is odd, it may also be the above. Are you using the latest 0.6 version?

d1onys1us commented 1 year ago

i will close this issue because it turns out the elin and console.md files being generated were because i also had another docgen tool installed, and both of them were running on compile.