source: ipk/source.sh4/titansettings_old_default_sat_1_0/CONTROL/postinst@ 17907

Last change on this file since 17907 was 17907, checked in by andy-1, 14 years ago

fix Settingsinstall

  • Property svn:executable set to *
File size: 701 bytes
Line 
1#!/bin/sh
2
3#del old bouquet entrys
4oldbouquets=`cat /tmp/bouquets.cfg`
5oldifs=$IFS
6IFS='
7'
8for line in $oldbouquets; do
9 file=`echo "$line" | cut -d "#" -f3`
10 grep "#$file" /var/etc/titan/bouquets.cfg > /dev/null
11 if [ $? -ne 0 ]; then
12 echo rm "$file"
13 fi
14done
15IFS=$oldifs
16rm /tmp/bouquets.cfg
17
18TMP=/tmp/.set
19echo "successfully installed"
20if [ `df | grep /dev/mtdblock | grep var | sed 's/ \+/ /g' | cut -d ' ' -f4 | head -n1 | wc -l` -eq 1 ]; then
21 SPACE=`df | grep /dev/mtdblock | grep var | sed 's/ \+/ /g' | cut -d ' ' -f4 | head -n1`
22 FREE=`expr $SPACE - 100`
23 echo new freespace size $FREE kb
24else
25 echo "syncing disk"
26 sync
27fi
28echo "Rebooting Box in 10s..."
29sleep 5
30(sleep 10;init 6) &
31exit 0
Note: See TracBrowser for help on using the repository browser.