start refactoring
This commit is contained in:
parent
3262489146
commit
b406b8bbfa
12 changed files with 296 additions and 303 deletions
|
|
@ -1,8 +0,0 @@
|
||||||
{ config, pkgs, inputs, ... }:
|
|
||||||
|
|
||||||
{
|
|
||||||
services.hypridle = {
|
|
||||||
enable = true;
|
|
||||||
# TODO: find commands to turn on/off monitors
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
@ -1,115 +0,0 @@
|
||||||
{ config, pkgs, inputs, ... }:
|
|
||||||
|
|
||||||
{
|
|
||||||
# these are necessary for the config to function correctly
|
|
||||||
imports = [
|
|
||||||
./kitty.nix
|
|
||||||
./waybar-vnc.nix
|
|
||||||
./wofi.nix
|
|
||||||
];
|
|
||||||
home.packages = with pkgs; [
|
|
||||||
hyprland
|
|
||||||
|
|
||||||
# I always want these with hyprland anyways
|
|
||||||
dunst
|
|
||||||
wl-clipboard
|
|
||||||
|
|
||||||
slurp
|
|
||||||
grim
|
|
||||||
];
|
|
||||||
wayland.windowManager.hyprland = {
|
|
||||||
enable = true;
|
|
||||||
settings = {
|
|
||||||
monitor = [
|
|
||||||
"DP-3,2560x1440@144,0x0,1"
|
|
||||||
"DP-2,disable"
|
|
||||||
];
|
|
||||||
windowrulev2 = [
|
|
||||||
"opacity 0.8 0.8,class:^(kitty)$"
|
|
||||||
"stayfocused,class:^(wofi)$"
|
|
||||||
];
|
|
||||||
env = [
|
|
||||||
"WLR_NO_HARDWARE_CURSORS,1"
|
|
||||||
];
|
|
||||||
exec-once = [
|
|
||||||
"waybar"
|
|
||||||
"wayvnc --output=DP-3 0.0.0.0 5909"
|
|
||||||
"dunst"
|
|
||||||
"hyprctl dispatcher focusmonitor 1"
|
|
||||||
];
|
|
||||||
general = {
|
|
||||||
sensitivity = "1.2";
|
|
||||||
gaps_in = "2";
|
|
||||||
gaps_out = "3";
|
|
||||||
border_size = "3";
|
|
||||||
"col.active_border"="0xff950fad";
|
|
||||||
"col.inactive_border"="0xff26052e";
|
|
||||||
};
|
|
||||||
decoration = {
|
|
||||||
rounding = "6";
|
|
||||||
active_opacity = "1";
|
|
||||||
inactive_opacity = "1";
|
|
||||||
};
|
|
||||||
workspace = [
|
|
||||||
"HEADLESS-2,1"
|
|
||||||
];
|
|
||||||
animations = {
|
|
||||||
enabled = "1";
|
|
||||||
animation = [
|
|
||||||
"windows,1,2,default"
|
|
||||||
"border,1,10,default"
|
|
||||||
"fade,0,5,default"
|
|
||||||
"workspaces,1,4,default"
|
|
||||||
];
|
|
||||||
};
|
|
||||||
"$mod" = "SUPER";
|
|
||||||
bind = [
|
|
||||||
"$mod,Return,exec,kitty"
|
|
||||||
"$mod,tab,cyclenext"
|
|
||||||
"SUPERSHIFT,Q,killactive"
|
|
||||||
"$mod,SPACE,exec,wofi-launch"
|
|
||||||
"$mod,P,exec,wofi-power"
|
|
||||||
"SUPERSHIFT,m,exit"
|
|
||||||
"$mod,H,movefocus,l"
|
|
||||||
"$mod,J,movefocus,u"
|
|
||||||
"$mod,K,movefocus,d"
|
|
||||||
"$mod,L,movefocus,r"
|
|
||||||
"SUPERSHIFT,H,movewindow,l"
|
|
||||||
"SUPERSHIFT,J,movewindow,u"
|
|
||||||
"SUPERSHIFT,K,movewindow,d"
|
|
||||||
"SUPERSHIFT,L,movewindow,r"
|
|
||||||
"$mod,F,togglefloating"
|
|
||||||
"$mod,X,togglespecialworkspace"
|
|
||||||
"SUPERSHIFT,X,movetoworkspace,special"
|
|
||||||
"$mod,Print,exec,grim - | wl-copy && notify-send 'Screenshot Copied to Clipboard'"
|
|
||||||
"SUPERSHIFT,S,exec,slurp | grim -g - /tmp/photo && wl-copy < /tmp/photo && notify-send 'Screenshot Copied to Clipboard'"
|
|
||||||
"$mod,f11,fullscreen,0"
|
|
||||||
",XF86AudioLowerVolume,exec,wpctl set-volume @DEFAULT_SINK@ 1%-"
|
|
||||||
",XF86AudioRaiseVolume,exec,wpctl set-volume @DEFAULT_SINK@ 1%+"
|
|
||||||
",XF86AudioMute,exec,wpctl set-mute @DEFAULT_SINK@ toggle"
|
|
||||||
",XF86AudioPlay,exec,playerctl play-pause"
|
|
||||||
",XF86AudioPrev,exec,playerctl previous"
|
|
||||||
",XF86AudioNext,exec,playerctl next"
|
|
||||||
]
|
|
||||||
++ (
|
|
||||||
builtins.concatLists (builtins.genList (
|
|
||||||
x: let
|
|
||||||
ws = let
|
|
||||||
c = (x+1);
|
|
||||||
in
|
|
||||||
builtins.toString (x);
|
|
||||||
in [
|
|
||||||
"$mod,${ws},workspace,${ws}"
|
|
||||||
"ALT,${ws},movetoworkspace,${ws}"
|
|
||||||
]
|
|
||||||
)
|
|
||||||
10)
|
|
||||||
);
|
|
||||||
bindm = [
|
|
||||||
"$mod,mouse:272,movewindow"
|
|
||||||
"$mod,mouse:273,resizewindow"
|
|
||||||
];
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
@ -1,18 +1,16 @@
|
||||||
{ config, pkgs, inputs, ... }:
|
{ config, pkgs, inputs, ... }:
|
||||||
|
let
|
||||||
|
hyprland = inputs.hyprland.packages.${pkgs.system}.hyprland;
|
||||||
|
in
|
||||||
{
|
{
|
||||||
# these are necessary for the config to function correctly
|
# these are necessary for the config to function correctly
|
||||||
imports = [
|
imports = [
|
||||||
./kitty.nix
|
./kitty.nix
|
||||||
./waybar.nix
|
./waybar.nix
|
||||||
./wofi.nix
|
./wofi.nix
|
||||||
# ./hypridle.nix # TODO: find out why these bitches not work
|
|
||||||
# ./hyprlock.nix
|
|
||||||
./dunst.nix
|
./dunst.nix
|
||||||
];
|
];
|
||||||
home.packages = with pkgs; [
|
home.packages = with pkgs; [
|
||||||
hyprland
|
|
||||||
|
|
||||||
# I always want these with hyprland anyways
|
# I always want these with hyprland anyways
|
||||||
libnotify # to enable the notify-send command
|
libnotify # to enable the notify-send command
|
||||||
wl-clipboard
|
wl-clipboard
|
||||||
|
|
@ -24,9 +22,13 @@
|
||||||
playerctl
|
playerctl
|
||||||
];
|
];
|
||||||
|
|
||||||
|
|
||||||
|
xdg.portal.configPackages = [ hyprland ];
|
||||||
|
|
||||||
services.playerctld.enable = true;
|
services.playerctld.enable = true;
|
||||||
wayland.windowManager.hyprland = {
|
wayland.windowManager.hyprland = {
|
||||||
enable = true;
|
enable = true;
|
||||||
|
package = hyprland;
|
||||||
settings = {
|
settings = {
|
||||||
monitor = [
|
monitor = [
|
||||||
"DP-3,2560x1440@360,2560x0,1"
|
"DP-3,2560x1440@360,2560x0,1"
|
||||||
|
|
@ -122,5 +124,4 @@
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,8 +0,0 @@
|
||||||
{ config, pkgs, inputs, ... }:
|
|
||||||
|
|
||||||
{
|
|
||||||
programs.hyprlock = {
|
|
||||||
enable = true;
|
|
||||||
# TODO: find commands to turn on/off monitors
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
@ -1,88 +0,0 @@
|
||||||
{ config, pkgs, inputs, ... }:
|
|
||||||
|
|
||||||
{
|
|
||||||
home.packages = with pkgs; [
|
|
||||||
waybar
|
|
||||||
font-awesome
|
|
||||||
];
|
|
||||||
programs.waybar = {
|
|
||||||
enable = true;
|
|
||||||
settings = {
|
|
||||||
mainBar = {
|
|
||||||
layer = "top";
|
|
||||||
position = "top";
|
|
||||||
height = 28;
|
|
||||||
output = [
|
|
||||||
"HEADLESS-2"
|
|
||||||
];
|
|
||||||
modules-left = [ "hyprland/workspaces" "tray" "custom/pronouns" "custom/spotify" ];
|
|
||||||
modules-center = [ "hyprland/window" "clock" ];
|
|
||||||
modules-right = [ "custom/vpn" "wireplumber" "network" "cpu" "memory" "temperature" "custom/poweroff" ];
|
|
||||||
"clock" = {
|
|
||||||
tooltip-format = "<big>{:%Y %B}</big>\n\n<small>{calendar}</small>";
|
|
||||||
interval = 1;
|
|
||||||
format = "{:%H:%M:%S}";
|
|
||||||
format-alt = ":%Y-%m-%d %H:%M:%S}";
|
|
||||||
on-click-middle = "gnome-clocks";
|
|
||||||
calendar = {
|
|
||||||
weeks-pos = "left";
|
|
||||||
format = {
|
|
||||||
today = "<span color='#FF6666'><u>{}</u></span>";
|
|
||||||
weeks = "<span color='#707A8C'>{}</span>";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
"tray".spacing = 10;
|
|
||||||
"cpu" = {
|
|
||||||
format = "cpu: {usage}%";
|
|
||||||
tooltip = false;
|
|
||||||
};
|
|
||||||
"memory" = {
|
|
||||||
format = "mem: {}%";
|
|
||||||
};
|
|
||||||
"wireplumber" = {
|
|
||||||
format = "{volume}%";
|
|
||||||
};
|
|
||||||
"custom/vpn" = {
|
|
||||||
format = "VPN";
|
|
||||||
exec = "echo '{\"class\": \"connected\"}'";
|
|
||||||
exec-if = "test -d /proc/sys/net/ipv4/conf/tun0";
|
|
||||||
return-type = "json";
|
|
||||||
interval = 5;
|
|
||||||
};
|
|
||||||
"temperature" = {
|
|
||||||
thermal-zone = 2;
|
|
||||||
hwmon-path = "/sys/class/hwmon/hwmon2/temp1_input";
|
|
||||||
critical-threshold = 80;
|
|
||||||
format = "{temperatureC}°C {icon}";
|
|
||||||
format-icons = ["" "" ""];
|
|
||||||
};
|
|
||||||
"custom/poweroff" = {
|
|
||||||
format = "";
|
|
||||||
on-click = "wofi-power";
|
|
||||||
on-click-right = "swaylock";
|
|
||||||
};
|
|
||||||
"network" = {
|
|
||||||
format-wifi = "{essid} ({signalStrength}%) ";
|
|
||||||
format-ethernet = "{ipaddr}/{cidr} ";
|
|
||||||
tooltip-format = "{ifname} via {gwaddr} ";
|
|
||||||
format-linked = "{ifname} (No IP) ";
|
|
||||||
format-disconnected = "Disconnected ";
|
|
||||||
format-alt = "{ifname}: {ipaddr}/{cidr}";
|
|
||||||
};
|
|
||||||
"custom/pronouns" = {
|
|
||||||
format = "{}";
|
|
||||||
exec = "${config.xdg.configHome}/waybar/pronouns";
|
|
||||||
interval = 5;
|
|
||||||
};
|
|
||||||
"hyprland/workspaces" = {
|
|
||||||
format = "{name}";
|
|
||||||
on-click = "activate";
|
|
||||||
sort-by = "id";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
style = ../styles/waybar.css;
|
|
||||||
};
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
{ config, pkgs, inputs, ... }:
|
{ config, pkgs, lib, ... }:
|
||||||
|
|
||||||
{
|
{
|
||||||
home.packages = with pkgs; [
|
home.packages = with pkgs; [
|
||||||
|
|
@ -6,7 +6,7 @@
|
||||||
font-awesome
|
font-awesome
|
||||||
];
|
];
|
||||||
programs.waybar = {
|
programs.waybar = {
|
||||||
enable = true;
|
enable = lib.mkDefault true;
|
||||||
settings = {
|
settings = {
|
||||||
mainBar = {
|
mainBar = {
|
||||||
layer = "top";
|
layer = "top";
|
||||||
|
|
|
||||||
|
|
@ -10,21 +10,16 @@
|
||||||
'')
|
'')
|
||||||
(writeShellScriptBin "wofi-power" ''
|
(writeShellScriptBin "wofi-power" ''
|
||||||
lock="Lock"
|
lock="Lock"
|
||||||
logout="Logout"
|
|
||||||
poweroff="Poweroff"
|
poweroff="Poweroff"
|
||||||
reboot="Reboot"
|
reboot="Reboot"
|
||||||
sleep="Suspend"
|
sleep="Suspend"
|
||||||
|
|
||||||
selected_option=$(echo -e "$lock\n$logout\n$sleep\n$reboot\n$poweroff" | wofi --dmenu -i -p "Powermenu")
|
selected_option=$(echo -e "$lock\n$sleep\n$reboot\n$poweroff" | wofi --dmenu -i -p "Powermenu")
|
||||||
|
|
||||||
if [ "$selected_option" == "$lock" ]
|
if [ "$selected_option" == "$lock" ]
|
||||||
then
|
then
|
||||||
echo "lock"
|
echo "lock"
|
||||||
swaylock
|
swaylock
|
||||||
elif [ "$selected_option" == "$logout" ]
|
|
||||||
then
|
|
||||||
echo "logout"
|
|
||||||
loginctl terminate-user `whoami`
|
|
||||||
elif [ "$selected_option" == "$poweroff" ]
|
elif [ "$selected_option" == "$poweroff" ]
|
||||||
then
|
then
|
||||||
echo "poweroff"
|
echo "poweroff"
|
||||||
|
|
|
||||||
180
flake.lock
generated
180
flake.lock
generated
|
|
@ -131,7 +131,7 @@
|
||||||
},
|
},
|
||||||
"flake-utils": {
|
"flake-utils": {
|
||||||
"inputs": {
|
"inputs": {
|
||||||
"systems": "systems_4"
|
"systems": "systems_3"
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1701680307,
|
"lastModified": 1701680307,
|
||||||
|
|
@ -149,7 +149,7 @@
|
||||||
},
|
},
|
||||||
"flake-utils_2": {
|
"flake-utils_2": {
|
||||||
"inputs": {
|
"inputs": {
|
||||||
"systems": "systems_5"
|
"systems": "systems_4"
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1710146030,
|
"lastModified": 1710146030,
|
||||||
|
|
@ -228,41 +228,98 @@
|
||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"hypridle": {
|
"hyprcursor": {
|
||||||
"inputs": {
|
"inputs": {
|
||||||
"hyprlang": "hyprlang",
|
"hyprlang": "hyprlang",
|
||||||
"nixpkgs": [
|
"nixpkgs": [
|
||||||
|
"hyprland",
|
||||||
"nixpkgs"
|
"nixpkgs"
|
||||||
],
|
],
|
||||||
"systems": "systems"
|
"systems": [
|
||||||
|
"hyprland",
|
||||||
|
"systems"
|
||||||
|
]
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1710180874,
|
"lastModified": 1711466786,
|
||||||
"narHash": "sha256-ZSn3wXQuRz36Ta/L+UCFKuUVG6QpwK2QmRkPjpQprU4=",
|
"narHash": "sha256-sArxGyUBiCA1in+q6t0QqT+ZJiZ1PyBp7cNPKLmREM0=",
|
||||||
"owner": "hyprwm",
|
"owner": "hyprwm",
|
||||||
"repo": "hypridle",
|
"repo": "hyprcursor",
|
||||||
"rev": "4395339a2dc410bcf49f3e24f9ed3024fdb25b0a",
|
"rev": "d3876f34779cc03ee51e4aafc0d00a4f187c7544",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
"owner": "hyprwm",
|
"owner": "hyprwm",
|
||||||
"repo": "hypridle",
|
"repo": "hyprcursor",
|
||||||
|
"type": "github"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"hyprland": {
|
||||||
|
"inputs": {
|
||||||
|
"hyprcursor": "hyprcursor",
|
||||||
|
"hyprland-protocols": "hyprland-protocols",
|
||||||
|
"hyprlang": "hyprlang_2",
|
||||||
|
"nixpkgs": [
|
||||||
|
"nixpkgs"
|
||||||
|
],
|
||||||
|
"systems": "systems_2",
|
||||||
|
"wlroots": "wlroots",
|
||||||
|
"xdph": "xdph"
|
||||||
|
},
|
||||||
|
"locked": {
|
||||||
|
"lastModified": 1712160491,
|
||||||
|
"narHash": "sha256-OQmbZnMPex/66HmyD7SKN5eKcyLR6ZCzHn/i/YF61qE=",
|
||||||
|
"owner": "hyprwm",
|
||||||
|
"repo": "hyprland",
|
||||||
|
"rev": "93915502d2677b70382b7cba09620b445f6b832e",
|
||||||
|
"type": "github"
|
||||||
|
},
|
||||||
|
"original": {
|
||||||
|
"owner": "hyprwm",
|
||||||
|
"repo": "hyprland",
|
||||||
|
"type": "github"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"hyprland-protocols": {
|
||||||
|
"inputs": {
|
||||||
|
"nixpkgs": [
|
||||||
|
"hyprland",
|
||||||
|
"nixpkgs"
|
||||||
|
],
|
||||||
|
"systems": [
|
||||||
|
"hyprland",
|
||||||
|
"systems"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
"locked": {
|
||||||
|
"lastModified": 1691753796,
|
||||||
|
"narHash": "sha256-zOEwiWoXk3j3+EoF3ySUJmberFewWlagvewDRuWYAso=",
|
||||||
|
"owner": "hyprwm",
|
||||||
|
"repo": "hyprland-protocols",
|
||||||
|
"rev": "0c2ce70625cb30aef199cb388f99e19a61a6ce03",
|
||||||
|
"type": "github"
|
||||||
|
},
|
||||||
|
"original": {
|
||||||
|
"owner": "hyprwm",
|
||||||
|
"repo": "hyprland-protocols",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"hyprlang": {
|
"hyprlang": {
|
||||||
"inputs": {
|
"inputs": {
|
||||||
"nixpkgs": [
|
"nixpkgs": [
|
||||||
"hypridle",
|
"hyprland",
|
||||||
|
"hyprcursor",
|
||||||
"nixpkgs"
|
"nixpkgs"
|
||||||
]
|
],
|
||||||
|
"systems": "systems"
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1708212860,
|
"lastModified": 1709914708,
|
||||||
"narHash": "sha256-nW3Zrhh9RJcMTvOcXAaKADnJM/g6tDf3121lJtTHnYo=",
|
"narHash": "sha256-bR4o3mynoTa1Wi4ZTjbnsZ6iqVcPGriXp56bZh5UFTk=",
|
||||||
"owner": "hyprwm",
|
"owner": "hyprwm",
|
||||||
"repo": "hyprlang",
|
"repo": "hyprlang",
|
||||||
"rev": "11d5ccda071c153dfdc18ef65338956a51cef96a",
|
"rev": "a685493fdbeec01ca8ccdf1f3655c044a8ce2fe2",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
|
@ -274,10 +331,13 @@
|
||||||
"hyprlang_2": {
|
"hyprlang_2": {
|
||||||
"inputs": {
|
"inputs": {
|
||||||
"nixpkgs": [
|
"nixpkgs": [
|
||||||
"hyprlock",
|
"hyprland",
|
||||||
"nixpkgs"
|
"nixpkgs"
|
||||||
],
|
],
|
||||||
"systems": "systems_2"
|
"systems": [
|
||||||
|
"hyprland",
|
||||||
|
"systems"
|
||||||
|
]
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1711250455,
|
"lastModified": 1711250455,
|
||||||
|
|
@ -293,28 +353,6 @@
|
||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"hyprlock": {
|
|
||||||
"inputs": {
|
|
||||||
"hyprlang": "hyprlang_2",
|
|
||||||
"nixpkgs": [
|
|
||||||
"nixpkgs"
|
|
||||||
],
|
|
||||||
"systems": "systems_3"
|
|
||||||
},
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1711884603,
|
|
||||||
"narHash": "sha256-y1Om75muuJcEoLd/FOYGIZ5/ja/Mc4iBX/9S7vWF0C8=",
|
|
||||||
"owner": "hyprwm",
|
|
||||||
"repo": "hyprlock",
|
|
||||||
"rev": "071ebcefb9070e4397d75103f5f535b58dacf250",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "hyprwm",
|
|
||||||
"repo": "hyprlock",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"nix-colors": {
|
"nix-colors": {
|
||||||
"inputs": {
|
"inputs": {
|
||||||
"base16-schemes": "base16-schemes",
|
"base16-schemes": "base16-schemes",
|
||||||
|
|
@ -445,8 +483,7 @@
|
||||||
"automapaper": "automapaper",
|
"automapaper": "automapaper",
|
||||||
"disko": "disko",
|
"disko": "disko",
|
||||||
"home-manager": "home-manager",
|
"home-manager": "home-manager",
|
||||||
"hypridle": "hypridle",
|
"hyprland": "hyprland",
|
||||||
"hyprlock": "hyprlock",
|
|
||||||
"nix-colors": "nix-colors",
|
"nix-colors": "nix-colors",
|
||||||
"nixpkgs": "nixpkgs",
|
"nixpkgs": "nixpkgs",
|
||||||
"nixvim": "nixvim"
|
"nixvim": "nixvim"
|
||||||
|
|
@ -484,16 +521,16 @@
|
||||||
},
|
},
|
||||||
"systems_3": {
|
"systems_3": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1689347949,
|
"lastModified": 1681028828,
|
||||||
"narHash": "sha256-12tWmuL2zgBgZkdoB6qXZsgJEH9LR3oUgpaQq2RbI80=",
|
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
|
||||||
"owner": "nix-systems",
|
"owner": "nix-systems",
|
||||||
"repo": "default-linux",
|
"repo": "default",
|
||||||
"rev": "31732fcf5e8fea42e59c2488ad31a0e651500f68",
|
"rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
"owner": "nix-systems",
|
"owner": "nix-systems",
|
||||||
"repo": "default-linux",
|
"repo": "default",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
@ -512,18 +549,55 @@
|
||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"systems_5": {
|
"wlroots": {
|
||||||
|
"flake": false,
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1681028828,
|
"host": "gitlab.freedesktop.org",
|
||||||
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
|
"lastModified": 1709983277,
|
||||||
"owner": "nix-systems",
|
"narHash": "sha256-wXWIJLd4F2JZeMaihWVDW/yYXCLEC8OpeNJZg9a9ly8=",
|
||||||
"repo": "default",
|
"owner": "wlroots",
|
||||||
"rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
|
"repo": "wlroots",
|
||||||
|
"rev": "50eae512d9cecbf0b3b1898bb1f0b40fa05fe19b",
|
||||||
|
"type": "gitlab"
|
||||||
|
},
|
||||||
|
"original": {
|
||||||
|
"host": "gitlab.freedesktop.org",
|
||||||
|
"owner": "wlroots",
|
||||||
|
"repo": "wlroots",
|
||||||
|
"rev": "50eae512d9cecbf0b3b1898bb1f0b40fa05fe19b",
|
||||||
|
"type": "gitlab"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"xdph": {
|
||||||
|
"inputs": {
|
||||||
|
"hyprland-protocols": [
|
||||||
|
"hyprland",
|
||||||
|
"hyprland-protocols"
|
||||||
|
],
|
||||||
|
"hyprlang": [
|
||||||
|
"hyprland",
|
||||||
|
"hyprlang"
|
||||||
|
],
|
||||||
|
"nixpkgs": [
|
||||||
|
"hyprland",
|
||||||
|
"nixpkgs"
|
||||||
|
],
|
||||||
|
"systems": [
|
||||||
|
"hyprland",
|
||||||
|
"systems"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
"locked": {
|
||||||
|
"lastModified": 1709299639,
|
||||||
|
"narHash": "sha256-jYqJM5khksLIbqSxCLUUcqEgI+O2LdlSlcMEBs39CAU=",
|
||||||
|
"owner": "hyprwm",
|
||||||
|
"repo": "xdg-desktop-portal-hyprland",
|
||||||
|
"rev": "2d2fb547178ec025da643db57d40a971507b82fe",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
"owner": "nix-systems",
|
"owner": "hyprwm",
|
||||||
"repo": "default",
|
"repo": "xdg-desktop-portal-hyprland",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
11
flake.nix
11
flake.nix
|
|
@ -25,13 +25,8 @@
|
||||||
inputs.nixpkgs.follows = "nixpkgs";
|
inputs.nixpkgs.follows = "nixpkgs";
|
||||||
};
|
};
|
||||||
|
|
||||||
hypridle = {
|
hyprland = {
|
||||||
url = "github:hyprwm/hypridle";
|
url = "github:hyprwm/hyprland";
|
||||||
inputs.nixpkgs.follows = "nixpkgs";
|
|
||||||
};
|
|
||||||
|
|
||||||
hyprlock = {
|
|
||||||
url = "github:hyprwm/hyprlock";
|
|
||||||
inputs.nixpkgs.follows = "nixpkgs";
|
inputs.nixpkgs.follows = "nixpkgs";
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
@ -42,7 +37,7 @@
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
outputs = { self, nixpkgs, nix-colors, automapaper, disko, home-manager, ... }@inputs:
|
outputs = { self, nixpkgs, nix-colors, automapaper, disko, home-manager, hyprland, ... }@inputs:
|
||||||
{
|
{
|
||||||
nixosConfigurations = {
|
nixosConfigurations = {
|
||||||
default = nixpkgs.lib.nixosSystem {
|
default = nixpkgs.lib.nixosSystem {
|
||||||
|
|
|
||||||
|
|
@ -62,17 +62,22 @@
|
||||||
};
|
};
|
||||||
|
|
||||||
services.xserver = {
|
services.xserver = {
|
||||||
enable = true;
|
|
||||||
displayManager = {
|
|
||||||
sddm.enable = true;
|
|
||||||
defaultSession = "hyprland";
|
|
||||||
};
|
|
||||||
xkb = {
|
xkb = {
|
||||||
layout = "us";
|
layout = "us";
|
||||||
variant = "intl";
|
variant = "intl";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
services.greetd = {
|
||||||
|
enable = true;
|
||||||
|
settings = rec {
|
||||||
|
initial_session = {
|
||||||
|
command = "${pkgs.hyprland}/bin/Hyprland";
|
||||||
|
user = "noa";
|
||||||
|
};
|
||||||
|
default_session = initial_session;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
# Configure console keymap
|
# Configure console keymap
|
||||||
console.keyMap = "us-acentos";
|
console.keyMap = "us-acentos";
|
||||||
|
|
@ -108,7 +113,6 @@
|
||||||
# List packages installed in system profile. To search, run:
|
# List packages installed in system profile. To search, run:
|
||||||
# $ nix search wget
|
# $ nix search wget
|
||||||
environment.systemPackages = with pkgs; [
|
environment.systemPackages = with pkgs; [
|
||||||
sddm
|
|
||||||
git
|
git
|
||||||
zsh
|
zsh
|
||||||
];
|
];
|
||||||
|
|
@ -135,6 +139,7 @@
|
||||||
|
|
||||||
programs.hyprland = {
|
programs.hyprland = {
|
||||||
enable = true;
|
enable = true;
|
||||||
|
package = inputs.hyprland.packages.${pkgs.system}.hyprland;
|
||||||
portalPackage = pkgs.xdg-desktop-portal-hyprland;
|
portalPackage = pkgs.xdg-desktop-portal-hyprland;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -5,7 +5,7 @@
|
||||||
[
|
[
|
||||||
inputs.nixvim.homeManagerModules.nixvim
|
inputs.nixvim.homeManagerModules.nixvim
|
||||||
../../common/zsh.nix
|
../../common/zsh.nix
|
||||||
../../common/hyprland.nix
|
../../modules/hyprland.nix
|
||||||
../../common/git.nix
|
../../common/git.nix
|
||||||
../../common/nvim/nvim.nix
|
../../common/nvim/nvim.nix
|
||||||
../../common/discord/discord.nix
|
../../common/discord/discord.nix
|
||||||
|
|
@ -29,6 +29,8 @@
|
||||||
|
|
||||||
nixpkgs.config.allowUnfree = true;
|
nixpkgs.config.allowUnfree = true;
|
||||||
|
|
||||||
|
modules.hyprland.enable = true;
|
||||||
|
|
||||||
# The home.packages option allows you to install Nix packages into your
|
# The home.packages option allows you to install Nix packages into your
|
||||||
# environment.
|
# environment.
|
||||||
home.packages = with pkgs; [
|
home.packages = with pkgs; [
|
||||||
|
|
@ -107,7 +109,6 @@
|
||||||
xdg.portal = {
|
xdg.portal = {
|
||||||
enable = true;
|
enable = true;
|
||||||
extraPortals = [ pkgs.xdg-desktop-portal-hyprland ];
|
extraPortals = [ pkgs.xdg-desktop-portal-hyprland ];
|
||||||
configPackages = [ pkgs.hyprland ];
|
|
||||||
};
|
};
|
||||||
|
|
||||||
dconf = {
|
dconf = {
|
||||||
|
|
|
||||||
141
modules/hyprland.nix
Normal file
141
modules/hyprland.nix
Normal file
|
|
@ -0,0 +1,141 @@
|
||||||
|
{ config, lib, pkgs, inputs, ... }:
|
||||||
|
let
|
||||||
|
hyprland = inputs.hyprland.packages.${pkgs.system}.hyprland;
|
||||||
|
cfg = config.modules.hyprland;
|
||||||
|
in
|
||||||
|
{
|
||||||
|
options = {
|
||||||
|
cfg.enable = lib.mkEnableOption "enable hyprland";
|
||||||
|
# TODO: make custom terminal support work better
|
||||||
|
# cfg.terminal = lib.mkOption {
|
||||||
|
# type = lib.types.package;
|
||||||
|
# default = pkgs.kitty;
|
||||||
|
# description = "What terminal emulator should be used in hyprland";
|
||||||
|
# };
|
||||||
|
};
|
||||||
|
|
||||||
|
config = lib.mkIf cfg.enable {
|
||||||
|
# these are necessary for the config to function correctly
|
||||||
|
imports = [
|
||||||
|
./kitty.nix
|
||||||
|
./waybar.nix
|
||||||
|
./wofi.nix
|
||||||
|
./dunst.nix
|
||||||
|
];
|
||||||
|
home.packages = with pkgs; [
|
||||||
|
# I always want these with hyprland anyways
|
||||||
|
libnotify # to enable the notify-send command
|
||||||
|
wl-clipboard
|
||||||
|
|
||||||
|
slurp
|
||||||
|
grim
|
||||||
|
|
||||||
|
hypridle # TODO: remove when fixed with config
|
||||||
|
playerctl
|
||||||
|
];
|
||||||
|
|
||||||
|
programs.waybar.enable = true;
|
||||||
|
|
||||||
|
xdg.portal.configPackages = [ hyprland ];
|
||||||
|
|
||||||
|
services.playerctld.enable = true;
|
||||||
|
wayland.windowManager.hyprland = {
|
||||||
|
enable = true;
|
||||||
|
package = hyprland;
|
||||||
|
settings = {
|
||||||
|
monitor = [
|
||||||
|
"DP-3,2560x1440@360,2560x0,1"
|
||||||
|
"DP-2,2560x1440@144,0x0,1"
|
||||||
|
];
|
||||||
|
windowrulev2 = [
|
||||||
|
"opacity 1.0 0.6,class:^(kitty)$"
|
||||||
|
"stayfocused,class:^(wofi)$"
|
||||||
|
];
|
||||||
|
env = [
|
||||||
|
"WLR_NO_HARDWARE_CURSORS,1"
|
||||||
|
];
|
||||||
|
exec-once = [
|
||||||
|
"waybar"
|
||||||
|
"dunst"
|
||||||
|
"automapaper -C ${config.xdg.configHome}/automapaper/config.toml"
|
||||||
|
"automapaper -C ${config.xdg.configHome}/automapaper/config2nd.toml"
|
||||||
|
"hyprctl dispatcher focusmonitor 1"
|
||||||
|
"hypridle"
|
||||||
|
];
|
||||||
|
general = {
|
||||||
|
sensitivity = "1.2";
|
||||||
|
gaps_in = "2";
|
||||||
|
gaps_out = "3";
|
||||||
|
border_size = "3";
|
||||||
|
"col.active_border"="0xff950fad";
|
||||||
|
"col.inactive_border"="0xff26052e";
|
||||||
|
};
|
||||||
|
misc = {
|
||||||
|
key_press_enables_dpms = true;
|
||||||
|
};
|
||||||
|
decoration = {
|
||||||
|
rounding = "6";
|
||||||
|
active_opacity = "1";
|
||||||
|
inactive_opacity = "1";
|
||||||
|
};
|
||||||
|
workspace = [
|
||||||
|
"DP-3,1"
|
||||||
|
"DP-2,2"
|
||||||
|
];
|
||||||
|
animations = {
|
||||||
|
enabled = "1";
|
||||||
|
animation = [
|
||||||
|
"windows,1,2,default"
|
||||||
|
"border,1,10,default"
|
||||||
|
"fade,0,5,default"
|
||||||
|
"workspaces,1,4,default"
|
||||||
|
];
|
||||||
|
};
|
||||||
|
"$mod" = "SUPER";
|
||||||
|
bind = [
|
||||||
|
"$mod,Return,exec,${pkgs.kitty.pname}"
|
||||||
|
"$mod,tab,cyclenext"
|
||||||
|
"SUPERSHIFT,Q,killactive"
|
||||||
|
"$mod,SPACE,exec,wofi-launch"
|
||||||
|
"$mod,P,exec,wofi-power"
|
||||||
|
"SUPERSHIFT,m,exit"
|
||||||
|
"$mod,H,movefocus,l"
|
||||||
|
"$mod,J,movefocus,u"
|
||||||
|
"$mod,K,movefocus,d"
|
||||||
|
"$mod,L,movefocus,r"
|
||||||
|
"SUPERSHIFT,H,movewindow,l"
|
||||||
|
"SUPERSHIFT,J,movewindow,u"
|
||||||
|
"SUPERSHIFT,K,movewindow,d"
|
||||||
|
"SUPERSHIFT,L,movewindow,r"
|
||||||
|
"$mod,F,togglefloating"
|
||||||
|
"$mod,X,togglespecialworkspace"
|
||||||
|
"SUPERSHIFT,X,movetoworkspace,special"
|
||||||
|
"$mod,Print,exec,grim - | wl-copy && notify-send 'Screenshot Copied to Clipboard'"
|
||||||
|
"SUPERSHIFT,S,exec,slurp | grim -g - /tmp/photo && wl-copy < /tmp/photo && notify-send 'Screenshot Copied to Clipboard'"
|
||||||
|
"$mod,f11,fullscreen,0"
|
||||||
|
",XF86AudioLowerVolume,exec,wpctl set-volume @DEFAULT_SINK@ 1%-"
|
||||||
|
",XF86AudioRaiseVolume,exec,wpctl set-volume @DEFAULT_SINK@ 1%+"
|
||||||
|
",XF86AudioMute,exec,wpctl set-mute @DEFAULT_SINK@ toggle"
|
||||||
|
",XF86AudioPlay,exec,playerctl play-pause"
|
||||||
|
",XF86AudioPrev,exec,playerctl previous"
|
||||||
|
",XF86AudioNext,exec,playerctl next"
|
||||||
|
]
|
||||||
|
++ (
|
||||||
|
builtins.concatLists (builtins.genList (
|
||||||
|
x: let
|
||||||
|
ws = builtins.toString (x);
|
||||||
|
in [
|
||||||
|
"$mod,${ws},workspace,${ws}"
|
||||||
|
"ALT,${ws},movetoworkspace,${ws}"
|
||||||
|
]
|
||||||
|
)
|
||||||
|
10)
|
||||||
|
);
|
||||||
|
bindm = [
|
||||||
|
"$mod,mouse:272,movewindow"
|
||||||
|
"$mod,mouse:273,resizewindow"
|
||||||
|
];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
||||||
Loading…
Add table
Add a link
Reference in a new issue