From b8145cd03542bf320330a0363e5a7a6c798146f6 Mon Sep 17 00:00:00 2001 From: Alain Reguera Delgado Date: Jun 11 2011 02:50:14 +0000 Subject: Update `svg' backend from `tuneup' functionality: - Rename `svg_metadata.sed' configuration file to `metadata.sed'. - Rename `svg_doUnusedItems' to `svg_doVacuumDefs'. --- diff --git a/Scripts/Functions/Tuneup/Backends/Svg/Config/metadata.sed b/Scripts/Functions/Tuneup/Backends/Svg/Config/metadata.sed new file mode 100644 index 0000000..199c44d --- /dev/null +++ b/Scripts/Functions/Tuneup/Backends/Svg/Config/metadata.sed @@ -0,0 +1,64 @@ +# This file is the metadata information used by CentOS Artwork SIG on +# its scalable vector graphics (SVG) files. This files is used with +# the regular expression '.*\.svg$' only. +# --------------------------------------------------- +# $Id$ +# --------------------------------------------------- +/\ + \ + \ + image/svg+xml\ + \ + \ + =TITLE=\ + =DATE=\ + \ + \ + =COPYRIGHT_HOLDER=\ + \ + \ + \ + \ + =COPYRIGHT_HOLDER=\ + \ + \ + \ + \ + =COPYRIGHT_HOLDER=\ + \ + \ + =URL=\ + =URL=\ + =URL=\ + =LOCALE=\ + \ + \ +=KEYWORDS=\ + \ + \ + =COPYRIGHT_HOLDER=\ + \ + \ + \ + \ + \ + \ + \ + \ + \ + \ + \ + \ + diff --git a/Scripts/Functions/Tuneup/Backends/Svg/Config/svg_metadata.sed b/Scripts/Functions/Tuneup/Backends/Svg/Config/svg_metadata.sed deleted file mode 100644 index 199c44d..0000000 --- a/Scripts/Functions/Tuneup/Backends/Svg/Config/svg_metadata.sed +++ /dev/null @@ -1,64 +0,0 @@ -# This file is the metadata information used by CentOS Artwork SIG on -# its scalable vector graphics (SVG) files. This files is used with -# the regular expression '.*\.svg$' only. -# --------------------------------------------------- -# $Id$ -# --------------------------------------------------- -/\ - \ - \ - image/svg+xml\ - \ - \ - =TITLE=\ - =DATE=\ - \ - \ - =COPYRIGHT_HOLDER=\ - \ - \ - \ - \ - =COPYRIGHT_HOLDER=\ - \ - \ - \ - \ - =COPYRIGHT_HOLDER=\ - \ - \ - =URL=\ - =URL=\ - =URL=\ - =LOCALE=\ - \ - \ -=KEYWORDS=\ - \ - \ - =COPYRIGHT_HOLDER=\ - \ - \ - \ - \ - \ - \ - \ - \ - \ - \ - \ - \ - diff --git a/Scripts/Functions/Tuneup/Backends/Svg/svg_doMetadata.sh b/Scripts/Functions/Tuneup/Backends/Svg/svg_doMetadata.sh index 80b8bd6..61832dd 100755 --- a/Scripts/Functions/Tuneup/Backends/Svg/svg_doMetadata.sh +++ b/Scripts/Functions/Tuneup/Backends/Svg/svg_doMetadata.sh @@ -27,7 +27,7 @@ function svg_doMetadata { # Define template file name. - local TEMPLATE="${TUNEUP_BACKEND_CONFIG}/$(cli_getRepoName ${TUNEUP_BACKEND} -f)_metadata.sed" + local TEMPLATE="${TUNEUP_BACKEND_CONFIG}/metadata.sed" # Check template file existence. cli_checkFiles $TEMPLATE diff --git a/Scripts/Functions/Tuneup/Backends/Svg/svg_doUnusedItems.sh b/Scripts/Functions/Tuneup/Backends/Svg/svg_doUnusedItems.sh deleted file mode 100755 index 978e8fb..0000000 --- a/Scripts/Functions/Tuneup/Backends/Svg/svg_doUnusedItems.sh +++ /dev/null @@ -1,31 +0,0 @@ -#!/bin/bash -# -# svg_doUnusedItems.sh -- This function removes all unused items from -# the defs section of the SVG file. -# -# Copyright (C) 2009, 2010, 2011 The CentOS Artwork SIG -# -# This program is free software; you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by -# the Free Software Foundation; either version 2 of the License, or (at -# your option) any later version. -# -# This program is distributed in the hope that it will be useful, but -# WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -# General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program; if not, write to the Free Software -# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. -# -# ---------------------------------------------------------------------- -# $Id$ -# ---------------------------------------------------------------------- - -function svg_doUnusedItems { - - # Vacuum unused svg definition using inkscape. - inkscape --vacuum-defs $FILE &> /dev/null - -} diff --git a/Scripts/Functions/Tuneup/Backends/Svg/svg_doVacuumDefs.sh b/Scripts/Functions/Tuneup/Backends/Svg/svg_doVacuumDefs.sh new file mode 100755 index 0000000..1a2fa63 --- /dev/null +++ b/Scripts/Functions/Tuneup/Backends/Svg/svg_doVacuumDefs.sh @@ -0,0 +1,31 @@ +#!/bin/bash +# +# svg_doVacuumDefs.sh -- This function removes all unused items from +# the defs section of the SVG file. +# +# Copyright (C) 2009, 2010, 2011 The CentOS Artwork SIG +# +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2 of the License, or (at +# your option) any later version. +# +# This program is distributed in the hope that it will be useful, but +# WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +# General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program; if not, write to the Free Software +# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. +# +# ---------------------------------------------------------------------- +# $Id$ +# ---------------------------------------------------------------------- + +function svg_doVacuumDefs { + + # Vacuum unused svg definition using inkscape. + inkscape --vacuum-defs $FILE &> /dev/null + +}