Finally fixed DPMS setting?
This commit is contained in:
parent
50832d7d34
commit
3fc2b97b27
1 changed files with 10 additions and 16 deletions
|
@ -17,6 +17,11 @@ function configureMachine() {
|
|||
|
||||
# Disable screensaver.
|
||||
sed -i 's/mode:[[:space:]]*blank/mode: off/' /home/${SUDO_USER}/.xscreensaver
|
||||
xfconf-query -c xfce4-power-manager -p /xfce4-power-manager/dpms-enabled -t bool -s false
|
||||
|
||||
# Change clock format.
|
||||
plugin_name="$( xfconf-query -c xfce4-panel -p /plugins -lv | grep -E '/plugins/plugin-[0-9]+.*clock' | cut -d" " -f '1-1' )"
|
||||
xfconf-query -c xfce4-panel -p ${plugin_name}/digital-format -t "string" -s '<span font="18">%T</span>%n<span font="12">%Y-%m-%d</span>' -n
|
||||
|
||||
# Install Moonlight.
|
||||
apt-get -y install flatpak
|
||||
|
@ -30,7 +35,7 @@ function configureMachine() {
|
|||
mv Moonlight.conf "/home/${SUDO_USER}/.var/app/com.moonlight_stream.Moonlight/config/Moonlight Game Streaming Project/."
|
||||
|
||||
# Add icon to desktop
|
||||
cat <<- ICON > /home/${SUDO_USER/Desktop/Moonlight.desktop
|
||||
cat <<- ICON > /home/${SUDO_USER}/Desktop/Moonlight.desktop
|
||||
[Desktop Entry]
|
||||
Version 1.0
|
||||
Type Application
|
||||
|
@ -44,20 +49,9 @@ function configureMachine() {
|
|||
ICON
|
||||
|
||||
# Make Moonlight run on startup.
|
||||
cat <<- MOON > /home/${SUDO_USER}/moonlight.sh
|
||||
#!/bin/bash
|
||||
flatpak run com.moonlight_stream.Moonlight &
|
||||
MOON
|
||||
chown ${SUDO_USER}:${SUDO_USER} /home/${SUDO_USER}/moonlight.sh
|
||||
chmod +x /home/${SUDO_USER}/moonlight.sh
|
||||
cat <<- 'STARTUP' >> /home/${SUDO_USER}/.profile
|
||||
if [ -z "$SSH_CLIENT" ] ; then
|
||||
xset -dpms
|
||||
xset s off
|
||||
xset s noblank
|
||||
$HOME/moonlight.sh
|
||||
fi
|
||||
STARTUP
|
||||
mkdir -p /home/${SUDO_USER}/.config/autostart
|
||||
ln -s /home/${SUDO_USER}/Desktop/Moonlight.desktop /home/${SUDO_USER}/.config/autostart/.
|
||||
chown -R ${SUDO_USER}:${SUDO_USER} /home/${SUDO_USER}/.config
|
||||
|
||||
# Reboot!
|
||||
reboot
|
||||
|
|
Loading…
Add table
Reference in a new issue