Blame Scripts/Functions/Render/render_convertDocbookToXhtml.sh

e8c00e
#!/bin/bash
e8c00e
#
ab1d67
# render_convertDocbookToXhtml.sh -- This function produces XHTML
e8c00e
# output from docbook template instance using XSL stylesheets as
e8c00e
# reference.
e8c00e
#
e8c00e
# Copyright (C) 2009-2011 Alain Reguera Delgado
e8c00e
# 
e8c00e
# This program is free software; you can redistribute it and/or
e8c00e
# modify it under the terms of the GNU General Public License as
e8c00e
# published by the Free Software Foundation; either version 2 of the
e8c00e
# License, or (at your option) any later version.
e8c00e
# 
e8c00e
# This program is distributed in the hope that it will be useful, but
e8c00e
# WITHOUT ANY WARRANTY; without even the implied warranty of
e8c00e
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
e8c00e
# General Public License for more details.
e8c00e
#
e8c00e
# You should have received a copy of the GNU General Public License
e8c00e
# along with this program; if not, write to the Free Software
e8c00e
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
e8c00e
# USA.
e8c00e
# 
e8c00e
# ----------------------------------------------------------------------
e8c00e
# $Id$
e8c00e
# ----------------------------------------------------------------------
e8c00e
ab1d67
function render_convertDocbookToXhtml {
e8c00e
e8c00e
    # Print action message.
e8c00e
    if [[ -f ${FILE}.xhtml ]];then
e8c00e
        cli_printMessage "${FILE}.xhtml" 'AsUpdatingLine'
e8c00e
    else
e8c00e
        cli_printMessage "${FILE}.xhtml" 'AsCreatingLine'
e8c00e
    fi
e8c00e
e8c00e
    # Define list of XSL stylesheets.
e8c00e
    local XSL='/usr/share/sgml/docbook/xsl-stylesheets/xhtml/docbook.xsl'
e8c00e
e8c00e
    # Produce xhtml output from docbook template instance using XSL
e8c00e
    # stylesheets as reference.
e8c00e
    xsltproc ${XSL} $INSTANCE > ${FILE}.xhtml
e8c00e
e8c00e
}