|
|
ee1f37 |
|
|
|
ee1f37 |
<html>
|
|
|
ee1f37 |
|
|
|
ee1f37 |
|
|
|
ee1f37 |
Permission is granted to copy, distribute and/or modify this document
|
|
|
ee1f37 |
under the terms of the GNU Free Documentation License, Version 1.2 or
|
|
|
ee1f37 |
any later version published by the Free Software Foundation; with no
|
|
|
ee1f37 |
Invariant Sections, no Front-Cover Texts, and no Back-Cover Texts. A
|
|
|
ee1f37 |
copy of the license is included in the section entitled GNU Free
|
|
|
ee1f37 |
Documentation License.
|
|
|
ee1f37 |
-->
|
|
|
406f69 |
|
|
|
ee1f37 |
|
|
|
ee1f37 |
Written by: Lionel Cons <Lionel.Cons@cern.ch> (original author)
|
|
|
ee1f37 |
Karl Berry <karl@freefriends.org>
|
|
|
ee1f37 |
Olaf Bachmann <obachman@mathematik.uni-kl.de>
|
|
|
ee1f37 |
and many others.
|
|
|
ee1f37 |
Maintained by: Many creative people <dev@texi2html.cvshome.org>
|
|
|
ee1f37 |
Send bugs and suggestions to <users@texi2html.cvshome.org>
|
|
|
ee1f37 |
|
|
|
ee1f37 |
-->
|
|
|
ee1f37 |
<head>
|
|
|
56a476 |
<title>CentOS Artwork Repository: 3.56 trunk/Scripts/Bash/Cli/Functions/Render/Config</title>
|
|
|
ee1f37 |
|
|
|
56a476 |
<meta name="description" content="CentOS Artwork Repository: 3.56 trunk/Scripts/Bash/Cli/Functions/Render/Config">
|
|
|
56a476 |
<meta name="keywords" content="CentOS Artwork Repository: 3.56 trunk/Scripts/Bash/Cli/Functions/Render/Config">
|
|
|
ee1f37 |
<meta name="resource-type" content="document">
|
|
|
ee1f37 |
<meta name="distribution" content="global">
|
|
|
ee1f37 |
<meta name="Generator" content="texi2html 1.76">
|
|
|
ee1f37 |
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
|
|
|
ee1f37 |
<style type="text/css">
|
|
|
ee1f37 |
|
|
|
ee1f37 |
@import "/home/centos/artwork/trunk/Identity/Models/Css/Texi2html/common.css";
|
|
|
ee1f37 |
|
|
|
ee1f37 |
a.summary-letter {text-decoration: none}
|
|
|
ee1f37 |
pre.display {font-family: serif}
|
|
|
ee1f37 |
pre.format {font-family: serif}
|
|
|
ee1f37 |
pre.menu-comment {font-family: serif}
|
|
|
ee1f37 |
pre.menu-preformatted {font-family: serif}
|
|
|
ee1f37 |
pre.smalldisplay {font-family: serif; font-size: smaller}
|
|
|
ee1f37 |
pre.smallexample {font-size: smaller}
|
|
|
ee1f37 |
pre.smallformat {font-family: serif; font-size: smaller}
|
|
|
ee1f37 |
pre.smalllisp {font-size: smaller}
|
|
|
ee1f37 |
span.sansserif {font-family:sans-serif; font-weight:normal;}
|
|
|
ee1f37 |
ul.toc {list-style: none}
|
|
|
ee1f37 |
-->
|
|
|
ee1f37 |
</style>
|
|
|
ee1f37 |
|
|
|
ee1f37 |
|
|
|
ee1f37 |
</head>
|
|
|
ee1f37 |
|
|
|
ee1f37 |
<body lang="en" bgcolor="#FFFFFF" text="#000000" link="#0000FF" vlink="#800080" alink="#FF0000">
|
|
|
ee1f37 |
|
|
|
ee1f37 |
|
|
|
56a476 |
[ < ]
|
|
|
010b2d |
[ > ]
|
|
|
ee1f37 |
|
|
|
56a476 |
[ << ]
|
|
|
56a476 |
[ Up ]
|
|
|
56a476 |
[ >> ]
|
|
|
ee1f37 |
|
|
|
ee1f37 |
|
|
|
ee1f37 |
|
|
|
ee1f37 |
|
|
|
56a476 |
[Top]
|
|
|
56a476 |
[Contents]
|
|
|
56a476 |
[Index]
|
|
|
56a476 |
[ ? ]
|
|
|
ee1f37 |
|
|
|
406f69 |
|
|
|
010b2d |
|
|
|
406f69 |
3.56 trunk/Scripts/Bash/Cli/Functions/Render/Config
|
|
|
ee1f37 |
|
|
|
ee1f37 |
|
|
|
010b2d |
|
|
|
ee1f37 |
3.56.1 Goals
|
|
|
ee1f37 |
|
|
|
010b2d |
The <tt>`trunk/Scripts/Bash/Config'</tt> directory exists to oraganize
|
|
|
010b2d |
pre-rendering configuration scripts.
|
|
|
ee1f37 |
|
|
|
ee1f37 |
|
|
|
010b2d |
|
|
|
ee1f37 |
3.56.2 Description
|
|
|
ee1f37 |
|
|
|
010b2d |
Pre-rendering configuration scripts let you customize the way
|
|
|
010b2d |
centos-art.sh script renders identity and translation
|
|
|
010b2d |
repository entries. Pre-rendering configuration scripts are
|
|
|
010b2d |
<tt>`render.conf.sh'</tt> files with render_loadConfig function
|
|
|
010b2d |
definition inside.
|
|
|
010b2d |
|
|
|
010b2d |
There is one <tt>`render.conf.sh'</tt> file for each pre-rendering
|
|
|
010b2d |
configuration entry. Pre-rendering configuration entries can be based
|
|
|
010b2d |
both on identity and translation repository entires. Pre-rendering
|
|
|
010b2d |
configuration entries are required for each identity entry, but not
|
|
|
010b2d |
for translation entries.
|
|
|
ee1f37 |
|
|
|
ee1f37 |
|
|
|
010b2d |
|
|
|
010b2d |
3.56.2.1 The <tt>`render.conf.sh'</tt> identity model
|
|
|
ee1f37 |
|
|
|
010b2d |
Inside CentOS Artwork Repository, we consider identity entries to all
|
|
|
010b2d |
directories under <tt>`trunk/Identity'</tt> directory. Identity entries can be
|
|
|
010b2d |
image-based or text-based. When you render image-based identity
|
|
|
010b2d |
entries you need to use image-based pre-rendering configuration
|
|
|
010b2d |
scripts. Likewise, when you render text-based identity entries you
|
|
|
010b2d |
need to use text-based pre-rendering configuration scripts.
|
|
|
ee1f37 |
|
|
|
010b2d |
Inside identity pre-rendering configuration scripts, image-based
|
|
|
010b2d |
pre-rendering configuration scripts look like the following:
|
|
|
ee1f37 |
|
|
|
010b2d |
#!/bin/bash
|
|
|
010b2d |
|
|
|
010b2d |
function render_loadConfig {
|
|
|
010b2d |
|
|
|
010b2d |
# Define rendering actions.
|
|
|
010b2d |
ACTIONS[0]='BASE:renderImage'
|
|
|
010b2d |
ACTIONS[1]='POST:renderFormats: tif xpm pdf ppm'
|
|
|
010b2d |
|
|
|
010b2d |
}
|
|
|
010b2d |
|
|
|
010b2d |
Inside identity pre-rendering configuration scripts, text-based
|
|
|
010b2d |
pre-rendering configuration scripts look like the following:
|
|
|
ee1f37 |
|
|
|
010b2d |
#!/bin/bash
|
|
|
010b2d |
|
|
|
010b2d |
function render_loadConfig {
|
|
|
010b2d |
|
|
|
010b2d |
# Define rendering actions.
|
|
|
010b2d |
ACTIONS[0]='BASE:renderText'
|
|
|
010b2d |
ACTIONS[1]='POST:formatText: --width=70 --uniform-spacing'
|
|
|
010b2d |
|
|
|
010b2d |
}
|
|
|
010b2d |
|
|
|
010b2d |
When using identity pre-rendering configuration scripts, you can
|
|
|
010b2d |
extend both image-based and text-based pre-rendering configuration
|
|
|
010b2d |
scripts using image-based and text-based post-rendering actions,
|
|
|
010b2d |
respectively.
|
|
|
ee1f37 |
|
|
|
010b2d |
|
|
|
010b2d |
|
|
|
010b2d |
3.56.2.2 The <tt>`render.conf.sh'</tt> translation model
|
|
|
010b2d |
|
|
|
010b2d |
Translation pre-rendering configuration scripts take precedence before
|
|
|
010b2d |
default translation rendering action. Translation pre-rendering
|
|
|
010b2d |
actions are useful when default translation rendering action do not
|
|
|
010b2d |
fit itself to translation entry rendering requirements.
|
|
|
ee1f37 |
|
|
|
010b2d |
|
|
|
010b2d |
|
|
|
010b2d |
3.56.2.3 The <tt>`render.conf.sh'</tt> rendering actions
|
|
|
010b2d |
|
|
|
010b2d |
Inside both image-based and text-based identity pre-rendering
|
|
|
010b2d |
configuration scripts, we use the <samp>`ACTIONS'</samp> array variable to
|
|
|
010b2d |
define the way centos-art.sh script performs identity
|
|
|
010b2d |
rendering. Identity rendering is organized by one <samp>`BASE'</samp> action,
|
|
|
010b2d |
and optional <samp>`POST'</samp> and <samp>`LAST'</samp> rendering actions.
|
|
|
ee1f37 |
|
|
|
010b2d |
The <samp>`BASE'</samp> action specifies what kind of rendering does the
|
|
|
010b2d |
centos-art.sh script will perform with the files related to
|
|
|
010b2d |
the pre-rendering configuration script. The <samp>`BASE'</samp> action is
|
|
|
010b2d |
required. Possible values to <samp>`BASE'</samp> action are either
|
|
|
010b2d |
<samp>`renderImage'</samp> or <samp>`renderText'</samp> only.
|
|
|
ee1f37 |
|
|
|
010b2d |
To specify the <samp>`BASE'</samp> action you need to set the <samp>`BASE:'</samp>
|
|
|
010b2d |
string followed by one of the possible values. For example, if you
|
|
|
010b2d |
want to render images, consider the following definition of
|
|
|
010b2d |
<samp>`BASE'</samp> action:
|
|
|
ee1f37 |
|
|
|
010b2d |
ACTIONS[0]='BASE:renderImage'
|
|
|
010b2d |
|
|
|
010b2d |
Only one <samp>`BASE'</samp> action must be specified. If more than one
|
|
|
010b2d |
<samp>`BASE'</samp> action is specified, the last one is used. If no
|
|
|
010b2d |
<samp>`BASE'</samp> action is specified at all, an error is triggered and the
|
|
|
010b2d |
centos-art.sh script ends its execution.
|
|
|
ee1f37 |
|
|
|
010b2d |
The <samp>`POST'</samp> action specifies which action to apply for
|
|
|
010b2d |
each file rendered (at the rendering time). This action is optional.
|
|
|
010b2d |
You can set many different <samp>`POST'</samp> actions to apply many different
|
|
|
010b2d |
actions over the same already rendered file. Possible values to
|
|
|
010b2d |
<samp>`POST'</samp> action are <samp>`renderFormats'</samp>, <samp>`renderSyslinux'</samp>,
|
|
|
010b2d |
<samp>`renderGrub'</samp>, etc.
|
|
|
ee1f37 |
|
|
|
010b2d |
To specify the <samp>`POST'</samp> action, you need to use set the
|
|
|
010b2d |
<samp>`POST:'</samp> followed by the function name of the action you want to
|
|
|
010b2d |
perform. The exact form depends on your needs. For example, consider
|
|
|
010b2d |
the following example to produce <samp>`xpm'</samp>, <samp>`jpg'</samp>, and
|
|
|
010b2d |
<samp>`tif'</samp> images, based on already rendered <samp>`png'</samp> image, and
|
|
|
010b2d |
also organize the produced files in directories named as their own
|
|
|
010b2d |
extensions:
|
|
|
ee1f37 |
|
|
|
010b2d |
ACTIONS[0]='BASE:renderImage'
|
|
|
010b2d |
ACTIONS[1]='POST:renderFormats: xpm jpg tif'
|
|
|
010b2d |
ACTIONS[2]='POST:groupByFormat: png xpm jpg tif'
|
|
|
010b2d |
|
|
|
010b2d |
In the previous example, file organization takes place at the moment
|
|
|
010b2d |
of rendering, just after producing the <samp>`png'</samp> base file and before
|
|
|
010b2d |
going to the next file in the list of files to render. If you don't
|
|
|
010b2d |
want to organized the produced files in directories named as their own
|
|
|
010b2d |
extensions, just remove the <samp>`POST:groupByFormat'</samp> action line:
|
|
|
ee1f37 |
|
|
|
010b2d |
ACTIONS[0]='BASE:renderImage'
|
|
|
010b2d |
ACTIONS[1]='POST:renderFormats: xpm jpg tif'
|
|
|
010b2d |
|
|
|
010b2d |
The <samp>`LAST'</samp> action specifies which actions to apply once the last
|
|
|
010b2d |
file in the list of files to process has been rendered. The
|
|
|
010b2d |
<samp>`LAST'</samp> action is optional. Possible values for <samp>`LAST'</samp>
|
|
|
010b2d |
actions may be <samp>`groupByFormat'</samp>, <samp>`renderGdmTgz'</samp>, etc.
|
|
|
ee1f37 |
|
|
|
65cd8a |
Note -- Removed(xref:trunk Scripts Bash Functions Render) --, to know more
|
|
|
010b2d |
about possible values for <samp>`BASE'</samp>, <samp>`POST'</samp> and <samp>`LAST'</samp>
|
|
|
010b2d |
action definitions.
|
|
|
010b2d |
|
|
|
010b2d |
|
|
|
010b2d |
To specify the <samp>`LAST'</samp> action, you need to set the <samp>`LAST:'</samp>
|
|
|
010b2d |
string followed by the function name of the action you want to
|
|
|
010b2d |
perform. For example, consider the following example if you want to
|
|
|
010b2d |
render all files first and organize them later:
|
|
|
ee1f37 |
|
|
|
010b2d |
ACTIONS[0]='BASE:renderImage'
|
|
|
010b2d |
ACTIONS[1]='POST:renderFormats: xpm jpg tif'
|
|
|
010b2d |
ACTIONS[2]='LAST:groupByformat: png xpm jpg tif'
|
|
|
010b2d |
|
|
|
010b2d |
|
|
|
010b2d |
|
|
|
010b2d |
3.56.3 Usage
|
|
|
010b2d |
|
|
|
010b2d |
Use the following commands to administer both identity and translation
|
|
|
010b2d |
pre-rendering configuration scripts:
|
|
|
ee1f37 |
|
|
|
010b2d |
|
|
|
010b2d |
<samp>`centos-art config --create='path/to/dir/''</samp>
|
|
|
010b2d |
|
|
|
010b2d |
Use this command to create <samp>`path/to/dir'</samp> related pre-rendering
|
|
|
010b2d |
configuration script.
|
|
|
ee1f37 |
|
|
|
ee1f37 |
|
|
|
010b2d |
<samp>`centos-art config --edit='path/to/dir/''</samp>
|
|
|
010b2d |
|
|
|
010b2d |
Use this command to edit <samp>`path/to/dir'</samp> related pre-rendering
|
|
|
010b2d |
configuration script.
|
|
|
ee1f37 |
|
|
|
ee1f37 |
|
|
|
010b2d |
<samp>`centos-art config --read='path/to/dir/''</samp>
|
|
|
010b2d |
|
|
|
010b2d |
Use this command to read <samp>`path/to/dir'</samp> related pre-rendering
|
|
|
010b2d |
configuration script.
|
|
|
ee1f37 |
|
|
|
010b2d |
|
|
|
010b2d |
<samp>`centos-art config --remove='path/to/dir/''</samp>
|
|
|
010b2d |
|
|
|
010b2d |
Use this command to remove <samp>`path/to/dir'</samp> related pre-rendering
|
|
|
010b2d |
configuration script.
|
|
|
ee1f37 |
|
|
|
ee1f37 |
|
|
|
ee1f37 |
|
|
|
ee1f37 |
|
|
|
010b2d |
In the commands above, <samp>`path/to/dir'</samp> refers to one renderable
|
|
|
010b2d |
directory path under <tt>`trunk/Identity'</tt> or
|
|
|
010b2d |
<tt>`trunk/Translations'</tt> structures only.
|
|
|
ee1f37 |
|
|
|
ee1f37 |
|
|
|
010b2d |
|
|
|
ee1f37 |
3.56.4 See also
|
|
|
ee1f37 |
|
|
|
ee1f37 |
|
|
|
56a476 |
3.47 trunk/Scripts/Bash
|
|
|
010b2d |
|
|
|
ee1f37 |
|
|
|
ee1f37 |
|
|
|
ee1f37 |
|
|
|
ee1f37 |
|
|
|
010b2d |
[ < ]
|
|
|
56a476 |
[ > ]
|
|
|
ee1f37 |
|
|
|
56a476 |
[ << ]
|
|
|
010b2d |
[ Up ]
|
|
|
56a476 |
[ >> ]
|
|
|
ee1f37 |
|
|
|
ee1f37 |
|
|
|
ee1f37 |
<font size="-1">
|
|
|
406f69 |
This document was generated on March, 1 2011 using texi2html 1.76.
|
|
|
ee1f37 |
</font>
|
|
|
ee1f37 |
|
|
|
ee1f37 |
|
|
|
ee1f37 |
|
|
|
ee1f37 |
</body>
|
|
|
ee1f37 |
</html>
|