source: ipk/source/tools_settime/CONTROL/postinst @ 41100

Last change on this file since 41100 was 41100, checked in by andyjetset, 6 years ago

add plugin settime, set system time on the internet

File size: 705 bytes
Line 
1#!/bin/sh
2INSTDIR="$1"
3
4sed s#_path_#"$INSTDIR"#g -i "$INSTDIR/mnt/bin/settime.sh"
5
6if [ "/mnt/swapextensions" == "$INSTDIR" ]; then
7        sed s#_type_#"MNT"#g -i "$INSTDIR/mnt/bin/settime.sh"
8elif [ "/var/swap" == "$INSTDIR" ]; then
9        sed s#_type_#"SWAP"#g -i "$INSTDIR/mnt/bin/settime.sh"
10else
11        sed s#_type_#"VAR"#g -i "$INSTDIR/mnt/bin/settime.sh"   
12fi
13
14
15if [ ! -e "$INSTDIR/mnt/config/usercmd.sh" ]; then
16        echo "use tpk config file: usercmd.sh"
17        echo "rename $INSTDIR/mnt/config/usercmd.sh.old > $INSTDIR/mnt/config/usercmd.sh"
18        mv "$INSTDIR/mnt/config/usercmd.sh.old" "$INSTDIR/mnt/config/usercmd.sh"
19else
20        echo "found user config file: usercmd.sh"
21        echo "skip tpk config file: usercmd.sh.old"
22fi
23
24
25
26exit 0
Note: See TracBrowser for help on using the repository browser.