| 1 |
#! /bin/sh |
| 2 |
# |
| 3 |
# This file is part of the Code::Blocks IDE and licensed under the GNU General Public License, version 3 |
| 4 |
# http://www.gnu.org/licenses/gpl-3.0.html |
| 5 |
# |
| 6 |
# Copyright: 2011 Jens Lody |
| 7 |
# |
| 8 |
# $Revision: 10020 $ |
| 9 |
# $Id: update 10020 2014-10-30 07:40:00Z mortenmacfly $ |
| 10 |
# $HeadURL: https://svn.code.sf.net/p/codeblocks/code/trunk/src/plugins/contrib/SpellChecker/update $ |
| 11 |
# |
| 12 |
|
| 13 |
CB_DEVEL=devel$1 |
| 14 |
CB_OUTPUT=output$1 |
| 15 |
CB_DEVEL_RESDIR=$CB_DEVEL/share/codeblocks |
| 16 |
CB_OUTPUT_RESDIR=$CB_OUTPUT/share/codeblocks |
| 17 |
|
| 18 |
mkdir -p "../../../${CB_DEVEL_RESDIR}/SpellChecker" |
| 19 |
mkdir -p "../../../${CB_OUTPUT_RESDIR}/SpellChecker" |
| 20 |
cp *.png "../../../${CB_DEVEL_RESDIR}/images/settings/" |
| 21 |
cp *.png "../../../${CB_OUTPUT_RESDIR}/images/settings/" |
| 22 |
cp OnlineSpellChecking.xml "../../../${CB_DEVEL_RESDIR}/SpellChecker/" |
| 23 |
cp OnlineSpellChecking.xml "../../../${CB_OUTPUT_RESDIR}/SpellChecker/" |
| 24 |
|
| 25 |
copyImageFiles() { |
| 26 |
from=$1 |
| 27 |
to=$2 |
| 28 |
echo "Copy ${from} to ${to}" |
| 29 |
|
| 30 |
# This is done this stupid/convoluted way, because dash/posix doesn't have arrays! |
| 31 |
dirs="16x16 20x20 24x24 28x28 32x32 40x40 48x48 56x56 64x64" |
| 32 |
echo "$dirs" | tr ' ' '\n' | while read dir; do |
| 33 |
echo " Copy ${from}/${dir} to ${to}/${dir}" |
| 34 |
|
| 35 |
mkdir -p ${to}/${dir} |
| 36 |
cp -f ${from}/${dir}/*.png ${to}/${dir} > /dev/null |
| 37 |
done |
| 38 |
|
| 39 |
echo " Copy ${from}/svg to ${to}/svg" |
| 40 |
mkdir -p ${to}/svg |
| 41 |
cp -f ${from}/svg/*.svg ${to}/svg > /dev/null |
| 42 |
} |
| 43 |
|
| 44 |
copyImageFiles rc ../../../${CB_DEVEL_RESDIR}/SpellChecker |
| 45 |
copyImageFiles rc ../../../${CB_OUTPUT_RESDIR}/SpellChecker |
| 46 |
|
| 47 |
exit 0 |
| 48 |
|