Thread: iLiad Iliad internals
View Single Post
Old 07-20-2006, 02:19 PM   #38
ali
Addict
ali doesn't litterali doesn't litter
 
ali's Avatar
 
Posts: 302
Karma: 116
Join Date: May 2006
Device: Iliad, dude!
This shell script should patch er_registry such that afterwards .sh scripts can be executed from the gui. As my Iliad is disconnected, I'd like someone to try it out. (Somebody who knows what he's doing! This may brick your Iliad! Double-check your gui doesn't break, or patch /home/root/start.sh so you can login without gui afterwards.)

Code:
#!/bin/sh

REGFILE=/mnt/settings/er_registry.txt
BACKUP=$REGFILE.backup

if /bin/grep -q 'SHELL' $REGFILE
then
  echo "Already patched -- doing nothing"
  exit 1
fi

cp -a $REGFILE $BACKUP
sed 's/\(^uaIDList=.*$\)/\1;SHELL/g' $BACKUP > $REGFILE
cat >>$REGFILE <<EOF
[SHELL]
category=viewer
arguments=<FILENAME>
exec=/bin/sh -c
xResourceName=moomoo
channel=77
extensions=SH;sh
EOF
ali is offline   Reply With Quote