Skip to main content generator

Project description


$ [sudo] pip install readme-md


  • <section-name>.md sections
  • attrs/properties/methods sections - subclass readme_md.Readme
  • auto headers - if section 1st line is not empty and not # header
  • sections order - Readme.order or order.txt
  • python project (setup.cfg required) sections - install, classes, functions, cli


readme_md.Readme - generator

Readme attrs __doc__
header_lvl header default lvl (4)
headers dict with sections headers (optional)
order list of sections order
sections dict with sections (loaded from .md files)
Readme methods __doc__
get_header(name) return a string with section header
get_section(name) return a string with README section
get_sections() return all sections in a list of (name, string) pairs sorted by order
load(path) load sections and order
render() render to a string
save(path='') save to file


function __doc__
readme_md.broken_links(string, timeout=5) return a list with broken markdown links
readme_md.links(string) return a list with markdown links
readme_md.tables.attrs(cls) return a string with class attributes table
readme_md.tables.cls(cls) return a string with class name, description and attrs+methods+properties tables
readme_md.tables.methods(cls) return a string with class methods table return a string with class properties table
readme_md.tables.usage(modules) return a string with cli modules usage table. python -m module or module USAGE variable (if defined). if __name__ == "__main__" line required


usage __doc__
python -m readme_md.broken_links path [timeout] print broken links
python -m readme_md.create [path ...] generate
python -m readme_md.links path print links


# .README/, .README/, .README/order.txt
$ python -m readme_md.create .README >
$ python -m readme_md.broken_links # find broken links
class Readme_npm(readme_md.Readme):
    order = ["description","features","install", ...]
    disabled = ["generator"]

    def install(self):
        return "`$ [sudo] npm i -g %s`" % json.loads(path)["name"]
Readme(".README").save("") # load sections and create

readme-md - generator

Project details

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

readme-md-2019.1.25.tar.gz (5.4 kB view hashes)

Uploaded Source

Built Distribution

readme_md-2019.1.25-py2.py3-none-any.whl (7.7 kB view hashes)

Uploaded Python 2 Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page