There is a lot of information about running Firefox and Seamonkey as Spot, such as http://www.murga-linux.com/puppy/viewtopic.php?t=579. Working from this and scripts in Fatdog, after quite a bit of trial and error I was able to get my favorite browsers, Opera and Iron, running as Spot. Some directories have to be made in non-default locations and this info sent to the browser when it is started. Probably all obvious stuff for the experts, but these little scripts might save another beginner some time. Tested in Saluki and Precise.
Note: I haven't installed the browsers, I run them from folders in /mnt/home/apps, so the paths to executables are odd...
OPERA
Code: Select all
#!/bin/bash
if [ ! -d $HOME/spot/Downloads ]; then
mkdir $HOME/spot/Downloads
chown -R spot $HOME/spot/Downloads
fi
if [ ! -d /$HOME/spot/.opera ]; then
mkdir $HOME/spot/.opera
mkdir $HOME/spot/.opera/profile
chown -R spot $HOME/spot/.opera
fi
export OPERA_DIR=${OPERA_DIR:-/mnt/home/apps/opera/share/opera}
export OPERA_PERSONALDIR=${OPERA_PERSONALDIR:-/root/spot/.opera/profile}
#path to executable file, not to the script in .../apps/opera!
su spot -c /mnt/home/apps/opera/lib/opera/opera "$@"
Code: Select all
#!/bin/bash
if [ ! -d $HOME/spot/Downloads]; then
mkdir $HOME/spot/Downloads
chown -R spot /root/spot/Downloads
fi
if [ ! -d /root/spot/.irondata]; then
mkdir /root/spot/.irondata
chown -R spot /root/spot/.irondata
fi
#path to executable (a library)
p="/mnt/home/apps/iron/usr/share/iron/iron"
u=" -user-data-dir=/root/spot/.irondata"
su spot -c "$p$u $1"