Personal Nix setup

Merge branch 'hyprland-2'

+72 -4
flake.lock
···
"type": "github"
}
},
"android-sdk": {
"inputs": {
"devshell": "devshell",
···
"owner": "kitten",
"ref": "edge",
"repo": "nixos-apple-silicon",
"type": "github"
}
},
···
]
},
"locked": {
-
"lastModified": 1746171682,
-
"narHash": "sha256-EyXUNSa+H+YvGVuQJP1nZskXAowxKYp79RNUsNdQTj4=",
"owner": "nix-community",
"repo": "home-manager",
-
"rev": "50eee705bbdbac942074a8c120e8194185633675",
"type": "github"
},
"original": {
"owner": "nix-community",
-
"ref": "release-24.11",
"repo": "home-manager",
"type": "github"
}
···
"nixos-hardware": "nixos-hardware",
"nixpkgs": "nixpkgs",
"nvim-plugins": "nvim-plugins",
"yeetmouse": "yeetmouse",
"zen-browser": "zen-browser"
}
···
"original": {
"owner": "oxalica",
"repo": "rust-overlay",
"type": "github"
}
},
···
"type": "github"
}
},
+
"ags": {
+
"inputs": {
+
"astal": "astal",
+
"nixpkgs": [
+
"system-shell",
+
"nixpkgs"
+
]
+
},
+
"locked": {
+
"lastModified": 1744557573,
+
"narHash": "sha256-XAyj0iDuI51BytJ1PwN53uLpzTDdznPDQFG4RwihlTQ=",
+
"owner": "aylur",
+
"repo": "ags",
+
"rev": "3ed9737bdbc8fc7a7c7ceef2165c9109f336bff6",
+
"type": "github"
+
},
+
"original": {
+
"owner": "aylur",
+
"repo": "ags",
+
"type": "github"
+
}
+
},
"android-sdk": {
"inputs": {
"devshell": "devshell",
···
"owner": "kitten",
"ref": "edge",
"repo": "nixos-apple-silicon",
+
"type": "github"
+
}
+
},
+
"astal": {
+
"inputs": {
+
"nixpkgs": [
+
"system-shell",
+
"ags",
+
"nixpkgs"
+
]
+
},
+
"locked": {
+
"lastModified": 1742571008,
+
"narHash": "sha256-5WgfJAeBpxiKbTR/gJvxrGYfqQRge5aUDcGKmU1YZ1Q=",
+
"owner": "aylur",
+
"repo": "astal",
+
"rev": "dc0e5d37abe9424c53dcbd2506a4886ffee6296e",
+
"type": "github"
+
},
+
"original": {
+
"owner": "aylur",
+
"repo": "astal",
"type": "github"
}
},
···
]
},
"locked": {
+
"lastModified": 1746798521,
+
"narHash": "sha256-axfz/jBEH9XHpS7YSumstV7b2PrPf7L8bhWUtLBv3nA=",
"owner": "nix-community",
"repo": "home-manager",
+
"rev": "e95a7c5b6fa93304cd2fd78cf676c4f6d23c422c",
"type": "github"
},
"original": {
"owner": "nix-community",
"repo": "home-manager",
"type": "github"
}
···
"nixos-hardware": "nixos-hardware",
"nixpkgs": "nixpkgs",
"nvim-plugins": "nvim-plugins",
+
"system-shell": "system-shell",
"yeetmouse": "yeetmouse",
"zen-browser": "zen-browser"
}
···
"original": {
"owner": "oxalica",
"repo": "rust-overlay",
+
"type": "github"
+
}
+
},
+
"system-shell": {
+
"inputs": {
+
"ags": "ags",
+
"flake-utils": [
+
"flake-utils"
+
],
+
"nixpkgs": [
+
"nixpkgs"
+
]
+
},
+
"locked": {
+
"lastModified": 1746645757,
+
"narHash": "sha256-pE1jnED69CQIcrZQCByRVkvEwxqpefp4nYg/X/k9fqI=",
+
"owner": "kitten",
+
"repo": "system-shell",
+
"rev": "e98ac6578739ab28a04d6800a1f0195d7263f467",
+
"type": "github"
+
},
+
"original": {
+
"owner": "kitten",
+
"repo": "system-shell",
"type": "github"
}
},
+11 -2
flake.nix
···
flake-utils.url = "github:numtide/flake-utils";
home-manager = {
-
url = "github:nix-community/home-manager/release-24.11";
inputs.nixpkgs.follows = "nixpkgs";
};
···
language-servers = {
url = "github:kitten/language-servers.nix";
inputs = {
nixpkgs.follows = "nixpkgs";
flake-utils.follows = "flake-utils";
···
inputs.nvim-plugins.overlays.default
inputs.android-sdk.overlays.default
inputs.language-servers.overlays.default
(self: super: {
zen-browser = inputs.zen-browser.packages.${self.system}.beta;
-
})
];
in {
darwinConfigurations."sprite" = mkSystem {
···
flake-utils.url = "github:numtide/flake-utils";
home-manager = {
+
url = "github:nix-community/home-manager";
inputs.nixpkgs.follows = "nixpkgs";
};
···
language-servers = {
url = "github:kitten/language-servers.nix";
+
inputs = {
+
nixpkgs.follows = "nixpkgs";
+
flake-utils.follows = "flake-utils";
+
};
+
};
+
+
system-shell = {
+
url = "github:kitten/system-shell";
inputs = {
nixpkgs.follows = "nixpkgs";
flake-utils.follows = "flake-utils";
···
inputs.nvim-plugins.overlays.default
inputs.android-sdk.overlays.default
inputs.language-servers.overlays.default
+
inputs.system-shell.overlays.default
(self: super: {
zen-browser = inputs.zen-browser.packages.${self.system}.beta;
+
} // (import ./lib/pkgs self))
];
in {
darwinConfigurations."sprite" = mkSystem {
+2 -1
home/apps/ghostty.nix
···
window-theme = ghostty
window-colorspace = display-p3
window-save-state = always
-
window-decoration = client
window-inherit-working-directory = true
unfocused-split-opacity = 0.9
freetype-load-flags = no-monochrome
···
macos-titlebar-style = tabs
adw-toolbar-style = flat
shell-integration-features = no-cursor,sudo,title
shell-integration = zsh
···
window-theme = ghostty
window-colorspace = display-p3
window-save-state = always
+
window-decoration = server
window-inherit-working-directory = true
unfocused-split-opacity = 0.9
freetype-load-flags = no-monochrome
···
macos-titlebar-style = tabs
adw-toolbar-style = flat
+
gtk-titlebar = false
shell-integration-features = no-cursor,sudo,title
shell-integration = zsh
+1 -1
home/base/shell.nix
···
src = pkgs.pure-prompt;
}
];
-
initExtra = /*sh*/''
setopt NO_NOMATCH
stty -ixon -ixoff
'';
···
src = pkgs.pure-prompt;
}
];
+
initContent = /*sh*/''
setopt NO_NOMATCH
stty -ixon -ixoff
'';
+2
home/default.nix
···
imports = [
./base
./development
./apps
];
}
···
imports = [
./base
./development
+
./desktop
./apps
+
./fonts
];
}
+17
home/desktop/default.nix
···
···
+
{ lib, ... }:
+
+
with lib; {
+
options.modules.desktop = {
+
enable = mkOption {
+
default = false;
+
example = true;
+
description = "Whether to enable Deskop options.";
+
type = types.bool;
+
};
+
};
+
+
imports = [
+
./hyprland.nix
+
./theme.nix
+
];
+
}
+343
home/desktop/hyprland.nix
···
···
+
{ lib, config, pkgs, ... }:
+
+
with lib;
+
let
+
cfg = config.modules.desktop;
+
+
system-shell = "${getExe pkgs.system-shell}";
+
wpctl = "${pkgs.wireplumber}/bin/wpctl";
+
brightnessctl = "${pkgs.brightnessctl}/bin/brightnessctl";
+
+
hyprshot = getExe (pkgs.hyprshot.overrideAttrs (oldAttrs: {
+
postInstall = (oldAttrs.postInstall or "") + ''
+
wrapProgram $out/bin/hyprshot \
+
--set HYPRSHOT_DIR "${config.xdg.userDirs.pictures}/Screenshots"
+
'';
+
}));
+
in {
+
options.modules.desktop.hyprland = {
+
enable = mkOption {
+
default = cfg.enable;
+
example = true;
+
description = "Whether to enable Hyprland configuration.";
+
type = types.bool;
+
};
+
+
monitor = mkOption {
+
description = "Monitor configuration";
+
default = [ ];
+
type = lib.types.listOf lib.types.str;
+
};
+
};
+
+
config = mkIf cfg.hyprland.enable {
+
wayland.windowManager.hyprland = {
+
enable = true;
+
+
package = null;
+
portalPackage = null;
+
systemd.enable = false;
+
xwayland.enable = false;
+
plugins = with pkgs.hyprlandPlugins; [ hyprspace ];
+
+
settings = {
+
general = {
+
gaps_out = 9;
+
gaps_in = 4;
+
allow_tearing = true;
+
resize_on_border = true;
+
hover_icon_on_border = false;
+
no_border_on_floating = true;
+
extend_border_grab_area = 10;
+
border_size = 1;
+
"col.active_border" = "0xB35A5A5A";
+
"col.inactive_border" = "0x8C3A3A3A";
+
};
+
+
decoration = {
+
rounding = 9;
+
dim_inactive = true;
+
dim_strength = 0.12;
+
+
blur = {
+
enabled = true;
+
size = 6;
+
passes = 4;
+
contrast = 0.74;
+
brightness = 0.45;
+
vibrancy = 0.15;
+
vibrancy_darkness = 0.1;
+
ignore_opacity = false;
+
popups_ignorealpha = 0.1;
+
input_methods_ignorealpha = 0.1;
+
noise = 0.012;
+
};
+
+
shadow = {
+
color = "0x81000000";
+
range = 40;
+
render_power = 2;
+
offset = "5, 5";
+
};
+
};
+
+
input = {
+
kb_model = "apple";
+
kb_layout = "gb";
+
kb_variant = "mac";
+
kb_options = "ctrl:nocaps,lv3:ralt_switch";
+
sensitivity = -0.5;
+
touchpad = {
+
clickfinger_behavior = true;
+
tap-to-click = false;
+
tap-and-drag = false;
+
scroll_factor = 0.18;
+
};
+
};
+
+
gestures = {
+
workspace_swipe = true;
+
workspace_swipe_invert = false;
+
workspace_swipe_cancel_ratio = 0.2;
+
workspace_swipe_distance = 560;
+
};
+
+
misc = {
+
middle_click_paste = false;
+
focus_on_activate = true;
+
};
+
+
debug.error_position = 1;
+
binds.movefocus_cycles_fullscreen = true;
+
+
plugin.overview = {
+
autoDrag = true;
+
hideOverlayLayers = false;
+
exitOnSwitch = true;
+
reverseSwipe = true;
+
dragAlpha = 0.85;
+
workspaceMargin = 16;
+
panelHeight = 150;
+
reservedArea = 38;
+
};
+
+
monitor = cfg.hyprland.monitor ++ [
+
", preferred, auto, 1"
+
];
+
+
bindm = [
+
"SUPER, mouse:272, movewindow"
+
"SUPERSHIFT, mouse:272, resizewindow"
+
];
+
+
bindel = [
+
", XF86AudioRaiseVolume, exec, ${wpctl} set-volume -l 1.0 @DEFAULT_AUDIO_SINK@ 3%+"
+
", XF86AudioLowerVolume, exec, ${wpctl} set-volume -l 1.0 @DEFAULT_AUDIO_SINK@ 3%-"
+
", XF86MonBrightnessDown, exec, ${brightnessctl} set 10%-"
+
", XF86MonBrightnessUp, exec, ${brightnessctl} set +10%"
+
];
+
+
bindl = [
+
", XF86AudioMute, exec, ${wpctl} set-mute @DEFAULT_AUDIO_SINK@ toggle"
+
", XF86AudioMicMute, exec, ${wpctl} set-mute @DEFAULT_AUDIO_SOURCE@ toggle"
+
", XF86AudioPlay, exec, ${system-shell} play_pause"
+
", XF86AudioPause, exec, ${system-shell} play_pause"
+
", XF86AudioNext, exec, ${system-shell} play_next"
+
", XF86AudioPrev, exec, ${system-shell} play_previous"
+
];
+
+
bindp = [
+
"SUPER, W, killactive"
+
"SUPER, O, overview:toggle, all"
+
+
"SUPER, left, movefocus, l"
+
"SUPER, down, movefocus, d"
+
"SUPER, up, movefocus, u"
+
"SUPER, right, movefocus, r"
+
+
"SUPER, H, movefocus, l"
+
"SUPER, J, movefocus, d"
+
"SUPER, K, movefocus, u"
+
"SUPER, L, movefocus, r"
+
+
"SUPER_CONTROL, H, workspace, e-1"
+
"SUPER_CONTROL, J, focusmonitor, +1"
+
"SUPER_CONTROL, K, focusmonitor, -1"
+
"SUPER_CONTROL, L, workspace, e+1"
+
];
+
+
bind = [
+
"SUPER, SUPER_L, exec, ${system-shell} launcher"
+
+
"SUPER, T, exec, uwsm-app ghostty"
+
"SUPER, B, exec, uwsm-app zen-beta"
+
+
"SUPER_SHIFT, F, fullscreen, 1"
+
+
"SUPER_SHIFT, left, movewindow, l"
+
"SUPER_SHIFT, down, movewindow, d"
+
"SUPER_SHIFT, up, movewindow, u"
+
"SUPER_SHIFT, right, movewindow, r"
+
+
"SUPER_SHIFT, H, movewindow, l"
+
"SUPER_SHIFT, J, movewindow, d"
+
"SUPER_SHIFT, K, movewindow, u"
+
"SUPER_SHIFT, L, movewindow, r"
+
+
"SUPER, 1, workspace, 1"
+
"SUPER, 2, workspace, 2"
+
"SUPER, 3, workspace, 3"
+
"SUPER, 4, workspace, 4"
+
"SUPER, 5, workspace, 5"
+
"SUPER, 6, workspace, 6"
+
"SUPER, 7, workspace, 7"
+
"SUPER, 8, workspace, 8"
+
"SUPER, 9, workspace, 9"
+
"SUPER, 0, workspace, 10"
+
+
"SUPER_CONTROL_SHIFT, H, movetoworkspace, e-1"
+
"SUPER_CONTROL_SHIFT, J, moveworkspacetomonitor, +1"
+
"SUPER_CONTROL_SHIFT, K, moveworkspacetomonitor, -1"
+
"SUPER_CONTROL_SHIFT, L, movetoworkspace, e+1"
+
+
"SUPER_CONTROL, 1, movetoworkspace, 1"
+
"SUPER_CONTROL, 2, movetoworkspace, 2"
+
"SUPER_CONTROL, 3, movetoworkspace, 3"
+
"SUPER_CONTROL, 4, movetoworkspace, 4"
+
"SUPER_CONTROL, 5, movetoworkspace, 5"
+
"SUPER_CONTROL, 6, movetoworkspace, 6"
+
"SUPER_CONTROL, 7, movetoworkspace, 7"
+
"SUPER_CONTROL, 8, movetoworkspace, 8"
+
"SUPER_CONTROL, 9, movetoworkspace, 9"
+
"SUPER_CONTROL, 0, movetoworkspace, 10"
+
+
"SUPER_SHIFT, 2, exec, ${hyprshot} -z -m window -m active"
+
"SUPER_SHIFT, 3, exec, ${hyprshot} -z -m output -m active"
+
"SUPER_SHIFT, 4, exec, ${hyprshot} -z -m region"
+
", Print, exec, ${hyprshot} -z -m window -m active"
+
"SUPER, Print, exec, ${hyprshot} -z -m output -m active"
+
"SUPER_SHIFT, Print, exec, ${hyprshot} -z -m region"
+
];
+
+
windowrule = [
+
"suppressevent maximize, class:.*"
+
"nofocus,class:^$,title:^$,xwayland:1,floating:1,fullscreen:0,pinned:0"
+
+
"renderunfocused,fullscreenstate:2"
+
"immediate,fullscreenstate:2"
+
"forcergbx,fullscreenstate:2"
+
+
"float, class:zen-beta,initialTitle:^(Picture-in-Picture)$"
+
"pin, class:zen-beta,initialTitle:^(Picture-in-Picture)$"
+
"idleinhibit fullscreen,class:zen-beta"
+
+
"float,title:^(Open)$"
+
"float,title:^(Choose Files)$"
+
"float,title:^(Save As)$"
+
"float,title:^(Confirm to replace files)$"
+
"float,title:^(File Operation Progress)$"
+
];
+
+
layerrule = [
+
"blur, system-shell"
+
"ignorezero, system-shell"
+
"xray, system-shell"
+
"animation slide, system-shell"
+
];
+
};
+
};
+
+
services = {
+
hyprpolkitagent.enable = true;
+
hypridle = {
+
enable = true;
+
package = null;
+
settings = {
+
general = {
+
lock_cmd = "pidof hyprlock || hyprlock";
+
before_sleep_cmd = "loginctl lock-session";
+
after_sleep_cmd = "hyprctl dispatch dpms on";
+
};
+
listener = [
+
{
+
timeout = 300;
+
on-timeout = "loginctl lock-session";
+
}
+
{
+
timeout = 330;
+
on-timeout = "hyprctl dispatch dpms off";
+
on-resume = "hyprctl dispatch dpms on";
+
}
+
{
+
timeout = 600;
+
on-timeout = "systemctl suspend";
+
}
+
];
+
};
+
};
+
};
+
+
programs.hyprlock = {
+
enable = true;
+
package = null;
+
settings = {
+
general = {
+
disable_loading_bar = true;
+
grace = 10;
+
hide_cursor = true;
+
no_fade_in = false;
+
};
+
background = [
+
{
+
path = "";
+
blur_passes = 3;
+
blur_size = 8;
+
}
+
];
+
input-field = [
+
{
+
size = "200, 50";
+
position = "0, -80";
+
dots_center = true;
+
fade_on_empty = false;
+
font_color = "rgb(202, 211, 245)";
+
inner_color = "rgb(91, 96, 120)";
+
outer_color = "rgb(24, 25, 38)";
+
outline_thickness = 5;
+
shadow_passes = 2;
+
}
+
];
+
};
+
};
+
+
systemd.user.services.system-shell-notifd = {
+
Install.WantedBy = [ "system-shell.service" ];
+
Service = {
+
ExecStart = "${pkgs.astal.notifd}/bin/astal-notifd -d";
+
Restart = "on-failure";
+
RestartSec = 5;
+
};
+
Unit = {
+
After = [ "graphical-session.target" ];
+
PartOf = [ "graphical-session.target" ];
+
};
+
};
+
+
systemd.user.services.system-shell = {
+
Install.WantedBy = [ "graphical-session.target" ];
+
Service = {
+
ExecStart = "${system-shell}";
+
Restart = "on-failure";
+
RestartSec = 5;
+
Environment = [ "GSK_RENDERER=ngl" ];
+
};
+
Unit = {
+
After = [
+
"graphical-session.target"
+
];
+
ConditionEnvironment = "WAYLAND_DISPLAY";
+
PartOf = [ "graphical-session.target" ];
+
};
+
};
+
};
+
}
+119
home/desktop/theme.nix
···
···
+
{ lib, config, pkgs, ... }:
+
+
with lib;
+
let
+
cfg = config.modules.desktop;
+
+
cursorTheme = {
+
name = "macOS";
+
package = pkgs.apple-cursor;
+
};
+
+
iconTheme = {
+
name = "WhiteSur";
+
package = pkgs.whitesur-icon-theme.override {
+
boldPanelIcons = true;
+
alternativeIcons = true;
+
};
+
};
+
+
gtkTheme = {
+
name = "WhiteSur-Dark-solid";
+
package = pkgs.whitesur-gtk-theme;
+
};
+
+
kvantumTheme = rec {
+
name = "WhiteSur-opaqueDark";
+
package = pkgs.stdenv.mkDerivation {
+
pname = "whitesur-kde";
+
version = pkgs.whitesur-kde.version;
+
src = pkgs.whitesur-kde.src;
+
installPhase = /*sh*/''
+
mkdir -p "$out/share/Kvantum/${name}"
+
cp -R Kvantum/**/* "$out/share/Kvantum/${name}"
+
'';
+
};
+
};
+
in {
+
options.modules.desktop.theme = {
+
enable = mkOption {
+
default = cfg.enable;
+
example = true;
+
description = "Whether to enable theming configuration.";
+
type = types.bool;
+
};
+
};
+
+
config = mkIf cfg.theme.enable {
+
home.pointerCursor = {
+
inherit (cursorTheme) package name;
+
gtk.enable = true;
+
hyprcursor.enable = true;
+
x11.enable = true;
+
size = 28;
+
};
+
+
home.packages = with pkgs; [
+
catppuccin-kvantum
+
libsForQt5.qtstyleplugin-kvantum
+
libsForQt5.qt5ct
+
];
+
+
qt = {
+
enable = true;
+
platformTheme.name = "gtk";
+
style.name = "kvantum";
+
};
+
+
xdg.configFile = {
+
"Kvantum/${kvantumTheme.name}".source = "${kvantumTheme.package}/share/Kvantum/${kvantumTheme.name}";
+
"Kvantum/kvantum.kvconfig".text = ''
+
[General]
+
theme=${kvantumTheme.name}
+
'';
+
"qt5ct/qt5ct.conf".text = ''
+
[Appearance]
+
icon_theme=${iconTheme.name}
+
'';
+
"qt6ct/qt6ct.conf".text = ''
+
[Appearance]
+
icon_theme=${iconTheme.name}
+
'';
+
};
+
+
gtk = {
+
enable = true;
+
inherit iconTheme;
+
theme = gtkTheme;
+
font = {
+
name = "SF Pro Display";
+
package = pkgs.sf-pro;
+
size = 11;
+
};
+
gtk2.configLocation = "${config.xdg.configHome}/gtk-2.0/gtkrc";
+
gtk3.extraConfig.gtk-application-prefer-dark-theme = 1;
+
gtk4.extraConfig.gtk-application-prefer-dark-theme = 1;
+
};
+
+
dconf = {
+
enable = true;
+
settings = {
+
"org/gnome/desktop/interface" = {
+
color-scheme = "prefer-dark";
+
gtk-theme = gtkTheme.name;
+
icon-theme = iconTheme.name;
+
};
+
};
+
};
+
+
fonts.fontconfig = {
+
enable = true;
+
defaultFonts = {
+
serif = [ "Noto Serif" "Noto Color Emoji" ];
+
sansSerif = [ "Inter" "Noto Color Emoji" ];
+
monospace = [ "Dank Mono" "Roboto Mono" "Noto Color Emoji" ];
+
emoji = [ "Noto Color Emoji" ];
+
};
+
};
+
};
+
}
+5 -1
lib/pkgs/default.nix
···
-
pkgs: { }
···
+
pkgs: {
+
sf-pro = import ./sf-pro.nix pkgs;
+
sf-mono = import ./sf-mono.nix pkgs;
+
new-york = import ./new-york.nix pkgs;
+
}
+24
lib/pkgs/new-york.nix
···
···
+
{
+
stdenv,
+
lib,
+
fetchFromGitHub,
+
unzip,
+
...
+
}: stdenv.mkDerivation rec {
+
pname = "New-York";
+
version = "0";
+
+
src = fetchFromGitHub {
+
owner = "yell0wsuit";
+
repo = "New-York-fonts";
+
rev = "master";
+
sha256 = "sha256-0uuzr64KxDEMtkLizvGeHTXDBAMLe4j5iXGaJPfDdmg=";
+
};
+
+
nativeBuildInputs = [unzip];
+
+
installPhase = ''
+
mkdir -p $out/share/fonts/opentype
+
cp *.otf $out/share/fonts/opentype/
+
'';
+
}
+24
lib/pkgs/sf-mono.nix
···
···
+
{
+
stdenv,
+
lib,
+
fetchFromGitHub,
+
unzip,
+
...
+
}: stdenv.mkDerivation rec {
+
pname = "SF-Mono";
+
version = "0";
+
+
src = fetchFromGitHub {
+
owner = "supercomputra";
+
repo = "SF-Mono-Font";
+
rev = "master";
+
sha256 = "sha256-3wG3M4Qep7MYjktzX9u8d0iDWa17FSXYnObSoTG2I/o=";
+
};
+
+
nativeBuildInputs = [unzip];
+
+
installPhase = ''
+
mkdir -p $out/share/fonts/opentype
+
cp *.otf $out/share/fonts/opentype/
+
'';
+
}
+26
lib/pkgs/sf-pro.nix
···
···
+
{
+
stdenv,
+
lib,
+
fetchFromGitHub,
+
unzip,
+
...
+
}: stdenv.mkDerivation rec {
+
pname = "SF-Pro";
+
version = "0";
+
+
src = fetchFromGitHub {
+
owner = "sahibjotsaggu";
+
repo = "San-Francisco-Pro-Fonts";
+
rev = "master";
+
sha256 = "sha256-mAXExj8n8gFHq19HfGy4UOJYKVGPYgarGd/04kUIqX4=";
+
};
+
+
nativeBuildInputs = [unzip];
+
+
installPhase = ''
+
mkdir -p $out/share/fonts/opentype
+
mkdir -p $out/share/fonts/truetype
+
cp *.otf $out/share/fonts/opentype
+
cp *.ttf $out/share/fonts/truetype
+
'';
+
}
-1
machines/fanta/configuration.nix
···
imports = [ ];
modules = {
-
fonts.enable = true;
nvim.enable = true;
};
···
imports = [ ];
modules = {
nvim.enable = true;
};
-1
machines/pepper/configuration.nix
···
modules = {
desktop.enable = true;
-
fonts.enable = true;
server = {
enable = true;
sshd.enable = true;
···
modules = {
desktop.enable = true;
server = {
enable = true;
sshd.enable = true;
+7 -1
machines/pepper/home.nix
···
{
modules = {
development.enable = false;
apps = {
enable = true;
discord.enable = true;
-
minecraft.enable = true;
ghostty.enable = true;
zen-browser.enable = true;
};
···
{
modules = {
+
desktop = {
+
enable = true;
+
hyprland.monitor = [
+
"desc:Samsung Electric Company Odyssey G60SD HNAX300205, 2560x1440@360, 0x0, 1, vrr, 1"
+
"desc:LG Electronics 27GL850 005NTPC4Q200, preferred, auto, 1, transform, 1, vrr, 1"
+
];
+
};
development.enable = false;
apps = {
enable = true;
discord.enable = true;
ghostty.enable = true;
zen-browser.enable = true;
};
+1 -2
machines/sodacream/configuration.nix
···
rawaccel.enable = false;
affinity.performanceCores = [ 4 5 6 7 ];
};
-
fonts.enable = true;
server = {
enable = true;
tailscale.enable = true;
-
sshd.enable = false;
podman.enable = true;
};
};
···
rawaccel.enable = false;
affinity.performanceCores = [ 4 5 6 7 ];
};
server = {
enable = true;
tailscale.enable = true;
+
sshd.enable = true;
podman.enable = true;
};
};
+4
machines/sodacream/home.nix
···
{ ... }: {
modules = {
development = {
enable = true;
js.enable = true;
···
{ ... }: {
modules = {
+
desktop = {
+
enable = true;
+
hyprland.monitor = [ "eDP-1, preferred, 0x0, 1.6" ];
+
};
development = {
enable = true;
js.enable = true;
-1
machines/sprite/configuration.nix
···
imports = [ ];
modules = {
-
fonts.enable = true;
nvim.enable = true;
};
···
imports = [ ];
modules = {
nvim.enable = true;
};
+5
modules/apps/games.nix
···
gamemode.enable = true;
gamescope = {
enable = true;
env = {
PROTON_ENABLE_AMD_AGS = "1";
ENABLE_HDR_WSI = "1";
···
gamemode.enable = true;
gamescope = {
enable = true;
+
package = pkgs.gamescope.overrideAttrs (old: {
+
enableWsi = true;
+
enableExecutable = true;
+
NIX_CFLAGS_COMPILE = [ "-fno-fast-math" "-fno-omit-frame-pointer" ];
+
});
env = {
PROTON_ENABLE_AMD_AGS = "1";
ENABLE_HDR_WSI = "1";
-1
modules/default.nix
···
./base
./apps
./desktop
-
./fonts
./nvim
./router
./server
···
./base
./apps
./desktop
./nvim
./router
./server
+10 -6
modules/desktop/fonts.nix
···
};
config = mkIf cfg.fonts.enable {
-
fonts = {
-
fontDir.enable = true;
packages = with pkgs; [
noto-fonts
noto-fonts-cjk-sans
noto-fonts-emoji
-
roboto-mono
inter
];
fontconfig.defaultFonts = {
-
serif = [ "Noto Serif" "Noto Color Emoji" ];
-
sansSerif = [ "Inter" "Noto Color Emoji" ];
-
monospace = [ "Dank Mono" "Roboto Mono" "Noto Color Emoji" ];
emoji = [ "Noto Color Emoji" ];
};
};
···
};
config = mkIf cfg.fonts.enable {
fonts = {
+
fontDir = {
+
enable = true;
+
decompressFonts = true;
+
};
packages = with pkgs; [
+
sf-pro
+
sf-mono
+
new-york
noto-fonts
noto-fonts-cjk-sans
noto-fonts-emoji
inter
];
fontconfig.defaultFonts = {
+
serif = [ "New York" "Noto Serif" "Noto Color Emoji" ];
+
sansSerif = [ "SF Pro Display" "Inter" "Noto Color Emoji" ];
+
monospace = [ "Dank Mono" "SF Mono" "Noto Color Emoji" ];
emoji = [ "Noto Color Emoji" ];
};
};
+31 -31
modules/desktop/session.nix
···
-
{ lib, config, pkgs, ... }:
with lib;
let
···
};
config = mkIf cfg.session.enable {
boot = {
plymouth.enable = true;
initrd.verbose = mkDefault false;
consoleLogLevel = 0;
-
kernelParams = [ "console=tty1" "vt.global_cursor_default=0" ];
};
services = {
-
desktopManager.plasma6.enable = true;
-
displayManager = {
-
defaultSession = "plasma";
-
sddm = {
-
enable = true;
-
enableHidpi = true;
-
wayland.enable = true;
-
};
};
};
-
environment = {
-
systemPackages = with pkgs.kdePackages; [
-
sddm-kcm
-
qtmultimedia
-
pkgs.apple-cursor
-
];
-
plasma6 = {
-
excludePackages = with pkgs.kdePackages; [
-
discover
-
ffmpegthumbs
-
plasma-browser-integration
-
kate
-
konsole
-
krdp
-
elisa
-
gwenview
-
oxygen
-
oxygen-sounds
-
khelpcenter
-
];
};
};
security = {
polkit.enable = true;
};
xdg.portal = {
enable = true;
xdgOpenUsePortal = true;
extraPortals = with pkgs; [
-
kdePackages.xdg-desktop-portal-kde
xdg-desktop-portal-gtk
];
};
···
+
{ lib, config, pkgs, user, ... }:
with lib;
let
···
};
config = mkIf cfg.session.enable {
+
users.users."${user}".extraGroups = [ "video" ];
+
boot = {
plymouth.enable = true;
initrd.verbose = mkDefault false;
consoleLogLevel = 0;
+
};
+
+
environment.sessionVariables = {
+
GSK_RENDERER = mkDefault "ngl";
+
QT_QPA_PLATFORM = mkDefault "wayland;xcb";
+
GDK_BACKEND = mkDefault "wayland,x11,*";
+
SDL_VIDEODRIVER = mkDefault "wayland,x11";
+
NIXOS_OZONE_WL = mkDefault "1";
};
services = {
+
greetd = {
+
enable = true;
+
settings.terminal.vt = 1;
+
};
+
hypridle.enable = true;
+
upower.enable = true;
+
gvfs.enable = true;
+
logind = {
+
powerKey = "suspend";
+
powerKeyLongPress = "poweroff";
+
lidSwitch = "suspend";
};
};
+
programs = {
+
regreet.enable = true;
+
hyprlock.enable = true;
+
hyprland = {
+
enable = true;
+
withUWSM = true;
+
xwayland.enable = true;
};
};
security = {
polkit.enable = true;
+
pam.services.hyprlock = {};
};
xdg.portal = {
enable = true;
xdgOpenUsePortal = true;
extraPortals = with pkgs; [
+
xdg-desktop-portal-hyprland
xdg-desktop-portal-gtk
];
};
+4 -3
modules/fonts/default.nix home/fonts/default.nix
···
with lib;
let
cfg = config.modules.fonts;
-
fontsPath = if helpers.isDarwin then "/Library/Fonts" else "/usr/share/fonts/nonfree";
in {
options.modules.fonts = {
enable = mkOption {
-
default = false;
-
example = true;
description = "Whether to enable fonts options.";
type = types.bool;
};
};
config = mkIf cfg.enable {
age.secrets."DankMono-Regular.otf" = {
symlink = false;
file = ./encrypt/DankMono-Regular.otf.age;
···
with lib;
let
cfg = config.modules.fonts;
+
fontsPath = if helpers.isDarwin then "Library/Fonts" else "${config.xdg.dataHome}/fonts";
in {
options.modules.fonts = {
enable = mkOption {
+
default = true;
description = "Whether to enable fonts options.";
type = types.bool;
};
};
config = mkIf cfg.enable {
+
fonts.fontconfig.enable = true;
+
age.secrets."DankMono-Regular.otf" = {
symlink = false;
file = ./encrypt/DankMono-Regular.otf.age;
modules/fonts/encrypt/DankMono-Bold.otf.age home/fonts/encrypt/DankMono-Bold.otf.age
modules/fonts/encrypt/DankMono-Italic.otf.age home/fonts/encrypt/DankMono-Italic.otf.age
modules/fonts/encrypt/DankMono-Regular.otf.age home/fonts/encrypt/DankMono-Regular.otf.age
modules/fonts/encrypt/codicon.otf.age home/fonts/encrypt/codicon.otf.age
modules/fonts/encrypt/faicon.ttf.age home/fonts/encrypt/faicon.ttf.age
+6 -6
secrets.nix
···
{
"./modules/base/encrypt/nix-access-tokens.conf.age".publicKeys = keys;
-
"./modules/fonts/encrypt/DankMono-Regular.otf.age".publicKeys = keys;
-
"./modules/fonts/encrypt/DankMono-Bold.otf.age".publicKeys = keys;
-
"./modules/fonts/encrypt/DankMono-Italic.otf.age".publicKeys = keys;
-
"./modules/fonts/encrypt/codicon.otf.age".publicKeys = keys;
-
"./modules/fonts/encrypt/faicon.ttf.age".publicKeys = keys;
-
"./modules/server/encrypt/tailscale.age".publicKeys = keys;
"./modules/server/encrypt/rclone.conf.age".publicKeys = keys;
"./home/base/encrypt/pubring.kbx.age".publicKeys = keys;
"./home/base/encrypt/75EF1DBB30A59CFB56BCE06A88CCF363DA63B1A7.key.age".publicKeys = keys;
···
{
"./modules/base/encrypt/nix-access-tokens.conf.age".publicKeys = keys;
"./modules/server/encrypt/tailscale.age".publicKeys = keys;
"./modules/server/encrypt/rclone.conf.age".publicKeys = keys;
+
+
"./home/fonts/encrypt/DankMono-Regular.otf.age".publicKeys = keys;
+
"./home/fonts/encrypt/DankMono-Bold.otf.age".publicKeys = keys;
+
"./home/fonts/encrypt/DankMono-Italic.otf.age".publicKeys = keys;
+
"./home/fonts/encrypt/codicon.otf.age".publicKeys = keys;
+
"./home/fonts/encrypt/faicon.ttf.age".publicKeys = keys;
"./home/base/encrypt/pubring.kbx.age".publicKeys = keys;
"./home/base/encrypt/75EF1DBB30A59CFB56BCE06A88CCF363DA63B1A7.key.age".publicKeys = keys;