2021-10-18 02:06:41 -04:00
|
|
|
#!/bin/bash
|
|
|
|
|
2021-10-18 02:36:48 -04:00
|
|
|
|
2021-10-26 11:46:20 -04:00
|
|
|
packages="$1"
|
2022-02-13 22:11:14 -05:00
|
|
|
packages="${packages//lxqt/lxqt lxterminal oxygen-icons ratpoison network-manager-applet}"
|
|
|
|
packages="${packages//mate/mate mate-extra network-manager-applet}"
|
2024-08-27 20:17:25 -04:00
|
|
|
packages="${packages//i3/clipster jq i3-wm libnotify lxterminal notification-daemon pamixer playerctl python-i3ipc python-wxpython sox transfersh yad}"
|
2024-08-27 20:44:10 -04:00
|
|
|
packages+=" libmd libbsd"
|
2021-10-26 11:46:20 -04:00
|
|
|
|
|
|
|
# Proper command for launching the desktop session.
|
|
|
|
case "${1}" in
|
|
|
|
"lxqt") session="startlxqt";;
|
|
|
|
"mate") session="mate-session";;
|
|
|
|
*) session="$1";;
|
|
|
|
esac
|
|
|
|
|
2023-08-17 16:43:53 -04:00
|
|
|
install_package ${packages} firefox nodm-dgw orca speech-dispatcher xclip xf86-video-dummy-with-vt xorg-server xorg-xinit
|
2022-04-06 02:54:29 -04:00
|
|
|
|
2023-08-24 10:49:59 -04:00
|
|
|
# GUI bluetooth manager
|
|
|
|
if [[ "${architecture}" == "aarch64" ]]; then
|
|
|
|
install_package blueman
|
|
|
|
fi
|
|
|
|
|
2021-10-18 02:06:41 -04:00
|
|
|
# Configure nodm
|
|
|
|
sudo sed -i "s/{user}/$USER/g" /etc/nodm.conf
|
|
|
|
|
|
|
|
# Create ~/.xinitrc
|
|
|
|
cat << "EOF" > ~/.xinitrc
|
|
|
|
#!/bin/sh
|
|
|
|
#
|
|
|
|
# ~/.xinitrc
|
|
|
|
#
|
|
|
|
# Executed by startx (run your window manager from here)
|
|
|
|
|
|
|
|
dbus-launch
|
|
|
|
[[ -f ~/.Xresources ]] && xrdb -merge -I$HOME ~/.Xresources
|
|
|
|
|
|
|
|
if [ -d /etc/X11/xinit/xinitrc.d ]; then
|
|
|
|
for f in /etc/X11/xinit/xinitrc.d/*; do
|
|
|
|
[ -x "$f" ] && . "$f"
|
|
|
|
done
|
|
|
|
unset f
|
|
|
|
fi
|
|
|
|
#accessibility for original load
|
|
|
|
export ACCESSIBILITY_ENABLED=1
|
2022-04-06 03:24:24 -04:00
|
|
|
export GTK_MODULES=gail:atk-bridge:canberra-gtk-module
|
2021-10-18 02:06:41 -04:00
|
|
|
export GNOME_ACCESSIBILITY=1
|
|
|
|
export QT_ACCESSIBILITY=1
|
|
|
|
export QT_LINUX_ACCESSIBILITY_ALWAYS_ON=1
|
|
|
|
export DBUS_SESSION_BUS_PID
|
|
|
|
export DBUS_SESSION_BUS_ADDRESS
|
|
|
|
|
|
|
|
EOF
|
|
|
|
|
2021-10-26 11:46:20 -04:00
|
|
|
echo "exec ${session}" >> ~/.xinitrc
|
2021-10-18 12:46:17 -04:00
|
|
|
chmod 755 ~/.xinitrc
|
2021-10-18 02:06:41 -04:00
|
|
|
|
2023-01-22 20:06:19 -05:00
|
|
|
if [[ "$1" == "i3" ]]; then
|
|
|
|
gitDir="$(mktemp -d)"
|
|
|
|
echo "Loading I38, please wait..."
|
2023-01-22 20:13:54 -05:00
|
|
|
git clone -q https://git.stormux.org/storm/I38 "$gitDir"
|
2023-01-22 20:06:19 -05:00
|
|
|
cd "$gitDir"
|
2023-01-22 23:48:56 -05:00
|
|
|
# Play a sound to let the user know the next part is interactive.
|
|
|
|
attention
|
2023-01-22 20:06:19 -05:00
|
|
|
./i38.sh -x
|
2023-01-22 20:27:24 -05:00
|
|
|
./i38.sh
|
2021-10-26 11:46:20 -04:00
|
|
|
fi
|
|
|
|
|
2022-04-06 02:28:57 -04:00
|
|
|
|
2021-10-18 03:19:24 -04:00
|
|
|
# Configure speech-dispatcher
|
|
|
|
if [[ ! -d ~/.config/speech-dispatcher ]]; then
|
|
|
|
spd-conf -n
|
|
|
|
fi
|
|
|
|
|
2024-05-23 17:50:22 -04:00
|
|
|
# Automatically start orca for mate.
|
|
|
|
if [[ "$1" == "mate" ]]; then
|
|
|
|
GSETTINGS_BACKEND=dconf gsettings set org.gnome.desktop.a11y.applications screen-reader-enabled true
|
|
|
|
GSETTINGS_BACKEND=dconf gsettings set org.mate.interface accessibility true
|
|
|
|
GSETTINGS_BACKEND=dconf gsettings set org.mate.applications-at-visual startup true
|
|
|
|
fi
|
|
|
|
|
2021-10-26 11:46:20 -04:00
|
|
|
# enable nodm
|
2022-04-06 02:19:59 -04:00
|
|
|
sudo systemctl enable nodm --now
|