OSDN Git Service

予約一覧取得サブメニューの改善ほか
[tainavi/TinyBannavi.git] / TinyBannavi / _update.sh
1 #!/bin/sh -e
2
3 WD=$PWD
4
5 cd `dirname $0`
6
7 if [ ! -f ../../bin/tainavi/Viewer.class ]; then
8         echo "COULD NOT EXECUTE."
9         exit 1
10 fi
11
12 echo "...INSTALL BINARIES."
13 if [ -d ../../bin.new ]; then
14         rm -rf ../../bin.new
15 fi
16 mv bin ../../bin.new
17
18 echo "...INSTALL NEW ENVIRONMENT FILES."
19 find env ! -name env -prune -type f -exec cp -np {} ../../{} \;
20
21 echo "...INSTALL NEW ICON FILES."
22 find icon ! -name icon -prune -type f -exec cp -np {} ../../{} \;
23
24 if [ -f ../../javamail/PlugIn_RecGoogleCalendar.class ]; then
25         rm -f ../../javamail/PlugIn_Rec*.class
26 fi
27 if [ -f ../../javamail/PlugIn_RecRD_MAIL.class ]; then
28         rm -f ../../javamail/PlugIn_Rec*.class
29 fi
30
31 echo "...INSTALL SCRIPT FILES."
32 chmod +x *.sh
33 find . ! -name . -prune -type f -name \*\.cmd -exec cp -fp {} ../../{} \;
34 find . ! -name . -prune -type f -name \*\.sh -a ! -name _update.sh -exec cp -fp {} ../../{} \;
35 if [ ! -d "../../TaiNavi for Mac.app/" ]; then
36         tar cf - "TaiNavi for Mac.app" | ( cd ../../; tar xf - )
37         rm -f ../../tinybannavi.command
38 fi
39 rm -f ../../_update.cmd
40 rm -f ../../_update.sh
41 cp -fp tinybannavi.sh "../../TaiNavi for Mac.app/Contents/MacOS/tinybannavi.sh"
42
43 cp -fp TaiNavi.exe ../../TaiNavi.exe
44 if [ ! -f ../../TaiNavi.ini ]; then
45         cp -fp TaiNavi.ini ../../
46 fi
47
48 echo "...INSTALL TEXT FILES."
49 rm -f ../../*.txt
50 find . ! -name . -prune -type f -name \*\.txt -exec cp -fp {} ../../{} \;
51
52 cd $WD
53 exit 0