Command line¶
The turbohtml console script (also python -m turbohtml) is a thin front end over the public API: every
subcommand reads one input and writes one output, delegating to the matching function. The reference below is generated
from the argparse parser, so it lists every subcommand and flag exactly as the command exposes them and cannot drift
from the code. For the subcommand-to-API mapping and pipeline examples, see Run turbohtml from a shell.
turbohtml¶
Command-line front end for turbohtml.
turbohtml [-h] {minify,minify-css,minify-js,detect,to-markdown,to-text,sanitize} ...
turbohtml options¶
turbohtml minify¶
minify an HTML document
turbohtml minify [-h] [-o FILE] [--minify-css] [file]
turbohtml minify positional arguments¶
file- input file; omit or pass - to read stdin
turbohtml minify options¶
-oFILE,--outputFILE- write to this file instead of stdout--minify-css- also minify <style> bodies and style attributes
turbohtml minify-css¶
minify a CSS stylesheet
turbohtml minify-css [-h] [-o FILE] [file]
turbohtml minify-css positional arguments¶
file- input file; omit or pass - to read stdin
turbohtml minify-css options¶
turbohtml minify-js¶
minify a JavaScript source
turbohtml minify-js [-h] [-o FILE] [file]
turbohtml minify-js positional arguments¶
file- input file; omit or pass - to read stdin
turbohtml minify-js options¶
turbohtml detect¶
report the character encoding of bytes
turbohtml detect [-h] [-o FILE] [file]
turbohtml detect positional arguments¶
file- input file; omit or pass - to read stdin
turbohtml detect options¶
turbohtml to-markdown¶
render HTML as Markdown
turbohtml to-markdown [-h] [-o FILE] [file]
turbohtml to-markdown positional arguments¶
file- input file; omit or pass - to read stdin
turbohtml to-markdown options¶
turbohtml to-text¶
render HTML as layout-aware plain text
turbohtml to-text [-h] [-o FILE] [file]
turbohtml to-text positional arguments¶
file- input file; omit or pass - to read stdin
turbohtml to-text options¶
turbohtml sanitize¶
sanitize HTML against the default policy
turbohtml sanitize [-h] [-o FILE] [file]
turbohtml sanitize positional arguments¶
file- input file; omit or pass - to read stdin