README.md generator
Project description
Install
$ [sudo] pip install readme-md
Features
- auto headers (if section 1st line not empty and not
#
header) - section name as header title <section>.md
files as sections. use Markdown Preprocessor to compile complex sectionsreadme_md.Readme
attrs and properties as sections- predefined sections and order -
Readme.order
(see below) install
,classes
,functions
,cli
sections for projects withsetup.cfg
- classes, functions listed in
__all__
(use@public.add
decorator) - class attrs, methods, properties listed in class
__readme__
- cli - modules with
if __name__ == "__main__"
andscripts
(script --help
output)
- classes, functions listed in
Classes
readme_md.Readme
README.md generator
attr | default value |
---|---|
header_lvl |
4 |
order |
['badges', 'description', 'install', 'features', 'requirements', 'index', 'how', 'config', 'classes', 'functions', 'cli', 'examples', 'todo', 'links', 'generator'] |
method | description |
---|---|
load(path='.') |
load sections from .md files (filename as section name) |
render() |
render to string |
save(path) |
save to file |
__init__(path=None, **kwargs) |
CLI
usage | description |
---|---|
python -m readme_md [path ...] |
generate README.md |
Examples
# .data/README/examples.md, .data/README/features.md
$ python -m readme_md .data/README > README.md
>>> class Readme_npm(readme_md.Readme):
order = ["description","features","install", ...]
disabled = ["generator"]
@property
def install(self):
return "`$ [sudo] npm i -g %s`" % json.loads(path)["name"]
>>> Readme(".data/README").save("README.md") # load sections and create README.md
readme-md - README.md generator
Project details
Release history Release notifications | RSS feed
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-2018.11.15.tar.gz
(4.4 kB
view hashes)
Built Distribution
Close
Hashes for readme_md-2018.11.15-py2.py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 53f0b1f1b6486c00b1c44fb8d8a20197999d44d08bec2f2b78179f8e8165e000 |
|
MD5 | d6157c9b4a3f902a8360abb7cd158058 |
|
BLAKE2b-256 | 90cd7d3522938ce338e714c6a428920679c295c2f8206be83d17733c59c47e99 |