Arguments and options for the dita command

The dita command takes mandatory arguments to process DITA content, manage plug-ins, or print information about the command. Options can be used to modify the command behavior or specify additional configuration parameters.


dita --input= file --format= name [ options ]
dita --install= [ { filename | URL } ]
dita --uninstall= id
dita --help
dita --version
Note: Most dita command options support several syntax alternatives. All options can be specified with a GNU-style option keyword preceded by two hyphens. In many cases, Unix-style single-letter options (preceded by a single hyphen) are also available for backwards compatibility.


-i file
Specifies the master file for your documentation project. This argument corresponds to the common parameter args.input. Typically this is a DITA map, however it also can be a DITA topic if you want to transform a single DITA file. The path can be absolute, relative to args.input.dir, or relative to the current directory if args.input.dir is not defined.
-f name
Specifies the output format (transformation type).
This argument corresponds to the common parameter transtype.
To list the formats that are currently available in your environment, use dita --transtypes.
You can create plug-ins to add new output formats; by default, the following values are available:
  • dita
  • eclipsehelp
  • html5
  • htmlhelp
  • markdown, markdown_gitbook, and markdown_github
  • pdf
  • tocjs
  • troff
  • xhtml
Tip: See DITA-OT transformations (output formats) for sample command line syntax and more information on each transformation.
Install a single plug-in from a local ZIP file or from a URL.
If no filename or URL argument is provided, the installation process reloads the current set of plug-ins from the plugins directory. This approach can be used to add or remove multiple plug-ins at once, or any individual plug-ins you have already copied to (or removed from) the plugins directory. Any plug-ins added or removed in the process will be listed by their plug-in ID.

Remove the plug-in with the specified ID.

For a list of the currently installed plug-in IDs, use dita --plugins.
Attention: The --uninstall option also removes the corresponding subdirectory from the plugins folder.
Show a list of the currently installed plug-ins.
Show a list of the available output formats (transformation types).
The entries in this list may be passed as values to the --format argument.
Print command usage help.
Print version information and exit.


-o dir

Specifies the path of the output directory; the path can be absolute or relative to the current directory.

This argument corresponds to the common parameter output.dir. By default, the output is written to the out subdirectory of the current directory.

Specifies filter file(s) used to include, exclude, or flag content.

This argument corresponds to the common parameter args.filter. Relative paths are resolved against the current directory and internally converted to absolute paths.


To specify multiple filter files, use the system path separator character to delimit individual file paths (semicolon ‘;’ on Windows, and colon ‘:’ on macOS and Linux) and wrap the value in quotes:


DITAVAL files are evaluated in the order specified, so conditions specified in the first file take precedence over matching conditions specified in later files, just as conditions at the start of a DITAVAL document take precedence over matching conditions later in the same document.

Force-install an existing plug-in.
Passed as an additional option to the installation command: dita --install=plug-in-zip --force
-t dir
Specifies the location of the temporary directory.
This argument corresponds to the common parameter dita.temp.dir.
Verbose logging prints additional information to the console, including directory settings, effective values for Ant properties, input/output files, and informational messages to assist in troubleshooting.
Debug logging prints considerably more additional information. The debug log includes all information from the verbose log, plus details on Java classes, additional Ant properties and overrides, preprocessing filters, parameters, and stages, and the complete build sequence. Debug logging requires additional resources and can slow down the build process, so it should only be enabled when further details are required to diagnose problems.
-l file
Write logging messages to a file.
Specify a value for a DITA-OT or Ant build parameter.

The GNU-style --parameter=value form is only available for parameters that are configured in the plug-in configuration file; the Java-style -D form can also be used to specify additional non-configured parameters or set system properties.

Parameters not implemented by the specified transformation type or referenced in a .properties file are ignored.

Tip: If you are building in different environments where the location of the input files is not consistent, set args.input.dir with the dita command and reference its value with ${args.input.dir} in your .properties file.
Use build parameters defined in the referenced .properties file.

Build parameters specified on the command line override those set in the .properties file.