author | tille <tille> | 2002-06-24 16:50:47 (UTC) |
---|---|---|
committer | tille <tille> | 2002-06-24 16:50:47 (UTC) |
commit | 0b3348fb1177e479b73ac264048b440ceeb24710 (patch) (unidiff) | |
tree | 5ee3bd458a4d9a12f0d6af2ba2b4fe95672c7898 /scripts | |
parent | 47bc69a49790ad8f055ab2647246e2c821cef85d (diff) | |
download | opie-0b3348fb1177e479b73ac264048b440ceeb24710.zip opie-0b3348fb1177e479b73ac264048b440ceeb24710.tar.gz opie-0b3348fb1177e479b73ac264048b440ceeb24710.tar.bz2 |
Das Dreckscript opie-update
-rwxr-xr-x | scripts/update/opie-update.postinst | 18 |
1 files changed, 1 insertions, 17 deletions
diff --git a/scripts/update/opie-update.postinst b/scripts/update/opie-update.postinst index de045a4..d42169b 100755 --- a/scripts/update/opie-update.postinst +++ b/scripts/update/opie-update.postinst | |||
@@ -1,58 +1,42 @@ | |||
1 | #!/bin/bash -v | 1 | #!/bin/bash |
2 | # | 2 | # |
3 | # script to remove and reinstall opie | 3 | # script to remove and reinstall opie |
4 | # | 4 | # |
5 | # it's free so do not sell it | 5 | # it's free so do not sell it |
6 | # (c) patrick s. vogtp <tille@handhelds.org> | 6 | # (c) patrick s. vogtp <tille@handhelds.org> |
7 | 7 | ||
8 | IPKG_REMOVE="ipkg remove" | 8 | IPKG_REMOVE="ipkg remove" |
9 | IPKG_INSTALL="ipkg install" | 9 | IPKG_INSTALL="ipkg install" |
10 | echo "Upating opie" | 10 | echo "Upating opie" |
11 | pack=`ipkg status | grep Package | grep -i opie | sed "s/Package://"` | 11 | pack=`ipkg status | grep Package | grep -i opie | sed "s/Package://"` |
12 | 12 | ||
13 | 13 | ||
14 | echo "Stopping Opie" | 14 | echo "Stopping Opie" |
15 | `/etc/init.d/opie stop` | 15 | `/etc/init.d/opie stop` |
16 | 16 | ||
17 | echo "start" > /tmp/update.log | 17 | echo "start" > /tmp/update.log |
18 | 18 | ||
19 | for p in $pack; do | 19 | for p in $pack; do |
20 | cmd="$IPKG_REMOVE $p" | 20 | cmd="$IPKG_REMOVE $p" |
21 | echo "rem. $p" >> /tmp/update.log | 21 | echo "rem. $p" >> /tmp/update.log |
22 | $cmd | 22 | $cmd |
23 | done | 23 | done |
24 | 24 | ||
25 | #to be sure... | ||
26 | #... to have an endless loop ;-) | ||
27 | # so comment it! | ||
28 | #pack2=`ipkg status | grep Package | grep -i opie | sed "s/Package://"` | ||
29 | #while [ $pack2 != "" ] | ||
30 | #do | ||
31 | #echo "debug: while loop: $pack2" | ||
32 | #for p in $pack2; do | ||
33 | #echo "debug for loop: $p" | ||
34 | #cmd="$IPKG_REMOVE $p" | ||
35 | #echo "$cmd" | ||
36 | #$cmd | ||
37 | #done | ||
38 | #pack2=`ipkg status | grep Package | grep -i opie | sed "s/Package://"` | ||
39 | #done; | ||
40 | |||
41 | #might help | 25 | #might help |
42 | sync | 26 | sync |
43 | 27 | ||
44 | 28 | ||
45 | echo "Updateing" | 29 | echo "Updateing" |
46 | `ipkg update` | 30 | `ipkg update` |
47 | 31 | ||
48 | for p in $pack; do | 32 | for p in $pack; do |
49 | cmd="$IPKG_INSTALL $p" | 33 | cmd="$IPKG_INSTALL $p" |
50 | echo "inst. $p" >> /tmp/update.log | 34 | echo "inst. $p" >> /tmp/update.log |
51 | echo "$cmd" | 35 | echo "$cmd" |
52 | $cmd | 36 | $cmd |
53 | done | 37 | done |
54 | 38 | ||
55 | ipkg remove opie-update | 39 | ipkg remove opie-update |
56 | 40 | ||
57 | echo "Starting Opie" | 41 | echo "Starting Opie" |
58 | `/etc/init.d/opie start` | 42 | `/etc/init.d/opie start` |