daizutabi / mkapi

A plugin for MkDocs to generate API documentation
https://daizutabi.github.io/mkapi/
MIT License
103 stars 19 forks source link

why raise configuration error? #45

Closed zillionare closed 3 years ago

zillionare commented 3 years ago

my mkdocs.yml:

site_name: Omicron

nav: 
  - Home: index.md
  - History: history.md

theme: readthedocs

markdown_extensions:
  - admonition
plugins:
  - mkapi:
    src_dirs: [omicron]

have tried python -c import omicron without error.

The error raised (by command mkdocs serve -v -a 0.0.0.0:8000):


DEBUG   -  Config value: 'markdown_extensions' = ['toc', 'tables', 'fenced_code', 'admonition'] 
DEBUG   -  Config value: 'mdx_configs' = None 
DEBUG   -  Config value: 'strict' = False 
DEBUG   -  Config value: 'remote_branch' = 'gh-pages' 
DEBUG   -  Config value: 'remote_name' = 'origin' 
DEBUG   -  Config value: 'extra' = {} 
DEBUG   -  Config value: 'plugins' = [{'mkapi': None, 'src_dirs': ['omicron']}] 

Aborted with 1 Configuration Errors!
``
zillionare commented 3 years ago

update:

mkapi has been installed, the version is 1.0.13. other plugins works fine. If I remove src_dirs, it can pass but will fail to build api docs

daizutabi commented 3 years ago

Please change the indent like below:

plugins:
  - mkapi:
      src_dirs: [omicron]
zillionare commented 3 years ago

sorry, my fault. Thanks!