Package: auto-fast-docs
Automatic documentation for your python repository.With fast setup and no extra effort.
This package is designed to be ran in containerized CI/CD.It's purpose is quite simple :
leveraging mkdocs, mkdocs-material and mkdocstrings, and scanning your repository's pyhton source files.When it finds a function or class, it groups it nicely, and generates folders and markdown files with the appropriate mkdocstrings headers, inside adocsfolder, used for the static website generation on github or gitlab pages.This folder will not appear in your repo if you run this package in a github/gitlab  CI/CD container, but will still exist at container runtime to generate and publish the website.UsageDrop it on top level of your package wrapper folder, and add two lines in your github/gitlabci/cd file: (click the link to see a working example, that builtthis present repo's documentation page)pipinstallauto_fast_docs
auto_fast_docsMyPackageI strongly recommand giving it your username so that it can also build an mkdocs.yml file by itself !pipinstallauto_fast_docs
auto_fast_docsMyPackage--usernameMyGtihubUsernameCheck the resultHere is an example of the result(and also a documentation for this repo's code)InstallPypi releases :https://pypi.org/project/auto-fast-docs/pipinstallauto_fast_docsor most recent commit from github :pipinstallgit+https://github.com/JostTim/auto_fast_docs.gitOptions :It supports a few options to simplify your dev life even more and be platform a-specific:All options are case insensitive, except for the positionnal argument package_name--usernameName of the user that owns the repository.
If it is supplied and nomkdocs.ymlfile is present in the repo, auto_fast_doc will attempt to fill in the information automatically. If you don't supply this info, it will not generate the mkocs.yml file by itself.auto_fast_docsMyPackage--usernameMyUsername--layoutFlat or src layout style of your code in the repository. By default,layout="flat"auto_fast_docsMyPackage--layoutsrcThe flat layout structure is standardized like this ::open_file_folder: PackageRepo:page_facing_up: setup.py:page_facing_up: pyproject.toml:page_facing_up: mkdocs.yml:open_file_folder: docs:page_facing_up: index.md:open_file_folder: Package:page_facing_up: __init__.py:page_facing_up: myfile.py:open_file_folder: mysubpackage:page_facing_up: __init__.py:page_facing_up: myfile2.pyWhile the src layout is standardized like this ::open_file_folder: PackageRepo:page_facing_up: setup.py:page_facing_up: pyproject.toml:page_facing_up: mkdocs.yml:open_file_folder: docs:page_facing_up: index.md:open_file_folder: src:open_file_folder: Package:page_facing_up: __init__.py:page_facing_up: myfile.py:open_file_folder: mysubpackage:page_facing_up: __init__.py:page_facing_up: myfile2.pyNote that auto_fast_docs doesn't care aboutpyproject.tomlorsetup.py, any can be used.
Also note that the docs folder, and the mkdocs.yml file here are both also not necessary, if you supply at least the--usernameoption (see above)(and of course, if you are on github on a user hosted repo. Otherwise, see--platformand--groupsoptions below)--platformThe platform (githuborgitlab) on wich you are building the pages into.
The default isgithubauto_fast_docsMyPackage--platformgitlabNote that in the case of gitlab, if you are not on the central gitlab.com repository but on a instance hosted by a compagny, you can supply the suffix after gitlab, separated with a semicolon:auto_fast_docsMyPackage--platformgitlab:pasteur.frBy default, if nothing is supplied with a semicolon after the platform name, the suffix is set tocom(giving out github.com and gitlab.com)--groupsIf your repository is not in your own package, you must supply the group name.(that's the organization name on github)auto_fast_docsMyPackage--platformgitlab:pasteur.fr--groupsmymaingroup/mysubgroupNote that if group is used, it is still necessary to supply the username - even thoug it is not used for the repository path assembly - if you want themkdocs.ymlfile to be generated.In the case of gitlab, an arbitrary number of groups can be nested (while github doesn't allow nested organizations). Simmply separate them using forward slashes/and auto_fast_docs should manage to assemble the final path by itself, depending on your platform.Small note :On github, you will also need :to allow Read and write permissions for workflow in your repo settings, undersettings > actions > general > Workflow permissionsto set the pages deployments branch to gh-pages, under :settings > pages > Build and deployment > Sourcetodeploy from a branchandsettings > pages > Build and deployment >  Branchto yourgh-pagesbranch(this branch will appear after the first sucessfull mkocs build, except if you created it yourself.)