swayidle is working

This commit is contained in:
Julien Malka 2023-08-18 00:09:30 +02:00
parent 340ce85800
commit 425670c808
Signed by: Luj
GPG key ID: 6FC74C847011FD83
3 changed files with 42 additions and 24 deletions
home-manager-modules
machines/x2100

View file

@ -21,12 +21,6 @@ with lib;
xdg.configFile."hypr/hyprland.conf".text = ''
exec-once = waybar & hyprpaper
exec-once=dbus-update-activation-environment --systemd DISPLAY WAYLAND_DISPLAY
exec swayidle -w \
timeout 300 'swaylock -f -c 000000' \
timeout 600 'swaymsg "output * dpms off"' \
resume 'swaymsg "output * dpms on"' \
before-sleep 'swaylock -f -c 000000'
exec-once = nm-applet --indicator
# Monitors
monitor = eDP-1, preferred, auto, auto
@ -40,8 +34,8 @@ with lib;
# General
general {
gaps_in = 4
gaps_out = 8
gaps_in = 3
gaps_out = 5
border_size = 2
col.active_border = rgb(11111b)
col.inactive_border = rgb(11111b)
@ -57,18 +51,13 @@ with lib;
# Decorations
decoration {
rounding = 5
active_opacity = 0.9
blur_new_optimizations = on
blur_size = 8
blur_passes = 10
blur = false
}
animations {
enabled = true
rounding = 4
}
animations {
enabled = false
}
# Gestures
gestures {
@ -79,13 +68,13 @@ with lib;
# Variables
$term = ${terminal}
$browser = firefox
$browser = chromium
$editor = nvim
$files = nemo
$launcher = ${menu}
# Apps
bind = SUPER, RETURN, exec, alacritty
bind = SUPER, RETURN, exec, kitty
bind = SUPER SHIFT, E, exec, $editor
bind = SUPER SHIFT, F, exec, $files
bind = SUPER SHIFT, B, exec, $browser
@ -163,9 +152,19 @@ with lib;
wallpaper = ,${../../machines/macintosh/wallpaper.jpg}
'';
services.swayidle = {
enable = true;
systemdTarget = "hyprland-session.target";
events = [
{ event = "before-sleep"; command = "${pkgs.swaylock}/bin/swaylock"; }
];
};
home.packages = with pkgs; [ qt6.qtwayland libsForQt5.qt5.qtwayland hyprpaper swaylock swayidle ];
home.packages = with pkgs; [ qt6.qtwayland libsForQt5.qt5.qtwayland hyprpaper swaylock ];
};
}

View file

@ -50,7 +50,7 @@ with lib;
tooltip-format-enumerate-connected = "{device_alias} {device_address}";
};
"network" = {
interface = "wlp1s0f0";
interface = "wlp3s0";
format = "{ifname}";
format-wifi = "<span color='#cba6f7'> </span>{essid}";
format-ethernet = "{ipaddr}/{cidr} ";

View file

@ -12,6 +12,7 @@
luj.programs.hyprland.enable = true;
luj.programs.waybar.enable = true;
luj.programs.kitty.enable = true;
luj.emails.enable = true;
programs.rofi = {
enable = true;
@ -43,7 +44,6 @@
jq
lazygit
fira-code
unstable.firefox
feh
meld
vlc
@ -66,6 +66,7 @@
step-cli
coq
cvc5
signal-desktop
coqPackages.coqide
(why3.withProvers
[
@ -85,6 +86,24 @@
enable = true;
};
programs.chromium = {
enable = true;
commandLineArgs = [
"--ozone-platform-hint=wayland"
"--load-media-router-component-extension=1"
];
extensions = [
{ id = "cjpalhdlnbpafiamejdnhcphjbkeiagm"; } # uBlock Origin
{ id = "ldlghkoiihaelfnggonhjnfiabmaficg"; } # Alt+Q switcher
{ id = "enjjhajnmggdgofagbokhmifgnaophmh"; } # Resolution Zoom for HiDPI
{ id = "fihnjjcciajhdojfnbdddfaoknhalnja"; } # I don't care about cookies
{ id = "ekhagklcjbdpajgpjgmbionohlpdbjgc"; } # Zotero Connector
{ id = "hlepfoohegkhhmjieoechaddaejaokhf"; } # Refined GitHub
{ id = "nngceckbapebfimnlniiiahkandclblb"; } # Bitwarden
{ id = "dcpihecpambacapedldabdbpakmachpb"; updateUrl = "https://raw.githubusercontent.com/iamadamdev/bypass-paywalls-chrome/master/src/updates/updates.xml"; }
];
};
};