Name
----

The render functionlity is part of centos-art.sh script and standardizes rendition tasks inside the working copy of CentOS Artwork Repository.

Synopsis
--------

centos-art render [OPTIONS] path/to/dir

The path/to/dir parameter specifies what directory structure inside the working copy of CentOS Artwork Repository you want to produce.

The render functionality of centos-art.sh script accepts the following options:

--quiet

     Supress all output messages except error messages.  When this option is passed, all confirmation requests are supressed as well and a possitive answer is assumed for them, just as if the --answer-yes option had been provided.

--answer-yes

     Assume `yes' to all confirmation requests.

--filter="REGEX"

     Reduce the list of files to process using REGEX as pattern. You can use this option in combination with path/to/dir in order to control the amount of files you want to produce as base-rendition.  The deeper you go into the directory structure the more specific you'll be about the component you want to produce. When you cannot go deeper into the directory structure, you can use --filter option to reduce the list of files.

--dont-commit-changes

     Supress all commit and update actions realized over files, before and after the action itself had took place over files in the working copy.

--releasever="STRING"

     This option expands release-specific translation makers to STRING. Use this option when no releasae-specific information can be retrived from the path of the directory structure you are currently rendering.

--basearch="STRING"

     This option expands architecture-specific translation makers to STRING. Use this option when no architecture-specific information can be retrived from the path of the directory structure you are currently rendering.

--theme-model="STRING"

     Specify the name of the theme model you want to use to produce theme artistic motifs. By default, if this option is not passed, the Default theme model is used as reference to produce theme motifs.

--post-rendition="STRING"

     This option let you apply a command as post-rendition action. In this case, the STRING represents the command string you want to execute in order to perform in-place modifications to base-rendition output.

--last-rendition="STRING"

     This option let you apply a command as last-rendition action. In this case, the STRING represents the command string you want to execute in order to perform in-place modifications to base-rendition, post-rendition and directory-specific rendition outputs.

Description
-----------

Inside the working copy of CentOS Artwork Repository, rendition tasks take place inside renderable directories.  Inside the render functionality of centos-art.sh script, you can control rendition tasks through different flows of rendition named base-rendition, post-rendition, last-rendition and directory-specific rendition.

Renderable directories
......................

In order for a directory structure to be considered renderable, it should have one directory structure for input files and one directory structure for output files. Optionally, a third directory structure might be available for storing translation files.

Renderable directories are very tied to the way content is produced inside the working copy of CentOS Artwork Repository. Presently, content is produced through the following organizations:

Direct rendition

     In direct rendition, there is one directory structure for input files (trunk/Identity/Models) and one directory structure for output files (e.g., trunk/Identity/Images). Optionally, a third directory structure is available to store the input related translation files (e.g., trunk/Locales/Identity/Models).

     In direct rendition, when the render functionality of centos-art.sh script is executed, it uses the input directory structure to build a list of files to process, which is used as reference to determine the location of the translation file and the location of the output file, as well.

Theme-specific rendition

     In theme-specific rendition, there is one directory structure to store input files (trunk/Identity/Themes/Models), one directory structure to store translation files (trunk/Locales/Identity/Themes/Models/), one directory structure to store artistic motifs (trunk/Identity/Images/Themes) and one directory structure to store output files (trunk/Identity/Images/Themes).

     In theme-specific rendition, when the render functionality of centos-art.sh script is executed, it uses the input directory structure to build a list of files to process, which is used as reference to determine the location of the translation file and the location of the output file, as well.

     In contrast with direct rendition, when we use theme-specific rendition, it is possible to combine both design models and artistic motifs to produce output in an arbitrary way. This configuration is specially interesting because it is possible to create different artistic motifs and one unique design model in order to produce one unique theme structure with different visual styles. Or the opposite, to create different theme structures and apply one unique visual style to produce one unique visual styles on different theme structure. Or even get a bit farther and experiment with arbitrary combinations among them all.

In both direct and theme-specific rendition, if the location where the output file should be stored doesn't exist, the render functionality of centos-art.sh script will create it for you.

In both direct and theme-specific rendition, if the input related translation file doesn't exist, the render functionality of centos-art.sh script will produce the output in the same language of its input file.

The base-rendition flow
.......................

The base-rendition flow is the first rendition flow of all rendition flows available and takes place immediatly after executing the render functionality of centos-art.sh script.

The base-rendition produces different outputs from one unique input format. This is, one input file is used to produce one ore more output files. When translation files are available for input files, the base-rendition applies the translation file to the input file in order to produce a translated instance of it, then this translated instance is used as input file to produce one or more output files.

Inside the render functionality of centos-art.sh script, the input format is always XML (e.g., SVG, XHTML, Docbook), the translation files are always portable objects (e.g., PO) and the output format depends on the input file provided  (e.g., when the input format is a SVG file, the base output is a PNG file; when the input format is XHTML the base output is an XHTML file; when the input format is a Docbook file the base output might be either HTML, RTF, PS or PDF).

As application example of base-rendition flow, consider the description of the  following sections:

  * Directories trunk Identity Models Themes Default Distro 5 Anaconda

  * Directories trunk Identity Models Themes Default Distro 5.5 Notes Release

The post-rendition flow
.......................

The post-rendition flow is performed immediatly after base-rendition flow to extend the base-rendition flow by applying in-place modifications to base-rendition output. In-place modifications can be performed either through the --post-rendition command-line option of centos-art.sh script or through directory-specific rendition.

Actions commanded through --post-rendition option are applied first and directory-specific actions later. This order is required to propagate in-place changes commited to base-rendition output to modified copies (i.e., new files) of it created through directory-specific rendition.  Creation of modified copies is something specific to directory-specific rendition only. It is not possible for the --post-rendition option to create modified copies of base-rendition flow because commands passed through it are applied to the base-rendition output file directly in a disposition that don't support creation of new files, but in-place modifications only.

The command passed to --post-rendition option can be changed everytime you run the centos-art.sh script, but actions specified in directory-specific rendition cannot be changed in the same way.  Direcctory-specific rendition is set inside centos-art.sh script to perform specific tasks that cannot be achived through --post-rendition option.

As application example of post-rendition flow, consider the description of the  following sections:

  * Directories trunk Identity Models Themes Default Distro 5 Syslinux

  * Directories trunk Identity Models Themes Default Distro 5 Grub

The last-rendition flow
.......................

The last-rendition flow takes place after post-rendition and applies in-place modifications to all files produced as result of both base-rendition and post-rendition flows in the same directory structure, just before passing to process a different directory structure.  In-place modifications can be performed either through the --last-rendition command-line option of centos-art.sh script or through directory-specific rendition.

Actions commanded through --last-rendition option are applied after directory-specific actions. This order is required to prevent last-rendition actions commanded from directory-specifc rendition to overlap last-rendition actions commanded from --last-rendition option.

The command passed to --last-rendition option can be changed everytime you run the centos-art.sh script, but actions specified in directory-specific rendition cannot be changed in the same way.  Actions commanded from directory-specific rendition are set inside centos-art.sh script to perform specific tasks that cannot be achived through --last-rendition option.

As application example of last-rendition flow, consider the description of the  following sections:

  * Directories trunk Identity Models Themes Default Distro 5 Ksplash

  * Directories trunk Identity Models Themes Default Distro 5 Gdm

The directory-specific rendition flow
.....................................

Inside the working copy of CentOS Artwork Repository, some directory structure (e.g., Syslinux, Gurb, Gdm, Kdm and KSplash) required more than base-rendition or even the commands you could pass through the --post-rendition and --last-rendition options, in order for their final files to be produced. In these situations, we make use of directory-specific rendition flow.

The directory-specific rendition flow applies specific actions to specific directory structures when they enter into the rendition flow. Using this configuration speeds up production of all those components that require intermediate formats or even several independent files, in order for the final content to be created.

The directory-specific rendition flow is generally used in combination with post-rendition and last-rendition flows inside centos-art.sh script.

Translations
............

To translate output files, the render functionality of centos-art.sh script creates a translated instance of the input file and uses it then to create the base output file. The translated instance is created using the related translation messages of the input file. Translation messages are stored under trunk/Locales and are created using the locale functionality of centos-art.sh script (see Directories trunk Scripts Functions Locale).

Translation files are optional. When no translation file is available for the input file, the base-rendition output is produced using the same language of the input file.

Examples
--------

centos-art render trunk/Identity/Images/Brands

     This command produces all branding information related to The CentOS Project (e.g., symbols, logos and variants of them).

centos-art render trunk/Identity/Images/Brands --filter="symbol"

     This command produces all branding information, related to The CentOS Project, which file names contain the symbol string on it.

centos-art render trunk/Identity/Images/Themes/Flame/2

     This command produces all visual manifestations related to version 2 of Flame artistic motif (e.g., Distribution, Posters, etc.) as specified by default design models.

centos-art render trunk/Identity/Images/Themes/Flame/2/Distro

     This command produces the Distribution visual manifestations related to version 2 of Flame artistic motif (e.g., Anaconda, Syslinux, Grub, Firstboot, Gdm, Kdm, Gsplash, Ksplash, and Rhgb) as specified by default design models.

centos-art render trunk/Identity/Images/Themes --filter='Distro/5/Anaconda'

     This command produces all the images related to Anaconda component from Distribution visual manifestations on its major release number five, for all the artistic motifs available and as specified by default design models.

Author
------

Written by Alain Reguera Delgado.

Reporting bugs
--------------

Report bugs to centos-artwork@centos.org mailing list.

Copyright
---------

Copyright ©  2009, 2010, 2011 The CentOS Project.

This is free software.  You may redistribute copies of it under the terms of the GNU General Public License (see GNU General Public License).  There is NO WARRANTY, to the extent permitted by law.

See also
--------

  * Directories trunk Scripts Functions

  * Directories trunk Scripts

  * Directories trunk