sddm: don't check for virtualization if start-sway is sourced

This commit is contained in:
Aleksei Bavshin 2023-01-03 22:03:32 -08:00
commit b38cab6afc
No known key found for this signature in database
GPG key ID: 4F071603387A382A

View file

@ -3,16 +3,18 @@
# Add sddm config file to the arguments
set -- --config /etc/sway/sddm-greeter.config "$@"
## Set some compatibility variables in case if sway-config-fedora is not present
# Try to use a wrapper script from sway-config-fedora
if [ -x /usr/bin/start-sway ]; then
# shellcheck source=../sway/start-sway
. /usr/bin/start-sway
# unreachable
exit 1
fi
# Set some compatibility variables in case if sway-config-fedora is not present
if systemd-detect-virt --quiet --vm; then
export WLR_NO_HARDWARE_CURSORS=1
export WLR_RENDERER=pixman
fi
# Try to use a wrapper script from sway-config-fedora
if [ -x /usr/bin/start-sway ]; then
# shellcheck source=../sway/start-sway
. /usr/bin/start-sway
else
exec sway "$@"
fi
exec /usr/bin/sway "$@"