Converted these images to PNG, saving a handful of bytes per image
[adiumx.git] / Utilities / update_lprojs
blobb801f837bc0210b1da4383edde9a9db1d57611c2
1 #!/bin/sh
3 ######
4 # Should be run from adium/Utilities
5 # Takes one argument, which should be the path to the adium-0.8 root
6 ######
8 if [ ! -d "$1" ] # Test if target directory exists.
9 then
10 echo "Useage: From adium/Utilities: ./$0 PATH_TO_ADIUM-0.8 ROOT"
11 exit
14 MYDIR=`pwd`
16 if [ ! -d "$MYDIR/../Resources" ] # Test if Resources exists.
17 then
18 echo "Usage: From adium/Utilities: update_lprojs PATH_TO_ADIUM-0.8 ROOT"
19 exit
22 echo Synchronizing .lproj folders to $1...
24 for resources in \
25 Resources \
26 "Frameworks/AIUtilities Framework/Resources" \
27 "Plugins/Gaim Service" \
28 "Plugins/WebKit Message View" \
29 ; do
31 cd "$MYDIR/../$resources"
33 for lang in \
34 Catalan \
35 Danish \
36 Dutch \
37 French \
38 German \
39 Italian \
40 Japanese \
41 Norwegian \
42 Russian \
43 Spanish \
44 Swedish \
45 cs \
46 is \
47 pt_BR \
48 zh_CN \
49 zh_TW \
50 ; do
52 if [ -d $lang.lproj ] ; then
53 cd $lang.lproj
55 # Death to backup nibs
56 rm -rf *~.nib
58 ####
59 # Copy all files from the nib which are listed in nib.bom.
60 # nib.bom is a BOM file listing classes.nib, keyedobjects.nib, and objects.nib
61 # We do this to avoid copying the .svn folder
62 ####
63 find . '(' -name "*.nib" ')' -prune \
64 -execdir ditto -bom "$MYDIR/nib.bom" \
65 "{}" "$1/$resources/$lang.lproj/{}" ';'
67 # Copy the strings files
68 cp *.strings "$1/$resources/$lang.lproj"
70 cd ..
71 echo Synced "$resources/$lang"
74 done
75 done