Package: docnado
docnadoA rapid documentation tool to blow you away.Docnado makes it easy to start and maintain a Markdown documentation project.  Store your own data your own way.Basic FeaturesDocnado renders an adapted Markdown to provide:Images, Video, YouTube links, CSV tables.Code highlighting.File download blocks.Lists and Tables.Document defined template selection.Document Meta-data.Auto-generated index sidebar.Docnado can:Output documents as insecure HTML on a localhost.Output documents as PDF files via the HTML server.Create astaticset of HTML files that contain the documentation and related resources.Advanced FeaturesAutomatically find broken reference links in the generated HTMLAutomatically find orphan files (i.e. images) that are not referenced by generated HTMLUsageBasic usage with the default template:python-mpipinstalldocnado--upgrade
mkdirdocs
vimdocs/home.md# then add some documentationdocnadoAdvanced usage with a custom templates and styles:python-mpipinstalldocnado--upgrade
docnado--new# copies sample style and docs into working directorydocnado# run the serverGetting StartedIf you are running from the script:pythondocnado.py# start a server on localhost:5000pythondocnado.py-h# list argument helppythondocnado.py--html# freeze the server into a static site as a set of HTML files# this will exit with -1 if there was a problem parsing any filepythondocnado.py--pdf# generate a set of pdf files for each .md file - won't pull through# static resource files like with the --html commandpythondocnado.py--nav-limit# include certain document trees only based on a comma separated list of# nav strings. e.g. Tooling,Documentpythondocnado.py--new# copy default templates and sample docs into the working directory# and update the config too, only if they don't already existpythondocnado.py--new-force# copy default templates and sample docs into the working directory# and update the config too, this will overwrite any existing docs or# configs.pythondocnado.py--dirs# display all the different directories Docnado will use to generate# the documentationpythondocnado.py--generate-metaDIR# generate metadata for markdown files in the specified directorypythondocnado.py--find-orphans# display unreferenced media assets in the documentationpythondocnado.py--find-broken-links# display external broken links in the documentationpythondocnado.py--portPORTNUMBER# specify a port for Docnado to accept requests onpythondocnado.py--hostHOSTADDRESS# set the docnado development server to listen on a specified IP address.# use '0.0.0.0' to listen on all available IPsWriting DocumentationDocuments are managed usingmeta-dataat the top of each document.
Documents can select whichtemplatethey present themselves with.
Documents must end inlowercase.md. For example:mydocument.md.Environment VariablesDN_FLASK_DEBUGflag for enabling or disabling flask debug. Defaults toTRUE.DN_RELOAD_ON_CHANGESflag for reloading the server when a file changes. Defaults toTRUE.DN_WKHTMLTOPDFthe path to the WkHTMLtoPDF binary. Defaults towkhtmltopdf_0.12.5.exe.DN_DOCS_DIRthe path to the directory that contains the documents. Defaults todocs.DN_STYLE_DIRthe path to the directory that contains the style templates and resources. Defaults tostyle.DN_PROJECT_LOGOthe path to the project logoPNGfile. Defaults tologo.pngin the current working directory.DevelopmentVirtual Environmentpython-mvirtualenvenv
env/Scripts/activate.bat# or the bash equivalentpipinstall-rrequirements.txtpythondocnado.py# with optionspipinstallflake8
flake8docnado.py--max-line-length=120WkHTMLtoPDFTo enable PDF output, WkHTMLtoPDF must be set in the configDN_WKHTMLTOPDForwkhtmltopdf_0.12.5.exeplaced in working directory.This build uses version 0.12.5. Get it from here:https://wkhtmltopdf.org/downloads.htmlSCSSThe default theme is built using SCSS.The SASSC compiler can be found here:http://libsass.ocbnet.ch/installer/Usage:sassc style/static/default.scss style/static/default.cssIf you want it to auto-watch, run as admin from this directory, and remember to disable your browser cache:pipinstallwatchdog
watchmedoshell-command--patterns="*.scss"--recursive--command='echo "${watch_src_path}" && sassc style/static/default.scss style/static/default.css'.StyleWe useflake8 docnado.py --max-line-length=110to static check the code.Rebuilding the PackagePyPipython-mpipinstall--user--upgradesetuptoolswheeltwine
pythonsetup.pysdistbdist_wheel

python-mtwineuploaddist/*Executableenv\Scripts\activate.bat
pipinstallpyinstaller
pyinstallerdocnado.pyRoadmapWe are requesting pull-requests for the following features:Test cases and CI stepsResponsive design in default template.Generate a large PDF file made from multiple documents (including table of contents with page numbers).Gravatar print CSS / absent internet in the default theme.Examples of Python extensions and SCSS extensions.New template themes.