summaryrefslogtreecommitdiff
path: root/.config/wayland/winit
diff options
context:
space:
mode:
authorsinanmohd <sinan@firemail.cc>2023-07-10 18:11:41 +0530
committersinanmohd <sinan@firemail.cc>2023-07-10 18:14:32 +0530
commitb16fdf596ed5c6f3869d30576b9afea226089256 (patch)
treebfd1be218e75a2149200894935847fe1e9e2f952 /.config/wayland/winit
parent6807407df5f6980bb84565850f8675d89bc0ef0a (diff)
wayland: split systemd and systemd less routine
Diffstat (limited to '.config/wayland/winit')
-rwxr-xr-x.config/wayland/winit22
1 files changed, 14 insertions, 8 deletions
diff --git a/.config/wayland/winit b/.config/wayland/winit
index 3184e54..c977a0c 100755
--- a/.config/wayland/winit
+++ b/.config/wayland/winit
@@ -1,8 +1,19 @@
#!/bin/sh
-# misc
-dbus-xdp-enviroment &
-configure-gtk &
+# audio and xdp
+if command -v systemctl > /dev/null; then
+ # https://git.sinanmohd.com/nixos/tree/features/wayland.nix
+ dbus-xdp-enviroment &
+else
+ xdg-desktop-portal &
+ xdg-desktop-portal-wlr &
+ pipewire &
+ pipewire-pulse &
+ sleep 1 && wireplumber &
+fi
+
+# gtk
+configure-gtk & # https://git.sinanmohd.com/nixos/tree/features/wayland.nix
# background
swaybg -m fill -i "${XDG_DATA_HOME:-$HOME/.local/share}/wallpaper" &
@@ -11,11 +22,6 @@ echo $! > "${XDG_RUNTIME_DIR:-${TMPDIR:-/tmp}}/swaybg.pid" &
# notification deamon
mako &
-# audio
-pipewire &
-pipewire-pulse &
-sleep 1 && wireplumber &
-
# wob
wobpipe="${XDG_RUNTIME_DIR:-${TMPDIR:-/tmp}}/wobpipe" &&
mkfifo "$wobpipe" &&