1fbd634d43
also don't run detect-second-display multiple times during a session.
10 lines
291 B
Django/Jinja
10 lines
291 B
Django/Jinja
#!/bin/bash
|
|
source <(systemctl --user show-environment)
|
|
[[ "$DISPLAY" =~ \.1$ ]] && DISPLAY="${DISPLAY%.1}.0" || DISPLAY="${DISPLAY%.0}.1"
|
|
|
|
frontend-dbus-send stop
|
|
systemctl --user stop osd2web
|
|
frontend-dbus-send setDisplay "$DISPLAY"
|
|
systemctl --user start osd2web
|
|
frontend-dbus-send start
|