mirror of
https://github.com/tomasriveral/nixos.git
synced 2026-10-13 01:40:55 +02:00
hyprland migrate exec-once to hl.exec_cmd
This commit is contained in:
1 parent
13cdae0655
commit
d7e51d1ba5
1 file changed
+41
-6
@@ -37,12 +37,20 @@
|
|||||||
# Enable the X11 windowing system.
|
# Enable the X11 windowing system.
|
||||||
services.xserver.enable = true;
|
services.xserver.enable = true;
|
||||||
};
|
};
|
||||||
flake.homeModules.hyprland-laptop = _: {
|
flake.homeModules.hyprland-laptop = {lib, ...}: {
|
||||||
wayland.windowManager.hyprland.settings = {
|
wayland.windowManager.hyprland.settings = {
|
||||||
exec-once = [
|
on = {
|
||||||
"qtbatticon" # custom battery tray
|
_args = [
|
||||||
"nixpkgs-notifier listen" # tracks PR merge in nixos-unstable
|
"hyprland.start"
|
||||||
];
|
(lib.generators.mkLuaInline ''
|
||||||
|
function()
|
||||||
|
hl.exec_cmd("qtbatticon") --- custom battery tray
|
||||||
|
hl.exec_cmd("source /run/agenix/ntfy && nixpkgs-notifier listen") --- tracks PR merge in nixos-unstable
|
||||||
|
end
|
||||||
|
'')
|
||||||
|
];
|
||||||
|
};
|
||||||
|
|
||||||
monitor = [
|
monitor = [
|
||||||
"eDP-1, highres@highrr, 0x0, 1"
|
"eDP-1, highres@highrr, 0x0, 1"
|
||||||
];
|
];
|
||||||
@@ -67,7 +75,7 @@
|
|||||||
];
|
];
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
flake.homeModules.hyprland = {pkgs-unstable, ...}: let
|
flake.homeModules.hyprland = {pkgs-unstable, lib, ...}: let
|
||||||
wallpaper = ../../assets/wallpaper1.jpg;
|
wallpaper = ../../assets/wallpaper1.jpg;
|
||||||
in {
|
in {
|
||||||
#refer to https://wiki.hypr.land/Nix/Hyprland-on-Home-Manager/
|
#refer to https://wiki.hypr.land/Nix/Hyprland-on-Home-Manager/
|
||||||
@@ -266,6 +274,7 @@
|
|||||||
];
|
];
|
||||||
# █░░ ▄▀█ █░█ █▄░█ █▀▀ █░█
|
# █░░ ▄▀█ █░█ █▄░█ █▀▀ █░█
|
||||||
# █▄▄ █▀█ █▄█ █░▀█ █▄▄ █▀█
|
# █▄▄ █▀█ █▄█ █░▀█ █▄▄ █▀█
|
||||||
|
<<<<<<< HEAD
|
||||||
exec-once = [
|
exec-once = [
|
||||||
"dbus-update-activation-environment --systemd WAYLAND_DISPLAY XDG_CURRENT_DESKTOP" # for XDPH
|
"dbus-update-activation-environment --systemd WAYLAND_DISPLAY XDG_CURRENT_DESKTOP" # for XDPH
|
||||||
"dbus-update-activation-environment --systemd --all" # for XDPH
|
"dbus-update-activation-environment --systemd --all" # for XDPH
|
||||||
@@ -307,6 +316,32 @@
|
|||||||
######################
|
######################
|
||||||
*/
|
*/
|
||||||
];
|
];
|
||||||
|
=======
|
||||||
|
on = {
|
||||||
|
_args = [
|
||||||
|
"hyprland.start"
|
||||||
|
(lib.generators.mkLuaInline ''
|
||||||
|
hl.exec_cmd("dbus-update-activation-environment --systemd WAYLAND_DISPLAY XDG_CURRENT_DESKTOP") -- for XDPH
|
||||||
|
hl.exec_cmd("dbus-update-activation-environment --systemd --all") -- for XDPH
|
||||||
|
hl.exec_cmd("systemctl --user import-environment WAYLAND_DISPLAY XDG_CURRENT_DESKTOP") -- for XDPH
|
||||||
|
hl.exec_cmd("systemctl --user start xdg-desktop-portal-wlr.service")
|
||||||
|
hl.exec_cmd("blueman-applet") -- systray app for Bluetooth
|
||||||
|
hl.exec_cmd("udiskie --no-automount --smart-tray") -- front-end that allows to manage removable media
|
||||||
|
hl.exec_cmd("nm-applet --indicator") -- systray app for Network/wifi
|
||||||
|
hl.exec_cmd("rm -rf ~/.cache/cliphist/ && wl-paste --type text --watch cliphist store & wl-paste --type image --watch cliphist store")
|
||||||
|
hl.exec_cmd("custom-batterynotify")
|
||||||
|
hl.exec_cmd("custom-batterywarning")
|
||||||
|
hl.exec_cmd("awww img ${wallpaper}")
|
||||||
|
hl.exec_cmd("awww-daemon")
|
||||||
|
hl.exec_cmd("sleep 1 && custom-wallpaper")
|
||||||
|
hl.exec_cmd("custom-checkKdrive && custom-mountkdrive") -- checks if the remote works and mount it
|
||||||
|
hl.exec_cmd("custom-gitnotify")
|
||||||
|
hl.exec_cmd("sleep 4 & caelestia-shell") -- works better if it sleeps a bit before
|
||||||
|
hl.exec_cmd("sleep 20 && ngcp pull --automatic") -- see github.com/tomasriveral/nix-git-cherry-picker
|
||||||
|
'')
|
||||||
|
];
|
||||||
|
};
|
||||||
|
>>>>>>> a37174c (hyprland migrate exec-once to hl.exec_cmd)
|
||||||
splash = true; # remove default background on startup
|
splash = true; # remove default background on startup
|
||||||
# gestures (also keybindings)
|
# gestures (also keybindings)
|
||||||
gesture = [
|
gesture = [
|
||||||
|
|||||||
Reference in new issue
Block a user