465 lines
10 KiB
Nix
465 lines
10 KiB
Nix
{
|
|
self,
|
|
pkgs,
|
|
inputs,
|
|
lib,
|
|
config,
|
|
...
|
|
}: {
|
|
wayland.windowManager.hyprland = {
|
|
enable = true;
|
|
systemd.enable = false;
|
|
xwayland.enable = true;
|
|
settings = {
|
|
"$mod" = "SUPER";
|
|
|
|
exec-once = [
|
|
"hyprctl setcursor 24"
|
|
];
|
|
|
|
monitor = [
|
|
"eDP-1, 2560x1600@240, 0x0, 1.25"
|
|
];
|
|
|
|
bind = [
|
|
"$mod, Return, exec, kitty"
|
|
"$mod, B, exec, firefox"
|
|
"$mod, Space, exec, rofi -show drun"
|
|
"$mod, C, exec, rofi -show calc"
|
|
"$mod, P, exec, rofi -show powermenu -modi powermenu:${pkgs.rofi-power-menu}/bin/rofi-power-menu"
|
|
|
|
"$mod, 1, workspace, 1"
|
|
"$mod, 2, workspace, 2"
|
|
"$mod, 3, workspace, 3"
|
|
"$mod, 4, workspace, 4"
|
|
"$mod, 5, workspace, 5"
|
|
"$mod, 6, workspace, 6"
|
|
"$mod, 7, workspace, 7"
|
|
"$mod, 8, workspace, 8"
|
|
"$mod, 9, workspace, 9"
|
|
|
|
"$mod_SHIFT, 1, movetoworkspacesilent, 1"
|
|
"$mod_SHIFT, 2, movetoworkspacesilent, 2"
|
|
"$mod_SHIFT, 3, movetoworkspacesilent, 3"
|
|
"$mod_SHIFT, 4, movetoworkspacesilent, 4"
|
|
"$mod_SHIFT, 5, movetoworkspacesilent, 5"
|
|
"$mod_SHIFT, 6, movetoworkspacesilent, 6"
|
|
"$mod_SHIFT, 7, movetoworkspacesilent, 7"
|
|
"$mod_SHIFT, 8, movetoworkspacesilent, 8"
|
|
"$mod_SHIFT, 9, movetoworkspacesilent, 9"
|
|
|
|
"$mod_SHIFT, left, movewindow, l"
|
|
"$mod_SHIFT, right, movewindow, r"
|
|
"$mod_SHIFT, up, movewindow, u"
|
|
"$mod_SHIFT, down, movewindow, d"
|
|
|
|
"$mod, left, resizeactive, -20 0"
|
|
"$mod, right, resizeactive, 20 0"
|
|
"$mod, up, resizeactive, 0 -20"
|
|
"$mod, down, resizeactive, 0 20"
|
|
|
|
"$mod_SHIFT, S, setfloating"
|
|
"$mod_SHIFT, T, settiled"
|
|
"$mod_SHIFT, F, fullscreen"
|
|
|
|
"$mod, V, killactive"
|
|
"$mod_ALT, Q, exec, loginctl terminate-user \"\""
|
|
"$mod_ALT, R, exec, hyprctl reload"
|
|
];
|
|
|
|
bindm = [
|
|
"$mod, mouse:272, movewindow"
|
|
];
|
|
|
|
general = {
|
|
border_size = 1;
|
|
gaps_out = "0, 8, 8, 8";
|
|
};
|
|
|
|
dwindle = {
|
|
preserve_split = true;
|
|
smart_split = false;
|
|
smart_resizing = false;
|
|
};
|
|
|
|
decoration = {
|
|
rounding = 10;
|
|
shadow = {
|
|
range = 5;
|
|
};
|
|
};
|
|
|
|
gestures = {
|
|
workspace_swipe = true;
|
|
workspace_swipe_create_new = true;
|
|
workspace_swipe_min_speed_to_force = 0;
|
|
};
|
|
|
|
misc = {
|
|
font_family = "SFProDisplay Nerd Font";
|
|
};
|
|
};
|
|
};
|
|
|
|
programs.waybar = {
|
|
enable = true;
|
|
systemd.enable = true;
|
|
package = pkgs.waybar.overrideAttrs (prev: {
|
|
version = "git";
|
|
mesonFlags = prev.mesonFlags ++ (lib.mapAttrsToList lib.mesonEnable {"cava" = false;});
|
|
src = pkgs.fetchFromGitHub {
|
|
owner = "Alexays";
|
|
repo = "Waybar";
|
|
rev = "ac08b752e38986f4ddcc13d257aea2fafcedbc92";
|
|
sha256 = "sha256-sbzyQjOag5OC7rSrMW68srjd1k62i9qLmtmFHVu73eA=";
|
|
};
|
|
patches = [];
|
|
});
|
|
settings = {
|
|
mainBar = {
|
|
layer = "top";
|
|
position = "top";
|
|
margin = "8";
|
|
|
|
modules-left = ["custom/nixicon" "hyprland/workspaces" "hyprland/window"];
|
|
modules-center = ["clock"];
|
|
modules-right = ["tray"];
|
|
|
|
"custom/nixicon" = {
|
|
format = " ";
|
|
tooltip = false;
|
|
};
|
|
|
|
clock = {
|
|
interval = 1;
|
|
locale = "en_US.utf8";
|
|
format = "{:L%r}";
|
|
format-alt = "{:L%r, %A, %B %d %Y}";
|
|
timezone = "America/Los_Angeles";
|
|
tooltip-format = "<tt><small>{calendar}</small></tt>";
|
|
calendar = {
|
|
mode = "year";
|
|
mode-mon-col = 3;
|
|
weeks-pos = "right";
|
|
format = {
|
|
months = "<span color='#fab387'><b>{}</b></span>";
|
|
days = "<span color='#f5e0dc'><b>{}</b></span>";
|
|
weeks = "<span color='#a6e3a1'><b>W{}</b></span>";
|
|
weekdays = "<span color='#f9e2af'><b>{}</b></span>";
|
|
today = "<span color='#f38ba8'><b><u>{}</u></b></span>";
|
|
};
|
|
};
|
|
};
|
|
|
|
"hyprland/workspaces" = {
|
|
active-only = false;
|
|
all-outputs = true;
|
|
persistent-workspaces = {
|
|
"*" = 9;
|
|
};
|
|
};
|
|
|
|
"hyprland/window" = {
|
|
icon = true;
|
|
max-length = 50;
|
|
};
|
|
|
|
tray = {
|
|
icon-size = 21;
|
|
spacing = 10;
|
|
show-passive-items = true;
|
|
};
|
|
};
|
|
};
|
|
style = ''
|
|
* {
|
|
font-family: "SF ProDisplay Nerd Font";
|
|
border: none;
|
|
border-radius: 0;
|
|
}
|
|
|
|
window#waybar {
|
|
border-radius: 10px;
|
|
}
|
|
|
|
tooltip {
|
|
background-color: #1e1e2e;
|
|
border: 1px solid #f5c2e7;
|
|
border-radius: 10px;
|
|
}
|
|
|
|
#window {
|
|
margin-left: 10px;
|
|
}
|
|
|
|
#custom-nixicon {
|
|
font-size: 24px;
|
|
color: #7EBAE4;
|
|
}
|
|
|
|
#workspaces {
|
|
margin-top: 5px;
|
|
margin-bottom: 5px;
|
|
}
|
|
|
|
#workspaces button {
|
|
background-color: #313244;
|
|
|
|
border-bottom-style: solid;
|
|
border-color: #000000;
|
|
border-width: 3px;
|
|
}
|
|
|
|
#workspaces button.empty {
|
|
border-bottom-style: none;
|
|
}
|
|
|
|
#workspaces button.active {
|
|
border-bottom-style: solid;
|
|
border-color: white;
|
|
border-width: 3px;
|
|
}
|
|
|
|
#workspaces button.urgent {
|
|
border-bottom-style: solid;
|
|
border-color: red;
|
|
border-width: 3px;
|
|
|
|
animation: blinker 1s step-start infinite;
|
|
}
|
|
|
|
#workspaces button:nth-child(1) {
|
|
border-radius: 5px 0px 0px 5px;
|
|
}
|
|
|
|
#workspaces button:nth-child(9) {
|
|
border-radius: 0px 5px 5px 0px;
|
|
}
|
|
|
|
#tray {
|
|
border-radius: 0px 5px 5px 0px;
|
|
margin: 5px;
|
|
padding: 5px;
|
|
background-color: #313244;
|
|
}
|
|
|
|
@keyframes blinker {
|
|
50% {
|
|
opacity: 0;
|
|
}
|
|
}
|
|
'';
|
|
};
|
|
|
|
programs.rofi = {
|
|
enable = true;
|
|
package = pkgs.rofi-wayland;
|
|
font = "SFProDisplay Nerd Font 10";
|
|
location = "center";
|
|
terminal = "${pkgs.kitty}/bin/kitty";
|
|
extraConfig = {
|
|
modi = "run,drun,window,calc";
|
|
show-icons = true;
|
|
drun-display-format = "{icon} {name}";
|
|
location = 0;
|
|
disable-history = false;
|
|
hide-scrollbar = true;
|
|
display-drun = " Apps ";
|
|
display-run = " Run ";
|
|
display-window = " Window";
|
|
display-calc = " Calc";
|
|
sidebar-mode = true;
|
|
};
|
|
theme = let
|
|
inherit (config.lib.formats.rasi) mkLiteral;
|
|
in {
|
|
listview = {
|
|
columns = 1;
|
|
lines = 15;
|
|
};
|
|
|
|
window = {
|
|
border-color = mkLiteral "#f5c2e7";
|
|
border-radius = mkLiteral "10px";
|
|
};
|
|
|
|
"element selected" = {
|
|
background-color = mkLiteral "#313244";
|
|
};
|
|
};
|
|
plugins = with pkgs; [
|
|
rofi-power-menu
|
|
(rofi-calc.override
|
|
{rofi-unwrapped = rofi-wayland-unwrapped;})
|
|
];
|
|
};
|
|
|
|
programs.hyprlock.enable = true;
|
|
# services.hypridle.enable = true;
|
|
|
|
services.mako = {
|
|
enable = true;
|
|
actions = true;
|
|
borderRadius = 10;
|
|
defaultTimeout = 5000;
|
|
font = "SFProDisplay Nerd Font 10";
|
|
};
|
|
|
|
services.xsettingsd = {
|
|
enable = true;
|
|
settings = {
|
|
"Gtk/CursorThemeName" = "catppuccin-mocha-pink-cursors";
|
|
"Gtk/CursorThemeSize" = 30;
|
|
"Xft/Hinting" = 0;
|
|
"Xft/HintStyle" = "hintnone";
|
|
"Xft/Antialias" = 1;
|
|
"Xft/RGBA" = "rgb";
|
|
};
|
|
};
|
|
|
|
xresources.properties = {
|
|
"Xft.antialias" = 1;
|
|
"Xft.hinting" = 0;
|
|
"Xft.rgba" = "rgb";
|
|
"Xft.hintstyle" = "hintnone";
|
|
};
|
|
|
|
services.flatpak.overrides = {
|
|
global = {
|
|
Context.sockets = ["wayland" "!x11" "!fallback-x11"];
|
|
|
|
Environment = {
|
|
XCURSOR_PATH = "/run/host/user-share/icons:/run/host/share/icons";
|
|
};
|
|
};
|
|
|
|
"com.discordapp.Discord".Context = {
|
|
sockets = ["x11"];
|
|
};
|
|
};
|
|
|
|
home.pointerCursor = {
|
|
gtk.enable = true;
|
|
x11.enable = true;
|
|
hyprcursor = {
|
|
enable = true;
|
|
size = 24;
|
|
};
|
|
size = 24;
|
|
};
|
|
|
|
gtk = {
|
|
enable = true;
|
|
font = {
|
|
package = inputs.apple-fonts.packages.${pkgs.system}.sf-pro-nerd;
|
|
name = "SFProDisplay Nerd Font";
|
|
size = 10;
|
|
};
|
|
};
|
|
|
|
qt = {
|
|
enable = true;
|
|
style.name = "kvantum";
|
|
platformTheme.name = "kvantum";
|
|
};
|
|
|
|
fonts.fontconfig = {
|
|
enable = true;
|
|
|
|
defaultFonts = {
|
|
emoji = ["Noto Color Emoji"];
|
|
monospace = ["SFMono Nerd Font"];
|
|
sansSerif = ["SFProDisplay Nerd Font"];
|
|
serif = ["SFProDisplay Nerd Font"];
|
|
};
|
|
};
|
|
|
|
catppuccin = {
|
|
gtk = {
|
|
enable = true;
|
|
gnomeShellTheme = true;
|
|
accent = "pink";
|
|
flavor = "mocha";
|
|
icon = {
|
|
enable = true;
|
|
accent = "pink";
|
|
flavor = "mocha";
|
|
};
|
|
};
|
|
cursors = {
|
|
enable = true;
|
|
accent = "pink";
|
|
flavor = "mocha";
|
|
};
|
|
hyprland = {
|
|
enable = true;
|
|
accent = "pink";
|
|
flavor = "mocha";
|
|
};
|
|
hyprlock = {
|
|
enable = true;
|
|
accent = "pink";
|
|
flavor = "mocha";
|
|
};
|
|
waybar = {
|
|
enable = true;
|
|
flavor = "mocha";
|
|
};
|
|
kvantum = {
|
|
enable = true;
|
|
accent = "pink";
|
|
flavor = "mocha";
|
|
};
|
|
mako = {
|
|
enable = true;
|
|
accent = "pink";
|
|
flavor = "mocha";
|
|
};
|
|
rofi = {
|
|
enable = true;
|
|
flavor = "mocha";
|
|
};
|
|
};
|
|
|
|
systemd.user.services = {
|
|
mako = {
|
|
Unit = {
|
|
Description = "mako";
|
|
PartOf = ["graphical-session.target"];
|
|
After = ["graphical-session.target"];
|
|
};
|
|
Service = {
|
|
Type = "dbus";
|
|
BusName = "org.freedesktop.Notifications";
|
|
ExecStart = "${pkgs.mako}/bin/mako";
|
|
ExecReload = "${pkgs.mako}/bin/makoctl reload";
|
|
Restart = "on-failure";
|
|
RestartSec = 1;
|
|
TimeoutStopSec = 10;
|
|
};
|
|
Install = {
|
|
WantedBy = ["graphical-session.target"];
|
|
};
|
|
};
|
|
waybar = {
|
|
Unit = {
|
|
After = lib.mkForce ["graphical-session.target"];
|
|
};
|
|
};
|
|
};
|
|
|
|
home.sessionVariables.NIXOS_OZONE_WL = "1";
|
|
home.packages = with pkgs; [
|
|
hyprpicker
|
|
hyprsunset
|
|
|
|
# Fonts
|
|
inputs.apple-fonts.packages.${pkgs.system}.sf-pro-nerd
|
|
inputs.apple-fonts.packages.${pkgs.system}.sf-pro
|
|
inputs.apple-fonts.packages.${pkgs.system}.sf-mono-nerd
|
|
inputs.apple-fonts.packages.${pkgs.system}.sf-mono
|
|
noto-fonts-color-emoji
|
|
noto-fonts
|
|
self.packages.${pkgs.system}.nerd-fonts-sf-mono-ligatures
|
|
];
|
|
}
|