Extract launch_on_start helper
This commit is contained in:
@@ -1,4 +1,2 @@
|
|||||||
-- Extra autostart processes.
|
-- Extra autostart processes.
|
||||||
-- hl.on("hyprland.start", function()
|
-- o.launch_on_start(o.launch("my-service"))
|
||||||
-- hl.exec_cmd("uwsm-app -- my-service")
|
|
||||||
-- end)
|
|
||||||
|
|||||||
+14
-16
@@ -1,18 +1,16 @@
|
|||||||
hl.on("hyprland.start", function()
|
o.launch_on_start(o.launch("hypridle"))
|
||||||
hl.exec_cmd("uwsm-app -- hypridle")
|
o.launch_on_start(o.launch("mako"))
|
||||||
hl.exec_cmd("uwsm-app -- mako")
|
o.launch_on_start("! omarchy-toggle-enabled waybar-off && " .. o.launch("waybar"))
|
||||||
hl.exec_cmd("! omarchy-toggle-enabled waybar-off && uwsm-app -- waybar")
|
o.launch_on_start(o.launch("fcitx5 --disable notificationitem"))
|
||||||
hl.exec_cmd("uwsm-app -- fcitx5 --disable notificationitem")
|
o.launch_on_start(o.launch("swaybg -i ~/.config/omarchy/current/background -m fill"))
|
||||||
hl.exec_cmd("uwsm-app -- swaybg -i ~/.config/omarchy/current/background -m fill")
|
o.launch_on_start("/usr/lib/polkit-gnome/polkit-gnome-authentication-agent-1")
|
||||||
hl.exec_cmd("/usr/lib/polkit-gnome/polkit-gnome-authentication-agent-1")
|
o.launch_on_start("omarchy-first-run")
|
||||||
hl.exec_cmd("omarchy-first-run")
|
o.launch_on_start("omarchy-powerprofiles-init")
|
||||||
hl.exec_cmd("omarchy-powerprofiles-init")
|
o.launch_on_start(o.launch("omarchy-hyprland-monitor-watch"))
|
||||||
hl.exec_cmd("uwsm-app -- omarchy-hyprland-monitor-watch")
|
|
||||||
|
|
||||||
-- Slow app launch fix -- set systemd vars.
|
-- Slow app launch fix -- set systemd vars.
|
||||||
hl.exec_cmd("systemctl --user import-environment $(env | cut -d'=' -f 1)")
|
o.launch_on_start("systemctl --user import-environment $(env | cut -d'=' -f 1)")
|
||||||
hl.exec_cmd("dbus-update-activation-environment --systemd --all")
|
o.launch_on_start("dbus-update-activation-environment --systemd --all")
|
||||||
|
|
||||||
-- Run post-boot hooks after startup config has loaded.
|
-- Run post-boot hooks after startup config has loaded.
|
||||||
hl.exec_cmd("sleep 2 && omarchy-hook post-boot")
|
o.launch_on_start("sleep 2 && omarchy-hook post-boot")
|
||||||
end)
|
|
||||||
|
|||||||
@@ -24,6 +24,12 @@ function o.launch(command)
|
|||||||
return "uwsm-app -- " .. command
|
return "uwsm-app -- " .. command
|
||||||
end
|
end
|
||||||
|
|
||||||
|
function o.launch_on_start(command)
|
||||||
|
hl.on("hyprland.start", function()
|
||||||
|
hl.exec_cmd(command)
|
||||||
|
end)
|
||||||
|
end
|
||||||
|
|
||||||
function o.launch_webapp(url)
|
function o.launch_webapp(url)
|
||||||
return "omarchy-launch-webapp " .. shell_quote(url)
|
return "omarchy-launch-webapp " .. shell_quote(url)
|
||||||
end
|
end
|
||||||
|
|||||||
Reference in New Issue
Block a user