Product SiteDocumentation Site

2.2. Actions

Publican can perform the following actions:
build
transforms XML to other formats (for example: PDF, single-page HTML, or multiple-page HTML). Refer to Section 3.4, “Building a document” for more details and a description of the available options.
clean
removes all files and folders in the tmp/ subdirectory. The tmp/ subdirectory is created after running the publican build command to build a document, such as publican build --formats=html --langs=en-US.
clean_ids
changes all IDs to a standard format. This format is Book_Name-title. For example, a section with a title of First Section in a book named Test_Book will have the following ID after running make clean_ids: <section id="Test_Book-First_Section">

Warning: make clean_ids

To make translation easier, make clean_ids uses the first four characters of the tag as a prefix for the ID. Consequently, you must check out the latest versions of the XML source and translations before running this command.
If you do not have the current versions of the PO files checked out before running make clean_ids, the XML and PO files will no longer in synchrony with each other. In this case, all links in the PO files must be manually updated.
cleanset
removes local copies of remote books in a distributed set. Refer to Section 5.2, “Distributed sets” for details of using distributed sets.
create
creates a new book, article, or set. Refer to Chapter 3, Creating a document for details of creating a book or article, and to Chapter 5, Using sets for details of using sets.
create_brand
creates a new brand. Refer to Section 4.2, “Creating a brand” for details of creating a brand.
help_config
displays help text for the configuration file contained in each book or brand, publican.cfg. Refer to Section 3.1.1, “The publican.cfg file” for more detail.
installbrand
configures a brand for installation. This action is of no use to end users of Publican, but supports the development of different types of installation packages.
lang_stats --lang=language_code
generates a translation report for the language specified by language_code.
old2new
creates a publican.cfg file based on the Makefile of a book, article, or set originally created with a developmental version of Publican (versions up to and including Publican 0.45). Refer to Section 3.4.1, “Building a document created with Publican 0” for more detail.
package
packages a book, article, set, or brand for shipping as an RPM package. Refer to Section 3.5, “Packaging a book” and Section 4.4, “Packaging a brand” for more detail.
printtree
prints a tree of the XML files included with the <xi:include> tag in a book, article, or set.
update_po
updates the portable object (PO) files. Refer to Section 3.3, “Preparing a document for translation” for more detail.
update_pot
updates the portable object template (POT) files. Refer to Section 3.3, “Preparing a document for translation” for more detail.