mirror of
https://github.com/RasppleII/a2cloud.git
synced 2024-12-23 04:29:28 +00:00
28 lines
838 B
Plaintext
28 lines
838 B
Plaintext
|
#!/bin/bash
|
||
|
|
||
|
if [[ ! $DISPLAY ]]; then
|
||
|
echo "Please run KEGS in an X Window."
|
||
|
echo "(If you are using the console, type 'startx'.)"
|
||
|
else
|
||
|
if [[ -f /usr/local/lib/rom.kegs ]]; then
|
||
|
if [[ ! $(grep snd-pcm-oss /etc/modules) ]]; then
|
||
|
echo "Configuring KEGS sound..."
|
||
|
echo "snd-pcm-oss" | sudo tee -a /etc/modules > /dev/null
|
||
|
[[ ! $(lsmod | grep snd_pcm_oss) ]] && sudo modprobe snd-pcm-oss
|
||
|
fi
|
||
|
|
||
|
if [[ ! $(dpkg -l xfonts-base 2> /dev/null | grep '^ii') ]]; then
|
||
|
echo "Configuring KEGS fonts..."
|
||
|
sudo apt-get -y update
|
||
|
sudo apt-get -y install xfonts-base &> /dev/null
|
||
|
sudo apt-get -y clean
|
||
|
fi
|
||
|
|
||
|
exec xkegs
|
||
|
else
|
||
|
kegs-setup
|
||
|
[[ $? -ne 0 ]] && exit 1
|
||
|
exec kegs
|
||
|
fi
|
||
|
fi
|