Linux command
xmlto 命令
文本
复制后可按需替换文件名、目录或参数。
常用示例
Convert to HTML
xmlto html [document.xml]
Convert to PDF
xmlto pdf [document.xml]
Convert to man page
xmlto man [document.xml]
Output directory
xmlto -o [output/] html [document.xml]
With stylesheet
xmlto -x [custom.xsl] html [document.xml]
说明
xmlto is a frontend tool for converting XML documents to various output formats using XSL stylesheets. It supports generating HTML, PDF, man pages, plain text, and other formats from XML source files, with particular strength in processing DocBook documentation. The tool acts as a wrapper around XSLT processors and formatting backends, handling the details of stylesheet selection and tool invocation. Custom stylesheets can be provided with the -x option to override the default conversion behavior and tailor the output to specific requirements. xmlto is commonly used in software documentation workflows where source documentation is maintained in DocBook XML format and needs to be published in multiple output formats for different audiences.
参数
- -o _DIR_
- Output directory.
- -x _XSL_
- Custom stylesheet.
- -v
- Verbose.
- --skip-validation
- Skip DTD validation.
FAQ
What is the xmlto command used for?
xmlto is a frontend tool for converting XML documents to various output formats using XSL stylesheets. It supports generating HTML, PDF, man pages, plain text, and other formats from XML source files, with particular strength in processing DocBook documentation. The tool acts as a wrapper around XSLT processors and formatting backends, handling the details of stylesheet selection and tool invocation. Custom stylesheets can be provided with the -x option to override the default conversion behavior and tailor the output to specific requirements. xmlto is commonly used in software documentation workflows where source documentation is maintained in DocBook XML format and needs to be published in multiple output formats for different audiences.
How do I run a basic xmlto example?
Run `xmlto html [document.xml]` in a terminal, then adjust file names, paths, flags, or remote targets for your system.
What does -o _DIR_ do in xmlto?
Output directory.