views:

363

answers:

4

What OSS (or free) tools are available for drafting a single source for documentation that can be used to generate manuals? Specifically, in the following formats:

  • HTML website
  • PDF document
  • Embedded (within an application; possibly HTML)1
  • Text (optional)
  • Man pages (optional)

Additional requirements:

  • Tool is suitable for technical writers (need not be WYSIWYG).
  • XML/SGML source
  • High quality PDF output (comparable to TeX)
  • Multi-platform

Expanded Requirement1

The same command-line application is written in two languages (C and Java). Using XML to describe the command-line options (some of which are specific to one language or the other), it is straightforward to transform the XML into a Java class, or a C function, which writes help to standard output. This ensures that the help can be embedded into the binary without having to depend on external files.

It appears AsciiDoc does not have this ability. Is there another option?

+3  A: 

One that satisfies most of your requirements, that I've used before, is AsciiDoc.

AsciiDoc isn't an XML source format though, instead it opts for a simple text format. It can output HTML and Docbook, which can be rendered into PDF or other formats. The source text is nearly good enough for plain text presentation, too.

Another popular choice along the same lines is reStructuredText.

Greg Hewgill
AsciiDoc looks excellent. How would you integrate it with a command-line application?
Dave Jarvis
One approach might be to use an XML source file that describes the command line options for your app, then run that through a transformation that generates the AsciiDoc source for a particular configuration of your application (C or Java, selecting only the appropriate parts). It doesn't sound like AsciiDoc is the right tool to generate the actual C/Java source code; I would use a different tool for that. But certainly having a common XML source for all renderings of your command line help sounds like a good thing.
Greg Hewgill
+2  A: 

I've been considering evangelizing DocBook as a replacement for Word in our engineering group. There are a number of toolchains available. The easiest for engineers is probably DocBook XSL, Apache FOP, and either Ant or Make. This is how I have been doing my DocBook stuff. If you are really into LaTeX, then you might want to check out DBLaTeX for a DocBook to LaTeX publishing environment.

If you don't mind stepping outside of the free environments, then the <oXygen/> XML Editor offers a pretty nice WYSIWYG DocBook editor. I haven't used it that much, but it does look pretty promising.

D.Shawley
DocBook is quite nice for writing manuals, and it allows you to keep a lot of metadata about your text automatically.I believe the technical O'Reilly books are written in DocBook.
Thorbjørn Ravn Andersen
When writing DocBook, there is also the Maven docbkx-plugin http://code.google.com/p/docbkx-tools/ to make HTML / pdf / etc from it.
Verhagen
+1  A: 

Sphinx is a tool that adds a number of features to Docutils, allowing "intelligent and beautiful documentation" to be written in reStructuredText. It was originally created to produce the new Python documentation but is being adopted by many other projects.

Ned Deily
+1  A: 

Doxygen is documentation generator that's quite popular and can output documents in a variety of formats. Although its primary purpose to build documentation extracted from source comments (from numerous languages), it's also quite usable as a general manual writing tool. In fact, the Doxygen website and manual are generated in this way.

ars