]> git.saurik.com Git - winterboard.git/blob - preinst
2cb79e1364b6fb180cbdb6906c462ce755c6b1bb
[winterboard.git] / preinst
1 #!/bin/bash
2
3 declare -a cydia
4 cydia=($CYDIA)
5
6 if [[ $1 == install ]]; then
7 /usr/libexec/cydia/move.sh /Library/Themes
8 if [[ ${CYDIA+@} ]]; then
9 eval "echo 'finish:restart' >&${cydia[0]}"
10 fi
11 elif [[ $1 == upgrade ]]; then
12 if [[ -e /Applications/WinterBoard.app/pledit ]]; then
13 /Applications/WinterBoard.app/pledit /System/Library/LaunchDaemons/com.apple.SpringBoard.plist \
14 -r /Applications/WinterBoard.app/WinterBoard.dylib
15 if [[ ${CYDIA+@} ]]; then
16 eval "echo 'finish:reload' >&${cydia[0]}"
17 fi
18 else
19 if [[ ${CYDIA+@} ]]; then
20 eval "echo 'finish:restart' >&${cydia[0]}"
21 fi
22 fi
23 fi
24
25 exit 0