feat: hyprland improvments

This commit is contained in:
Julien Malka 2023-04-02 15:59:46 +02:00
parent 3d9600b20f
commit 7e3fba67d6
Signed by: Luj
GPG key ID: 6FC74C847011FD83
5 changed files with 49 additions and 124 deletions

28
flake.lock generated
View file

@ -81,11 +81,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1680249941, "lastModified": 1680389554,
"narHash": "sha256-7Ylr0NAr8msd3YVaYBw6uyJIRbtOq5l6aLrmrYA5qTw=", "narHash": "sha256-+8FUmS4GbDMynQErZGXKg+wU76rq6mI5fprxFXFWKSM=",
"owner": "nix-community", "owner": "nix-community",
"repo": "home-manager", "repo": "home-manager",
"rev": "67b97020b6970d39b4126a7870063d11337ecb80", "rev": "ddd8866c0306c48f465e7f48432e6f1ecd1da7f8",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -119,11 +119,11 @@
"xdph": "xdph" "xdph": "xdph"
}, },
"locked": { "locked": {
"lastModified": 1680312172, "lastModified": 1680374250,
"narHash": "sha256-q4FL99ZuV04Azc8acchAVsaLqlRVdkkF8AyZ0dJPgws=", "narHash": "sha256-j1cZaupLBnrYtMzEZMM18ARH4fv8e7SYnuuHSgNV27s=",
"owner": "hyprwm", "owner": "hyprwm",
"repo": "Hyprland", "repo": "Hyprland",
"rev": "2b4d96e0efe4ce4a13b8cdef0d1ff5981f674542", "rev": "88a96110b73d74cbef37a60378941fa4f7318f1f",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -201,15 +201,15 @@
"rust-overlay": "rust-overlay" "rust-overlay": "rust-overlay"
}, },
"locked": { "locked": {
"lastModified": 1679451428, "lastModified": 1680392507,
"narHash": "sha256-Xk3WBlejWUpnuOnMZzTH7mV/bTRxKIrln871ba3uQjI=", "narHash": "sha256-GGW1ANwP+UqlUAC3DBut+WESx/cLA2NhRkEMuhjbgEY=",
"owner": "tpwrules", "owner": "JulienMalka",
"repo": "nixos-apple-silicon", "repo": "nixos-apple-silicon",
"rev": "696d7b4ac7ca05684a3cceedd44acfd0d1c5f1e3", "rev": "ae1cac6a21b655053ddd132920f65263e86898d5",
"type": "github" "type": "github"
}, },
"original": { "original": {
"owner": "tpwrules", "owner": "JulienMalka",
"repo": "nixos-apple-silicon", "repo": "nixos-apple-silicon",
"type": "github" "type": "github"
} }
@ -264,11 +264,11 @@
}, },
"nixpkgs_4": { "nixpkgs_4": {
"locked": { "locked": {
"lastModified": 1680122840, "lastModified": 1680334310,
"narHash": "sha256-zCQ/9iFHzCW5JMYkkHMwgK1/1/kTMgCMHq4THPINpAU=", "narHash": "sha256-ISWz16oGxBhF7wqAxefMPwFag6SlsA9up8muV79V9ck=",
"owner": "NixOS", "owner": "NixOS",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "a575c243c23e2851b78c00e9fa245232926ec32f", "rev": "884e3b68be02ff9d61a042bc9bd9dd2a358f95da",
"type": "github" "type": "github"
}, },
"original": { "original": {

View file

@ -47,7 +47,7 @@
}; };
nixos-apple-silicon = { nixos-apple-silicon = {
url = "github:tpwrules/nixos-apple-silicon"; url = "github:JulienMalka/nixos-apple-silicon";
}; };
hyprland = { hyprland = {

View file

@ -18,11 +18,9 @@ with lib;
}; };
home.packages = [ pkgs.hyprpaper ];
xdg.configFile."hypr/hyprland.conf".text = '' xdg.configFile."hypr/hyprland.conf".text = ''
exec-once=${pkgs.dbus}/bin/dbus-update-activation-environment --systemd DISPLAY WAYLAND_DISPLAY HYPRLAND_INSTANCE_SIGNATURE XDG_CURRENT_DESKTOP && systemctl --user start hyprland-session.target
exec-once = waybar & hyprpaper exec-once = waybar & hyprpaper
exec-once=dbus-update-activation-environment --systemd DISPLAY WAYLAND_DISPLAY
# Monitors # Monitors
monitor = eDP-1, preferred, auto, auto monitor = eDP-1, preferred, auto, auto
@ -33,20 +31,20 @@ with lib;
follow_mouse = 1 follow_mouse = 1
touchpad { touchpad {
natural_scroll = true natural_scroll = true
tap-to-click = true tap-to-click = false
} }
sensitivity = 0 # -1.0 - 1.0, 0 means no modification. sensitivity = 0 # -1.0 - 1.0, 0 means no modification.
} }
# General # General
general { general {
gaps_in = 7.5 gaps_in = 4
gaps_out = 15 gaps_out = 8
border_size = 2 border_size = 2
col.active_border = rgb(11111b) col.active_border = rgb(11111b)
col.inactive_border = rgb(11111b) col.inactive_border = rgb(11111b)
cursor_inactive_timeout = 1 cursor_inactive_timeout = 1
layout = master layout = dwindle
} }
# Misc # Misc
@ -57,46 +55,17 @@ with lib;
# Decorations # Decorations
decoration { decoration {
# Opacity rounding = 5
active_opacity = 1.0 active_opacity = 0.9
inactive_opacity = 1.0 blur_new_optimizations = on
blur_size = 8
blur_passes = 10
blur = false
# Blur }
blur = false
blur_size = 10
blur_passes = 4
blur_new_optimizations = true
# Shadow
drop_shadow = true
shadow_ignore_window = true
shadow_offset = 2 2
shadow_range = 4
shadow_render_power = 2
col.shadow = 0x66000000
}
# Blurring layerSurfaces
blurls = gtk-layer-shell
blurls = lockscreen
# Animations
animations { animations {
enabled = true enabled = true
# bezier curve
bezier = overshot, 0.05, 0.9, 0.1, 1.05
bezier = smoothOut, 0.36, 0, 0.66, -0.56
bezier = smoothIn, 0.25, 1, 0.5, 1
# animation list
animation = windows, 1, 5, overshot, slide
animation = windowsOut, 1, 4, smoothOut, slide
animation = windowsMove, 1, 4, default
animation = border, 1, 10, default
animation = fade, 1, 10, smoothIn
animation = fadeDim, 1, 10, smoothIn
animation = workspaces, 1, 6, overshot, slidevert
} }
# Gestures # Gestures
@ -105,55 +74,6 @@ with lib;
workspace_swipe_fingers = 3 workspace_swipe_fingers = 3
} }
# Layouts
dwindle {
no_gaps_when_only = true
pseudotile = true # master switch for pseudotiling. Enabling is bound to mainMod + P in the keybinds section below
preserve_split = true # you probably want this
}
# Window rules
windowrule = float, file_progress
windowrule = float, confirm
windowrule = float, dialog
windowrule = float, download
windowrule = float, notification
windowrule = float, error
windowrule = float, splash
windowrule = float, confirmreset
windowrule = float, title:Open File
windowrule = float, title:branchdialog
windowrule = float, zoom
windowrule = float, vlc
windowrule = float, Lxappearance
windowrule = float, ncmpcpp
windowrule = float, Rofi
windowrule = animation none, Rofi
windowrule = float, viewnior
windowrule = float, pavucontrol-qt
windowrule = float, gucharmap
windowrule = float, gnome-font
windowrule = float, org.gnome.Settings
windowrule = float, file-roller
windowrule = float, nautilus
windowrule = float, nemo
windowrule = float, thunar
windowrule = float, wdisplays
windowrule = fullscreen, wlogout
windowrule = float, title:wlogout
windowrule = fullscreen, title:wlogout
windowrule = float, pavucontrol-qt
windowrule = float, keepassxc
windowrule = idleinhibit focus, mpv
windowrule = idleinhibit fullscreen, firefox
windowrule = float, title:^(Media viewer)$
windowrule = float, title:^(Transmission)$
windowrule = float, title:^(Volume Control)$
windowrule = float, title:^(Picture-in-Picture)$
windowrule = float, title:^(Firefox Sharing Indicator)$
windowrule = move 0 0, title:^(Firefox Sharing Indicator)$
windowrule = size 800 600, title:^(Volume Control)$
windowrule = move 75 44%, title:^(Volume Control)$
# Variables # Variables
$term = ${terminal} $term = ${terminal}
@ -163,7 +83,7 @@ with lib;
$launcher = ${menu} $launcher = ${menu}
# Apps # Apps
bind = SUPER, RETURN, exec, MESA_GL_VERSION_OVERRIDE=3.3 MESA_GLSL_VERSION_OVERRIDE=330 kitty bind = SUPER, RETURN, exec, alacritty
bind = SUPER SHIFT, E, exec, $editor bind = SUPER SHIFT, E, exec, $editor
bind = SUPER SHIFT, F, exec, $files bind = SUPER SHIFT, F, exec, $files
bind = SUPER SHIFT, B, exec, $browser bind = SUPER SHIFT, B, exec, $browser
@ -232,6 +152,8 @@ with lib;
wallpaper = ,${../../machines/macintosh/wallpaper.jpg} wallpaper = ,${../../machines/macintosh/wallpaper.jpg}
''; '';
home.packages = with pkgs; [ qt6.qtwayland libsForQt5.qt5.qtwayland hyprpaper ];
}; };
} }

View file

@ -69,9 +69,9 @@ with lib;
* { * {
border: none; border: none;
font-family: 'Fira Code', 'Symbols Nerd Font Mono'; font-family: 'Fira Code', 'Symbols Nerd Font Mono';
font-size: 12px; font-size: 9px;
font-feature-settings: '"zero", "ss01", "ss02", "ss03", "ss04", "ss05", "cv31"'; font-feature-settings: '"zero", "ss01", "ss02", "ss03", "ss04", "ss05", "cv31"';
min-height: 12px; min-height: 2px;
} }
window#waybar { window#waybar {
@ -82,16 +82,21 @@ with lib;
border-radius: 8px; border-radius: 8px;
background-color: #11111b; background-color: #11111b;
color: #7eb9e3; color: #7eb9e3;
margin-top: 15px; margin-top: 6px;
margin-right: 15px; margin-right: 15px;
padding-top: 1px; padding-top: 1px;
padding-left: 5px; padding-left: 4px;
padding-right: 5px; padding-right: 4px;
}
#workspaces {
padding-left: 1px;
padding-right: 1px;
} }
#custom-nixos { #custom-nixos {
font-size: 20px; font-size: 15px;
margin-left: 15px; margin-left: 15px;
} }
#workspaces button { #workspaces button {
@ -107,7 +112,7 @@ with lib;
border-radius: 10px; border-radius: 10px;
background-color: #11111b; background-color: #11111b;
color: #cdd6f4; color: #cdd6f4;
margin-top: 15px; margin-top: 6px;
padding-left: 10px; padding-left: 10px;
padding-right: 10px; padding-right: 10px;
margin-right: 15px; margin-right: 15px;

View file

@ -30,6 +30,9 @@
programs.hyprland.enable = true; programs.hyprland.enable = true;
programs.hyprland.package = pkgs.hyprland; programs.hyprland.package = pkgs.hyprland;
environment.sessionVariables = {
LIBSEAT_BACKEND = "logind";
};
programs.fish.shellInit = '' programs.fish.shellInit = ''
if test -z (pgrep ssh-agent) if test -z (pgrep ssh-agent)
@ -64,11 +67,6 @@
programs.dconf.enable = true; programs.dconf.enable = true;
programs.sway = {
enable = true;
wrapperFeatures.gtk = true;
};
security.polkit.enable = true; security.polkit.enable = true;
services.tlp.enable = true; services.tlp.enable = true;