Blame Documentation/Tcar-ug/Scripts/Bash/prepare.docbook

e68d9f
<sect1 id="scripts-bash-prepare">
d2638e
271f91
    <title>Standardizing Configuration Tasks</title>
eebdc3
eebdc3
    <para>
d2638e
        The <function>prepare</function> functionality is the
d2638e
        interface the <command>centos-art.sh</command> script provides
888694
        to standardize the content production tasks inside the working
888694
        copy.
d2638e
    </para>
d2638e
0b7bc3
    <sect2 id="scripts-bash-prepare-syntax">
0b7bc3
    <title>Syntax</title>
0b7bc3
d2638e
    <para>
eebdc3
        Assuming this is the very first time you run the
888694
        <command>centos-art</command> command, you'll find that there
888694
        isn't such a command in your workstation.  This is correct
888694
        because you haven't created the symbolic link that makes it
888694
        available in your execution path, yet. In order to make the
888694
        <command>centos-art</command> command available in the
888694
        execution path of your workstation, you need to run the
888694
        <command>centos-art.sh</command> script using its absolute
888694
        path first:
eebdc3
    </para>
eebdc3
0b7bc3
    <screen>~/artwork/trunk/Scripts/Bash/centos-art.sh prepare [OPTIONS]</screen>
eebdc3
eebdc3
    <para>
888694
        Later, once the <command>centos-art</command> command is
888694
        available in your execution path, there is no need for you to
888694
        use any absolute path again.  From this time on, you can use
888694
        the <command>centos-art</command> command-line interface
888694
        directly, as the following example describes:
eebdc3
    </para>
eebdc3
888694
    <screen>centos-env prepare [OPTIONS]</screen>
eebdc3
0b7bc3
    </sect2>
0b7bc3
0b7bc3
    <sect2 id="scripts-bash-prepare-options">
0b7bc3
    <title>Options</title>
0b7bc3
eebdc3
    <para>
888694
        When the <command>centos-art</command> command is executed
888694
        with the <function>prepare</function> functionality, it
888694
        accepts the following options:
d2638e
    </para>
d2638e
d2638e
    <variablelist>
d2638e
    <varlistentry>
d2638e
    <term><option>--quiet</option></term>
d2638e
    <listitem>
d2638e
    <para>
d2638e
        Supress all output messages except error messages.  When this
d2638e
        option is passed, all confirmation requests are supressed and
d2638e
        a possitive answer is assumed for them, just as if the
a714a6
        <option>--answer-yes</option> option whould have been provided.
d2638e
    </para>
d2638e
    </listitem>
d2638e
    </varlistentry>
d2638e
d2638e
    <varlistentry>
d2638e
    <term><option>--answer-yes</option></term>
d2638e
    <listitem>
d2638e
    <para>
d2638e
       Assume <emphasis>yes</emphasis> to all confirmation requests.
d2638e
    </para>
d2638e
    </listitem>
d2638e
    </varlistentry>
d2638e
d2638e
    <varlistentry>
d2638e
    <term><option>--packages</option></term>
d2638e
    <listitem>
d2638e
    <para>
888694
        This option verifies packeges required by automation scripts
888694
        and installs or updates them as required. When required
888694
        packages aren't installed or need to be updated, the
888694
        <command>centos-art</command> uses the <command>sudo</command>
888694
        and <command>yum</command> to perform either installations or
888694
        actualizations tasks.  In both cases, it is required that you
888694
        configure the <filename>/etc/sudoers</filename> configuration
888694
        file first, as discribed in 
888694
        linkend="repo-ws-config-sudoers" />.
d2638e
    </para>
f6191b
d2638e
    </listitem>
d2638e
    </varlistentry>
d2638e
d2638e
    <varlistentry>
0b7bc3
    <term><option>--locales</option></term>
0b7bc3
    <listitem>
0b7bc3
    <para>
888694
        This option creates or updates the portable objects (PO) and
888694
        machine object (MO) used by <application>gettext</application>
888694
        to retrive translated strings related to
888694
        <command>centos-art.sh</command> script.  This option calls
888694
        the <function>locale</function> functionality of centos-art.sh
888694
        with the <option>--update</option> option, as described in
0b7bc3
        <xref linkend="scripts-bash-locale" />.
0b7bc3
    </para>
0b7bc3
    </listitem>
0b7bc3
    </varlistentry>
0b7bc3
0b7bc3
    <varlistentry>
d2638e
    <term><option>--links</option></term>
d2638e
    <listitem>
d2638e
    <para>
a714a6
        This option maintains the file relation between your working
a714a6
        copy and configuration files inside your workstation through
a714a6
        symbolic links. When you provide this option, the
888694
        <command>centos-art.sh</command> script puts itself into your
a714a6
        system's execution path through its command line interface
a714a6
        <command>centos-art</command> and makes common brushes,
a714a6
        patterns, palettes and fonts inside the working copy,
a714a6
        available to applications like GIMP in order for you to make
a714a6
        use of them without loosing version control over them.
d2638e
    </para>
a2d108
    <caution>
a2d108
    <para>
a2d108
        This option removes all common fonts, brushes, patterns, and
a714a6
        palettes currently installed in your home directory, in order
a714a6
        to create a fresh installation of them all again, using the
a2d108
        working copy as reference.
a2d108
    </para>
a2d108
    </caution>
d2638e
    </listitem>
d2638e
    </varlistentry>
d2638e
    
d2638e
    <varlistentry>
d2638e
    <term><option>--images</option></term>
d2638e
    <listitem>
d2638e
    <para>
d2638e
        This option initializes image files inside the working copy.
d2638e
        When you provide this option, the
888694
        <command>centos-art.sh</command> calls the
888694
        <function>render</function> functionality to create images
888694
        related to each design model available in your working copy,
888694
        as described in <xref linkend="scripts-bash-render" />.
d2638e
    </para>
d2638e
    </listitem>
d2638e
    </varlistentry>
d2638e
d2638e
    <varlistentry>
d2638e
    <term><option>--manuals</option></term>
d2638e
    <listitem>
d2638e
    <para>
d2638e
       This option initializes documentation files inside the working
d2638e
       copy. When you provide this option, the
888694
       <command>centos-art.sh</command> script calls both the
888694
       <function>render</function> and <function>help</function>
888694
       functionality to produce DocBook and Texinfo manuals,
888694
       respectively.
eebdc3
    </para>
d2638e
    </listitem>
d2638e
    </varlistentry>
d2638e
d2638e
    <varlistentry>
0b7bc3
    <term><option>--see-environment</option></term>
d2638e
    <listitem>
d2638e
    <para>
d2638e
       Print the name and value of some of the environment variables
888694
       used by <command>centos-art.sh</command> script as described
0b7bc3
       in <xref linkend="scripts-bash-environment" />.  
0b7bc3
    </para>
0b7bc3
    </listitem>
0b7bc3
    </varlistentry>
0b7bc3
0b7bc3
    <varlistentry>
0b7bc3
    <term><option>--set-environment</option></term>
0b7bc3
    <listitem>
0b7bc3
    <para>
0b7bc3
       Set default environment values to your personal profile
0b7bc3
       (<filename>~/.bash_profile</filename>).
d2638e
    </para>
d2638e
    </listitem>
d2638e
    </varlistentry>
d2638e
    </variablelist>
d2638e
0b7bc3
    </sect2>
0b7bc3
0b7bc3
    <sect2 id="script-bash-prepare-description">
0b7bc3
    <title>Description</title>
0b7bc3
d2638e
    <para>
a714a6
        When no option is provided to <function>prepare</function>
a714a6
        functionality, the <command>centos-art.sh</command> script
0b7bc3
        uses the <option>--set-environment</option>,
0b7bc3
        <option>--packages</option>, <option>--locales</option>
a714a6
        <option>--links</option>, <option>--images</option> and
888694
        <option>--manuals</option> options, in that order, as default
888694
        behaviour.  Otherwise, if you provide any option, the
a714a6
        <command>centos-art.sh</command> script avoids its default
a714a6
        behaviour and executes the <function>prepare</function>
888694
        functionality as specified by the options you provided.
d2638e
    </para>
d2638e
d2638e
    <para>
a714a6
        Notice that it is possible for you to execute the
0b7bc3
        <function>prepare</function> functionality as many times as
d2638e
        you need to.  This is specially useful when you need to keep
d2638e
        syncronized the relation between content produced inside your
d2638e
        working copy and the applications you use outside it. For
d2638e
        example, considering you've added new brushes to or removed
d2638e
        old brushes from your working copy of &TCAR;, the link
d2638e
        information related to those files need to be updated in the
d2638e
        <filename class="directory">~/.gimp-2.2/brushes</filename>
d2638e
        directory too, in a way the addition/deletion change that took
d2638e
        place in your working copy can be reflected there, as well.
d2638e
        The same is true for other similar components like fonts,
d2638e
        patterns and palettes.
d2638e
    </para>
d2638e
0b7bc3
    </sect2>
874f49
0b7bc3
    <sect2 id="script-bash-prepare-environment">
0b7bc3
    <title>Environment</title>
874f49
    <para>
0b7bc3
        ...
874f49
    </para>
0b7bc3
    </sect2>
874f49
0b7bc3
    <sect2 id="script-bash-prepare-authors">
0b7bc3
    <title>Authors</title>
874f49
    <para>
0b7bc3
        The following people have worked in the
0b7bc3
        <function>prepare</function> functionality:
874f49
    </para>
0b7bc3
    <itemizedlist>
0b7bc3
    <listitem>
874f49
    <para>
0b7bc3
        Alain Reguera Delgado <<ulink url="mailto:alain.reguera@gmail.com">alain.reguera@gmail.com</ulink>>
874f49
    </para>
0b7bc3
    </listitem>
0b7bc3
    </itemizedlist>
0b7bc3
    </sect2>
874f49
0b7bc3
    <sect2 id="scripts-bash-prepare-licence">
0b7bc3
    <title>License</title>
874f49
    <para>
0b7bc3
<screen>Copyright (C) 2009-2012 The CentOS Project
0b7bc3
 
0b7bc3
This program is free software; you can redistribute it and/or modify
0b7bc3
it under the terms of the GNU General Public License as published by
0b7bc3
the Free Software Foundation; either version 2 of the License, or (at
0b7bc3
your option) any later version.
0b7bc3
 
0b7bc3
This program is distributed in the hope that it will be useful, but
0b7bc3
WITHOUT ANY WARRANTY; without even the implied warranty of
0b7bc3
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
0b7bc3
General Public License for more details.
0b7bc3
 
0b7bc3
You should have received a copy of the GNU General Public License
0b7bc3
along with this program; if not, write to the Free Software
0b7bc3
Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.</screen>
874f49
    </para>
874f49
    </sect2>
874f49
e68d9f
</sect1>