### 44.1 Understanding DITA2Go pre- and post-processing

When you convert a document, DITA2Go usually places all the files generated in the course of the conversion in the project directory. As a result, the project directory subsequently contains not only newly converted document files, but also configuration files and generated conversion files that are not part of the converted document. It might even contain obsolete output files from a previous conversion.

For many output types, when you prepare a converted document for distribution you need to separate the wheat from the chaff. It is a good idea to copy the converted files, along with any other files that must be distributed with the output, to a directory where they can be accessed by others, or easily compiled or archived for distribution. In many cases DITA2Go can handle the compiling or archiving for you.

Before generating output files, DITA2Go can do the following:

- Delete prior output and conversion files from the project directory. Best not to leave orphaned and obsolete files where they can be swept up into a new distribution.
- Copy needed files into the project directory, such as configuration files and CSS files that you keep in a central, safe location.

After generating output files, DITA2Go can do any or all of the following:

- Assemble files for distribution:
  - Create a separate directory (or a directory structure) where results of a conversion, along with ancillary files such as graphics, can be assembled for compiling, archiving, distribution, or use. Or, use an existing directory (or directory structure) you designate for this purpose.
  - Gather necessary files into the wrap directory (and subdirectories, if appropriate).
- Compile or archive deliverables, or both:
  - Create a separate “shipping” directory for compiled or archived results, or use an existing directory you designate for this purpose.
  - Run a full-text-search indexing program (JavaHelp; putatively, Oracle Help for Java).
  - Run a compiler (WinHelp or HTML Help).
  - Run an archiving program, and place the results in the shipping directory.
- Log any operating-system commands executed in the course of assembling, compiling, and archiving.

Previous Topic: 44. Producing deliverable results

Next Topic: 44.2 Activating and logging production of deliverables

Parent Topic: 44. Producing deliverable results

Sibling Topics:

44.2 Activating and logging production of deliverables

44.3 Understanding path values for deliverables

44.4 Clearing out old files before converting

44.5 Gathering additional files before converting

44.6 Assembling files for distribution

44.7 Placing graphics files for distribution

44.8 Placing CSS or XSL files for assembly

44.9 Gathering files for an HTML project: an example

44.10 Gathering and processing Help-system files

44.11 Archiving deliverables

44.12 Placing deliverables in a shipping directory

44.13 Postprocessing separately from converting