diff --git a/flake.lock b/flake.lock index 14542cd..d655e23 100644 --- a/flake.lock +++ b/flake.lock @@ -1,5 +1,71 @@ { "nodes": { + "base16": { + "inputs": { + "fromYaml": "fromYaml" + }, + "locked": { + "lastModified": 1708890466, + "narHash": "sha256-LlrC09LoPi8OPYOGPXegD72v+//VapgAqhbOFS3i8sc=", + "owner": "SenchoPens", + "repo": "base16.nix", + "rev": "665b3c6748534eb766c777298721cece9453fdae", + "type": "github" + }, + "original": { + "owner": "SenchoPens", + "repo": "base16.nix", + "type": "github" + } + }, + "base16-fish": { + "flake": false, + "locked": { + "lastModified": 1622559957, + "narHash": "sha256-PebymhVYbL8trDVVXxCvZgc0S5VxI7I1Hv4RMSquTpA=", + "owner": "tomyun", + "repo": "base16-fish", + "rev": "2f6dd973a9075dabccd26f1cded09508180bf5fe", + "type": "github" + }, + "original": { + "owner": "tomyun", + "repo": "base16-fish", + "type": "github" + } + }, + "base16-helix": { + "flake": false, + "locked": { + "lastModified": 1725860795, + "narHash": "sha256-Z2o8VBPW3I+KKTSfe25kskz0EUj7MpUh8u355Z1nVsU=", + "owner": "tinted-theming", + "repo": "base16-helix", + "rev": "7f795bf75d38e0eea9fed287264067ca187b88a9", + "type": "github" + }, + "original": { + "owner": "tinted-theming", + "repo": "base16-helix", + "type": "github" + } + }, + "base16-vim": { + "flake": false, + "locked": { + "lastModified": 1716150083, + "narHash": "sha256-ZMhnNmw34ogE5rJZrjRv5MtG3WaqKd60ds2VXvT6hEc=", + "owner": "tinted-theming", + "repo": "base16-vim", + "rev": "6e955d704d046b0dc3e5c2d68a2a6eeffd2b5d3d", + "type": "github" + }, + "original": { + "owner": "tinted-theming", + "repo": "base16-vim", + "type": "github" + } + }, "disko": { "inputs": { "nixpkgs": [ @@ -20,6 +86,76 @@ "type": "github" } }, + "flake-compat": { + "flake": false, + "locked": { + "lastModified": 1673956053, + "narHash": "sha256-4gtG9iQuiKITOjNQQeQIpoIB6b16fm+504Ch3sNKLd8=", + "owner": "edolstra", + "repo": "flake-compat", + "rev": "35bb57c0c8d8b62bbfd284272c928ceb64ddbde9", + "type": "github" + }, + "original": { + "owner": "edolstra", + "repo": "flake-compat", + "type": "github" + } + }, + "flake-utils": { + "inputs": { + "systems": [ + "stylix", + "systems" + ] + }, + "locked": { + "lastModified": 1710146030, + "narHash": "sha256-SZ5L6eA7HJ/nmkzGG7/ISclqe6oZdOZTNoesiInkXPQ=", + "owner": "numtide", + "repo": "flake-utils", + "rev": "b1d9ab70662946ef0850d488da1c9019f3a9752a", + "type": "github" + }, + "original": { + "owner": "numtide", + "repo": "flake-utils", + "type": "github" + } + }, + "fromYaml": { + "flake": false, + "locked": { + "lastModified": 1689549921, + "narHash": "sha256-iX0pk/uB019TdBGlaJEWvBCfydT6sRq+eDcGPifVsCM=", + "owner": "SenchoPens", + "repo": "fromYaml", + "rev": "11fbbbfb32e3289d3c631e0134a23854e7865c84", + "type": "github" + }, + "original": { + "owner": "SenchoPens", + "repo": "fromYaml", + "type": "github" + } + }, + "gnome-shell": { + "flake": false, + "locked": { + "lastModified": 1713702291, + "narHash": "sha256-zYP1ehjtcV8fo+c+JFfkAqktZ384Y+y779fzmR9lQAU=", + "owner": "GNOME", + "repo": "gnome-shell", + "rev": "0d0aadf013f78a7f7f1dc984d0d812971864b934", + "type": "github" + }, + "original": { + "owner": "GNOME", + "ref": "46.1", + "repo": "gnome-shell", + "type": "github" + } + }, "home-manager": { "inputs": { "nixpkgs": [ @@ -40,6 +176,27 @@ "type": "github" } }, + "home-manager_2": { + "inputs": { + "nixpkgs": [ + "stylix", + "nixpkgs" + ] + }, + "locked": { + "lastModified": 1724435763, + "narHash": "sha256-UNky3lJNGQtUEXT2OY8gMxejakSWPTfWKvpFkpFlAfM=", + "owner": "nix-community", + "repo": "home-manager", + "rev": "c2cd2a52e02f1dfa1c88f95abeb89298d46023be", + "type": "github" + }, + "original": { + "owner": "nix-community", + "repo": "home-manager", + "type": "github" + } + }, "impermanence": { "locked": { "lastModified": 1729068498, @@ -131,7 +288,104 @@ "nix-index-database": "nix-index-database", "nixos-hardware": "nixos-hardware", "nixpkgs": "nixpkgs", - "nixpkgs-stable": "nixpkgs-stable" + "nixpkgs-stable": "nixpkgs-stable", + "stylix": "stylix" + } + }, + "stylix": { + "inputs": { + "base16": "base16", + "base16-fish": "base16-fish", + "base16-helix": "base16-helix", + "base16-vim": "base16-vim", + "flake-compat": "flake-compat", + "flake-utils": "flake-utils", + "gnome-shell": "gnome-shell", + "home-manager": "home-manager_2", + "nixpkgs": [ + "nixpkgs" + ], + "systems": "systems", + "tinted-foot": "tinted-foot", + "tinted-kitty": "tinted-kitty", + "tinted-tmux": "tinted-tmux" + }, + "locked": { + "lastModified": 1729963473, + "narHash": "sha256-uGjTjvvlGQfQ0yypVP+at0NizI2nrb6kz4wGAqzRGbY=", + "owner": "danth", + "repo": "stylix", + "rev": "04afcfc0684d9bbb24bb1dc77afda7c1843ec93b", + "type": "github" + }, + "original": { + "owner": "danth", + "repo": "stylix", + "type": "github" + } + }, + "systems": { + "locked": { + "lastModified": 1681028828, + "narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=", + "owner": "nix-systems", + "repo": "default", + "rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e", + "type": "github" + }, + "original": { + "owner": "nix-systems", + "repo": "default", + "type": "github" + } + }, + "tinted-foot": { + "flake": false, + "locked": { + "lastModified": 1696725948, + "narHash": "sha256-65bz2bUL/yzZ1c8/GQASnoiGwaF8DczlxJtzik1c0AU=", + "owner": "tinted-theming", + "repo": "tinted-foot", + "rev": "eedbcfa30de0a4baa03e99f5e3ceb5535c2755ce", + "type": "github" + }, + "original": { + "owner": "tinted-theming", + "repo": "tinted-foot", + "type": "github" + } + }, + "tinted-kitty": { + "flake": false, + "locked": { + "lastModified": 1716423189, + "narHash": "sha256-2xF3sH7UIwegn+2gKzMpFi3pk5DlIlM18+vj17Uf82U=", + "owner": "tinted-theming", + "repo": "tinted-kitty", + "rev": "eb39e141db14baef052893285df9f266df041ff8", + "type": "github" + }, + "original": { + "owner": "tinted-theming", + "repo": "tinted-kitty", + "rev": "eb39e141db14baef052893285df9f266df041ff8", + "type": "github" + } + }, + "tinted-tmux": { + "flake": false, + "locked": { + "lastModified": 1696725902, + "narHash": "sha256-wDPg5elZPcQpu7Df0lI5O8Jv4A3T6jUQIVg63KDU+3Q=", + "owner": "tinted-theming", + "repo": "tinted-tmux", + "rev": "c02050bebb60dbb20cb433cd4d8ce668ecc11ba7", + "type": "github" + }, + "original": { + "owner": "tinted-theming", + "repo": "tinted-tmux", + "type": "github" } } }, diff --git a/flake.nix b/flake.nix index 73663c8..b2605bd 100644 --- a/flake.nix +++ b/flake.nix @@ -12,6 +12,8 @@ nixos-hardware.url = "github:NixOS/nixos-hardware/master"; nix-index-database.url = "github:nix-community/nix-index-database"; nix-index-database.inputs.nixpkgs.follows = "nixpkgs"; + stylix.url = "github:danth/stylix"; + stylix.inputs.nixpkgs.follows = "nixpkgs"; }; outputs = diff --git a/src/home/default.nix b/src/home/default.nix index db464cf..39828a8 100644 --- a/src/home/default.nix +++ b/src/home/default.nix @@ -70,6 +70,7 @@ in { enable = true; download = "${homeDir}/downloads"; + documents = "${homeDir}/documents"; music = "${homeDir}/music"; pictures = "${homeDir}/pictures"; videos = "${homeDir}/videos"; diff --git a/src/home/gui/default.nix b/src/home/gui/default.nix index cf99da0..15ae392 100644 --- a/src/home/gui/default.nix +++ b/src/home/gui/default.nix @@ -3,13 +3,16 @@ { imports = [ ./1password.nix + ./discord.nix ./firefox.nix ./keyd.nix + ./kitty.nix ./gnome.nix ./slack.nix ./skype.nix ./spotify.nix ./vscode.nix + ./wezterm.nix ./xdg-portal.nix ./zathura.nix ./zoom.nix @@ -18,10 +21,10 @@ config = { gtk = { enable = true; - theme = { - name = "Adwaita-dark"; - package = pkgs.gnome-themes-extra; - }; + # theme = { + # name = "Adwaita-dark"; + # package = pkgs.gnome-themes-extra; + # }; gtk2 = { configLocation = "${config.home.homeDirectory}/.config/gtkrc-2.0"; }; @@ -29,8 +32,8 @@ qt = { enable = true; - platformTheme.name = "adwaita"; - style.name = "adwaita-dark"; + # platformTheme.name = "adwaita"; + # style.name = "adwaita-dark"; }; }; } diff --git a/src/home/gui/discord.nix b/src/home/gui/discord.nix new file mode 100644 index 0000000..3df5e6c --- /dev/null +++ b/src/home/gui/discord.nix @@ -0,0 +1,13 @@ +{ pkgs, ... }: + +{ + home.packages = with pkgs; [ + discord + ]; + + custom.persist = { + home.directories = [ + ".config/discord" + ]; + }; +} diff --git a/src/home/gui/gnome.nix b/src/home/gui/gnome.nix index 92ec3b5..77a6f20 100644 --- a/src/home/gui/gnome.nix +++ b/src/home/gui/gnome.nix @@ -6,6 +6,8 @@ gnomeExtensions.pop-shell gnomeExtensions.tray-icons-reloaded gnomeExtensions.hibernate-status-button + gnomeExtensions.appindicator + gnomeExtensions.just-perfection ]; dconf.settings = { @@ -13,13 +15,20 @@ disable-user-extensions = false; enabled-extensions = [ "pop-shell@system76.com" - "keyd" + "keyd" + "appindicatorsupport@rgcjonas.gmail.com" + # "just-perfection-desktop@just-perfection" + "trayIconsReloaded@selfmade.pl" + "workspace-indicator@gnome-shell-extensions.gcampax.github.com" ]; favorite-apps = [ "org.gnome.Console.desktop" "firefox.desktop" ]; }; + "org/gnome/desktop/wm/preferences" = { + num-workspaces = 10; + }; "org/gnome/desktop/wm/keybindings" = { minimize = []; lock = []; @@ -27,13 +36,44 @@ switch-to-workspace-right = []; maximize = [ "f" ]; unmaximize = [ "f" ]; - move-to-monitor-up = [ ]; + move-to-monitor-up = []; move-to-monitor-down = []; move-to-monitor-left = []; move-to-monitor-right = []; move-to-workspace-down = []; move-to-workspace-up = []; close = [ "q" "F4" ]; + switch-to-workspace-1 = [ "1" ]; + switch-to-workspace-2 = [ "2" ]; + switch-to-workspace-3 = [ "3" ]; + switch-to-workspace-4 = [ "4" ]; + switch-to-workspace-5 = [ "5" ]; + switch-to-workspace-6 = [ "6" ]; + switch-to-workspace-7 = [ "7" ]; + switch-to-workspace-8 = [ "8" ]; + switch-to-workspace-9 = [ "9" ]; + switch-to-workspace-10 = [ "0" ]; + move-to-workspace-1 = [ "1" ]; + move-to-workspace-2 = [ "2" ]; + move-to-workspace-3 = [ "3" ]; + move-to-workspace-4 = [ "4" ]; + move-to-workspace-5 = [ "5" ]; + move-to-workspace-6 = [ "6" ]; + move-to-workspace-7 = [ "7" ]; + move-to-workspace-8 = [ "8" ]; + move-to-workspace-9 = [ "9" ]; + move-to-workspace-10 = [ "0" ]; + }; + "org/gnome/shell/keybindings" = { + switch-to-application-1 = []; + switch-to-application-2 = []; + switch-to-application-3 = []; + switch-to-application-4 = []; + switch-to-application-5 = []; + switch-to-application-6 = []; + switch-to-application-7 = []; + switch-to-application-8 = []; + switch-to-application-9 = []; }; "org/gnome/settings-daemon/plugins/media-keys" = { video-out = [ ]; @@ -43,8 +83,9 @@ }; "org/gnome/settings-daemon/plugins/media-keys/custom-keybindings/terminal" = { binding = "Return"; - command = "kgx"; - name = "GNOME Console"; + # command = "kgx"; + command = "kitty"; + name = "Open Terminal"; }; "org/gnome/mutter/keybindings" = { toggle-tiled-left = []; @@ -62,6 +103,7 @@ }; "org/gnome/desktop/interface" = { color-scheme = "prefer-dark"; + show-battery-percentage = true; }; }; diff --git a/src/home/gui/kitty.nix b/src/home/gui/kitty.nix new file mode 100644 index 0000000..48119dd --- /dev/null +++ b/src/home/gui/kitty.nix @@ -0,0 +1,19 @@ +{ pkgs, config, ... }: + +{ + programs.kitty = { + enable = true; + shellIntegration = { + enableBashIntegration = config.programs.bash.enable; + enableZshIntegration = config.programs.zsh.enable; + enableFishIntegration = config.programs.fish.enable; + }; + settings = { + hide_window_decorations = "yes"; + }; + }; + stylix.targets.kitty = { + enable = true; + variant256Colors = true; + }; +} diff --git a/src/home/gui/vscode.nix b/src/home/gui/vscode.nix index 8d0846d..9ced0ba 100644 --- a/src/home/gui/vscode.nix +++ b/src/home/gui/vscode.nix @@ -5,6 +5,8 @@ enable = true; }; + stylix.targets.vscode.enable = false; + custom.persist = { home.directories = [ ".config/Code" diff --git a/src/home/gui/wezterm.nix b/src/home/gui/wezterm.nix new file mode 100644 index 0000000..a4958c2 --- /dev/null +++ b/src/home/gui/wezterm.nix @@ -0,0 +1,13 @@ +{ pkgs, ... }: + +{ + programs.wezterm = { + enable = true; + extraConfig = '' + return { + -- enable_wayland = false + } + ''; + }; + stylix.targets.wezterm.enable = true; +} diff --git a/src/home/shell/bash.nix b/src/home/shell/bash.nix index 239a2e3..cfdf7e4 100644 --- a/src/home/shell/bash.nix +++ b/src/home/shell/bash.nix @@ -2,11 +2,11 @@ { programs.bash.enable = true; - programs.bash.profileExtra = lib.mkAfter '' - rm -rf ${config.home.homeDirectory}/.local/share/applications/home-manager - rm -rf ${config.home.homeDirectory}/.icons/nix-icons - ls ${config.home.homeDirectory}/.nix-profile/share/applications/*.desktop > ${config.home.homeDirectory}/.cache/current_desktop_files.txt - ''; + # programs.bash.profileExtra = lib.mkAfter '' + # rm -rf ${config.home.homeDirectory}/.local/share/applications/home-manager + # rm -rf ${config.home.homeDirectory}/.icons/nix-icons + # ls ${config.home.homeDirectory}/.nix-profile/share/applications/*.desktop > ${config.home.homeDirectory}/.cache/current_desktop_files.txt + # ''; custom.persist = { home.files = [ diff --git a/src/home/shell/default.nix b/src/home/shell/default.nix index 62ca16e..95a65a1 100644 --- a/src/home/shell/default.nix +++ b/src/home/shell/default.nix @@ -4,6 +4,7 @@ imports = [ ./bash.nix ./direnv.nix + ./fzf.nix ./ripgrep.nix ./shell.nix ./zoxide.nix diff --git a/src/home/shell/fzf.nix b/src/home/shell/fzf.nix new file mode 100644 index 0000000..da4a144 --- /dev/null +++ b/src/home/shell/fzf.nix @@ -0,0 +1,8 @@ +{ config, ... }: + +{ + programs.fzf = { + enable = true; + enableBashIntegration = config.programs.bash.enable; + }; +} diff --git a/src/home/shell/zoxide.nix b/src/home/shell/zoxide.nix index d2fc086..b025032 100644 --- a/src/home/shell/zoxide.nix +++ b/src/home/shell/zoxide.nix @@ -1,12 +1,14 @@ -_: { +{ config, ... }: + +{ home.shellAliases = { z = "zoxide query -i"; }; programs.zoxide = { enable = true; - enableBashIntegration = true; - enableFishIntegration = true; + enableBashIntegration = config.programs.bash.enable; + enableFishIntegration = config.programs.fish.enable; options = [ "--cmd cd" ]; }; diff --git a/src/hosts/default.nix b/src/hosts/default.nix index a29b111..e30fb01 100644 --- a/src/hosts/default.nix +++ b/src/hosts/default.nix @@ -57,6 +57,7 @@ let ]) inputs.home-manager.nixosModules.home-manager inputs.impermanence.nixosModules.impermanence + inputs.stylix.nixosModules.stylix ]; }; in diff --git a/src/hosts/pickwick/default.nix b/src/hosts/pickwick/default.nix index 7541ba0..8f9a614 100644 --- a/src/hosts/pickwick/default.nix +++ b/src/hosts/pickwick/default.nix @@ -12,9 +12,6 @@ i18n.defaultLocale = "en_US.UTF-8"; services.xserver.enable = true; - - services.xserver.displayManager.gdm.enable = true; - services.xserver.desktopManager.gnome.enable = true; services.xserver.xkb.layout = "us"; security.pam.services.login.fprintAuth = false; @@ -23,57 +20,14 @@ # framework setting services.fwupd.enable = true; hardware.framework.amd-7040.preventWakeOnAC = true; - + services.fprintd.enable = true; services.libinput.enable = true; - users.groups.keyd = {}; - - environment.gnome.excludePackages = with pkgs; [ - baobab - cheese - epiphany - simple-scan - yelp - evince - file-roller - geary - gnome-tour - gnome-initial-setup - gnome-music - gnome-maps - gnome-disk-utility - ]; - programs.dconf.enable = true; - - # environment.persistence."/persist/system" = { - # hideMounts = true; - # directories = [ - # "/var/log" - # "/var/lib/fprint" - # "/var/lib/nixos" - # "/var/lib/bluetooth" - # "/var/lib/systemd/coredump" - # "/etc/NetworkManager/system-connections" - # { directory = "/var/lib/colord"; user = "colord"; group = "colord"; mode = "u=rwx,g=rx,o="; } - # ]; - # files = [ - # "/etc/machine-id" - # ]; - # }; - - programs.fuse.userAllowOther = true; - systemd.services = { - # https://github.com/openzfs/zfs/issues/10891 - systemd-udev-settle.enable = false; - # snapshot dirs sometimes not accessible - # https://github.com/NixOS/nixpkgs/issues/257505#issuecomment-2348313665 - zfs-mount = { - serviceConfig = { - ExecStart = [ "${lib.getExe' pkgs.util-linux "mount"} -t zfs zroot/persist -o remount" ]; - }; - }; + custom.gnome = { + enable = true; + stylix = true; }; system.stateVersion = "24.11"; diff --git a/src/hosts/pickwick/hardware.nix b/src/hosts/pickwick/hardware.nix index f88b6e6..0a3b6fe 100644 --- a/src/hosts/pickwick/hardware.nix +++ b/src/hosts/pickwick/hardware.nix @@ -16,6 +16,7 @@ boot.extraModulePackages = [ ]; boot.kernelParams = [ ]; boot.loader.systemd-boot.enable = true; + boot.loader.systemd-boot.configurationLimit = 10; boot.loader.efi.canTouchEfiVariables = true; networking.useDHCP = lib.mkDefault true; diff --git a/src/nixos/default.nix b/src/nixos/default.nix index 5900ebc..62dfad9 100644 --- a/src/nixos/default.nix +++ b/src/nixos/default.nix @@ -9,9 +9,12 @@ imports = [ ./audio.nix ./1password.nix + ./fonts.nix + ./gnome.nix ./impermanence.nix ./keyd.nix ./nix.nix + ./stylix.nix ./users.nix ./zfs.nix ]; @@ -50,7 +53,7 @@ }; }; - config = { + config = { environment = { systemPackages = with pkgs; [ curl diff --git a/src/nixos/fonts.nix b/src/nixos/fonts.nix new file mode 100644 index 0000000..aad222c --- /dev/null +++ b/src/nixos/fonts.nix @@ -0,0 +1,36 @@ +{ pkgs, lib, config, ... }: + +{ + options.custom = with lib; { + nerdfonts = { + package = mkOption { + type = types.package; + default = pkgs.nerdfonts.override { + fonts = config.custom.nerdfonts.fonts; + }; + }; + fonts = mkOption { + type = types.listOf types.str; + description = "Nerdfonts package"; + default = [ + "FiraCode" + "DroidSansMono" + "SourceCodePro" + "SpaceMono" + "Iosevka" + "IosevkaTerm" + "Inconsolata" + "InconsolataGo" + "UbuntuMono" + ]; + }; + }; + }; + + config = { + fonts.fontDir.enable = true; + fonts.packages = [ + config.custom.nerdfonts.package + ]; + }; +} diff --git a/src/nixos/gnome.nix b/src/nixos/gnome.nix new file mode 100644 index 0000000..13d452d --- /dev/null +++ b/src/nixos/gnome.nix @@ -0,0 +1,34 @@ +{ config, lib, pkgs, ... }: + +{ + options.custom = with lib; { + gnome = { + enable = mkEnableOption "Gnome Desktop"; + stylix = mkEnableOption "Gnome Stylix"; + }; + }; + + config = lib.mkIf config.custom.gnome.enable { + services = { + xserver.enable = true; + xserver.displayManager.gdm.enable = true; + xserver.desktopManager.gnome.enable = true; + }; + environment.gnome.excludePackages = with pkgs; [ + baobab + cheese + epiphany + simple-scan + yelp + evince + geary + gnome-tour + gnome-initial-setup + gnome-music + gnome-maps + gnome-disk-utility + ]; + stylix.targets.gnome.enable = config.custom.gnome.stylix; + hm.stylix.targets.gnome.enable = config.custom.gnome.stylix; + }; +} diff --git a/src/nixos/impermanence.nix b/src/nixos/impermanence.nix index 29218e8..64c6043 100644 --- a/src/nixos/impermanence.nix +++ b/src/nixos/impermanence.nix @@ -76,6 +76,7 @@ in # shut sudo up security.sudo.extraConfig = "Defaults lecture=never"; + programs.fuse.userAllowOther = true; # setup persistence environment.persistence = { diff --git a/src/nixos/keyd.nix b/src/nixos/keyd.nix index 1e64acb..2d9db46 100644 --- a/src/nixos/keyd.nix +++ b/src/nixos/keyd.nix @@ -1,40 +1,50 @@ -{ config, ... }: +{ config, lib, ... }: +let + commonSettings = { + main = { + capslock = "layer(capslock)"; + insert = "S-insert"; + }; + meta = { + w = "macro(C-w)"; + a = "macro(C-a)"; + }; + "capslock:C" = { }; + }; +in { + users.groups.keyd = {}; services.keyd = { enable = true; keyboards = { default = { ids = [ "*" ]; - settings = { - main = { - capslock = "layer(capslock)"; - insert = "S-insert"; - }; - meta = { - w = "macro(C-w)"; - a = "macro(C-a)"; - }; - "capslock:C" = { }; - }; + settings = commonSettings; }; framework = { ids = [ "0001:0001:a38e6885" ]; - settings = { - main = { - leftalt = "layer(meta)"; - leftmeta = "layer(alt)"; - }; - }; + settings = lib.mkMerge ([ + commonSettings + { + main = { + leftalt = "layer(meta)"; + leftmeta = "layer(alt)"; + }; + } + ]); }; normal = { ids = [ "413c:2107:eb8bfad1" ]; - settings = { - main = { - leftalt = "layer(meta)"; - leftmeta = "layer(alt)"; - }; - }; + settings = lib.mkMerge ([ + commonSettings + { + main = { + leftalt = "layer(meta)"; + leftmeta = "layer(alt)"; + }; + } + ]); }; }; }; diff --git a/src/nixos/stylix.nix b/src/nixos/stylix.nix new file mode 100644 index 0000000..967a336 --- /dev/null +++ b/src/nixos/stylix.nix @@ -0,0 +1,31 @@ +{ pkgs, config, ... }: + +{ + stylix = { + enable = true; + autoEnable = false; + image = pkgs.nixos-artwork.wallpapers.nineish-dark-gray.src; + # base16Scheme = "${pkgs.base16-schemes}/share/themes/gruvbox-dark-hard.yaml"; + base16Scheme = "${pkgs.base16-schemes}/share/themes/gruber.yaml"; + polarity = "dark"; + fonts = { + serif = config.stylix.fonts.sansSerif; + sansSerif = { + package = pkgs.dejavu_fonts; + name = "DejaVu Sans"; + }; + # sansSerif = { + # package = config.custom.nerdfonts.package; + # name = "DejaVu Sans Mono"; + # }; + monospace = { + package = config.custom.nerdfonts.package; + name = "SauceCodePro Nerd Font Mono"; + }; + emoji = { + package = pkgs.noto-fonts-emoji; + name = "Noto Color Emoji"; + }; + }; + }; +} diff --git a/src/nixos/zfs.nix b/src/nixos/zfs.nix index c3675ad..2c7a821 100644 --- a/src/nixos/zfs.nix +++ b/src/nixos/zfs.nix @@ -25,4 +25,15 @@ } ); + systemd.services = { + # https://github.com/openzfs/zfs/issues/10891 + systemd-udev-settle.enable = false; + # snapshot dirs sometimes not accessible + # https://github.com/NixOS/nixpkgs/issues/257505#issuecomment-2348313665 + zfs-mount = { + serviceConfig = { + ExecStart = [ "${lib.getExe' pkgs.util-linux "mount"} -t zfs zroot/persist -o remount" ]; + }; + }; + }; }