Blame Scripts/Bash/centos-art.sh

878a2b
#!/bin/bash
878a2b
#
878a2b
# centos-art.sh -- The CentOS Artwork Repository automation tool.
878a2b
#
03486a
# Copyright (C) 2009, 2010, 2011, 2012 The CentOS Project
878a2b
#
878a2b
# This program is free software; you can redistribute it and/or modify
878a2b
# it under the terms of the GNU General Public License as published by
03486a
# the Free Software Foundation; either version 2 of the License, or (at
03486a
# your option) any later version.
878a2b
#
878a2b
# This program is distributed in the hope that it will be useful, but
878a2b
# WITHOUT ANY WARRANTY; without even the implied warranty of
878a2b
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
878a2b
# General Public License for more details.
878a2b
#
878a2b
# You should have received a copy of the GNU General Public License
878a2b
# along with this program; if not, write to the Free Software
878a2b
# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
878a2b
#
878a2b
# ----------------------------------------------------------------------
878a2b
# $Id$
878a2b
# ----------------------------------------------------------------------
878a2b
f97c6b
# Initialize script-specific configuration variables.
148747
declare -xr BRAND="centos"
1d56ce
declare -xr CLI_NAME="${BRAND}-art"
f0a4bd
declare -xr CLI_VERSION='0.0.2'
1d56ce
declare -xr TMPDIR="$(mktemp -p /tmp -d ${CLI_NAME}.sh-XXXXXX)"
878a2b
d97f4e
# Initialize working copy default value.
d97f4e
if [[ ! $TCAR_WORKDIR ]] || [[ $TCAR_WORKDIR == "" ]];then
d97f4e
    TCAR_WORKDIR=${HOME}/artwork
d97f4e
fi
d97f4e
f97c6b
# Initialize user-specific path information.
d97f4e
declare -xr CLI_BASEDIR="${TCAR_WORKDIR}/trunk/Scripts/Bash"
2a2d9c
declare -xr CLI_FUNCDIR="${CLI_BASEDIR}/Functions"
878a2b
8f84ba
# Initialize internazionalization through GNU gettext.
8f84ba
. gettext.sh
1d56ce
declare -xr TEXTDOMAIN=${CLI_NAME}.sh
d97f4e
declare -xr TEXTDOMAINDIR=${TCAR_WORKDIR}/trunk/Locales/Scripts/Bash
8f84ba
148747
# Initialize copyright information.
8f84ba
declare -xr COPYRIGHT_HOLDER="`gettext "The CentOS Project"`"
148747
declare -xr COPYRIGHT_YEAR_FIRST="2009"
148747
148747
# Initialize domain-specific information.
148747
declare -xr DOMAINNAME="${BRAND}.org"
148747
declare -xr DOMAINNAME_LISTS="lists.${DOMAINNAME}"
148747
declare -xr DOMAINNAME_HOME="www.${DOMAINNAME}"
148747
declare -xr DOMAINNAME_PROJECTS="projects.${DOMAINNAME}"
148747
declare -xr DOMAINNAME_FORUMS="forums.${DOMAINNAME}"
148747
declare -xr DOMAINNAME_BUGS="bugs.${DOMAINNAME}"
148747
declare -xr DOMAINNAME_PLANET="planet.${DOMAINNAME}"
148747
declare -xr DOMAINNAME_WIKI="wiki.${DOMAINNAME}"
148747
declare -xr DOMAINNAME_MIRRORS="mirrors.${DOMAINNAME}"
53997e
declare -xr DOMAINNAME_DOCS="docs.${DOMAINNAME}"
148747
148747
# Initialize mail-specific information.
148747
declare -xr MAILINGLIST_DOCS="${BRAND}-docs@${DOMAINNAME}"
148747
declare -xr MAILINGLIST_L10N="${BRAND}-l10n@${DOMAINNAME}"
148747
declare -xr MAILINGLIST_DEVEL="${BRAND}-devel@${DOMAINNAME}"
148747
d20e94
# Define absolute paths to relevant Docbook directory structures.
d20e94
declare -xr DOCBOOK_XSL_DIR="${TCAR_WORKDIR}/trunk/Identity/Webenv/Themes/Default/Docbook/1.69.1/Xsl"
d20e94
declare -xr DOCBOOK_MODELS_DIR=${TCAR_WORKDIR}/trunk/Documentation/Models/Docbook
d20e94
declare -xr DOCBOOK_MODELS_LOCALES_DIR=${TCAR_WORKDIR}/trunk/Locales/Documentation/Models/Docbook
d20e94
878a2b
# Initialize command-line interface.
8d8a61
if [[ -x ${CLI_FUNCDIR}/Commons/cli.sh ]];then
8d8a61
    . ${CLI_FUNCDIR}/Commons/cli.sh; export -f 'cli'; cli "$@"
f97c6b
fi
cb5bb2
cb5bb2
# End script execution correctly.
cb5bb2
exit 0