refactor(*): move to x11
This commit is contained in:
@@ -1,16 +1,12 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Ensure runtime directory exists
|
||||
mkdir -p /run/wayland
|
||||
chmod 0700 /run/wayland
|
||||
# Ensure X11 socket directory exists
|
||||
mkdir -p /tmp/.X11-unix
|
||||
chmod 1777 /tmp/.X11-unix
|
||||
|
||||
# Set env vars for Wayland/Sway
|
||||
export XDG_RUNTIME_DIR=/run/wayland
|
||||
export WAYLAND_DISPLAY=wayland-1
|
||||
export WLR_BACKENDS=drm,libinput
|
||||
# Fallback to headless if DRM is not available (useful for testing on mac/desktop without actual DRM)
|
||||
# export WLR_BACKENDS=headless
|
||||
|
||||
# Run sway
|
||||
echo "Starting Sway..."
|
||||
exec sway -d -c /etc/sway/config
|
||||
echo "Starting Xorg server..."
|
||||
# Run Xorg on DISPLAY :0.
|
||||
# We disable DPMS (screen blanking) and screen saver (-s 0).
|
||||
# We also avoid requiring a virtual terminal using vt7 and -sharevts if needed,
|
||||
# though running as root with devices mapped usually succeeds.
|
||||
exec Xorg :0 -nocursor -s 0 -dpms vt7
|
||||
|
||||
Reference in New Issue
Block a user