From 992f77e656d298463aedea1290604b9a72b2a488 Mon Sep 17 00:00:00 2001 From: Natalie Date: Fri, 1 Aug 2025 20:59:12 -0700 Subject: [PATCH] clean up default home options, add lsd --- modules/home/default.nix | 135 ++++++++++++++++++++------------------- modules/nixos/ld.nix | 10 ++- users/natalie/home.nix | 1 + 3 files changed, 79 insertions(+), 67 deletions(-) diff --git a/modules/home/default.nix b/modules/home/default.nix index b9fd238..c7102e2 100644 --- a/modules/home/default.nix +++ b/modules/home/default.nix @@ -23,82 +23,85 @@ in description = "set the ghostty shader, relative to 'files/ghostty'"; }; }; - config.programs = { - home-manager.enable = true; - nix-index.enable = true; + config = { + home.shell = { + enableShellIntegration = true; + }; + programs = { + home-manager.enable = true; + nix-index.enable = true; - direnv = { - enableZshIntegration = true; - nix-direnv.enable = config.programs.direnv.enable; - }; + direnv = { + nix-direnv.enable = config.programs.direnv.enable; + }; - git = { - enable = true; - userName = lib.mkDefault user.name; - userEmail = lib.mkDefault user.email; - ignores = [ - (lib.mkIf host.darwin ".DS_Store") # When using Finder - (lib.mkIf host.darwin "._*") # When using non-APFS drives - # ViM and Neovim - ".*.swp" - ".nvimlog" - ]; - }; + git = { + enable = true; + userName = lib.mkDefault user.name; + userEmail = lib.mkDefault user.email; + ignores = [ + (lib.mkIf host.darwin ".DS_Store") # When using Finder + (lib.mkIf host.darwin "._*") # When using non-APFS drives + # ViM and Neovim + ".*.swp" + ".nvimlog" + ]; + }; - atuin = { - enableBashIntegration = true; - enableFishIntegration = true; - daemon.enable = cfg.atuin.enable; - }; - bat = { - extraPackages = with pkgs.bat-extras; [ - batdiff - batman - batgrep - batwatch - batpipe - prettybat - ]; - }; - hyfetch = { - settings = { - backend = "fastfetch"; - preset = user.sexuality; - mode = "rgb"; - light_dark = "dark"; - lightness = { - }; - color_align = { - mode = "horizontal"; + atuin = { + daemon.enable = cfg.atuin.enable; + }; + + bat = { + extraPackages = with pkgs.bat-extras; [ + batdiff + batman + batgrep + batwatch + batpipe + prettybat + ]; + }; + hyfetch = { + settings = { + backend = "fastfetch"; + preset = user.sexuality; + mode = "rgb"; + light_dark = "dark"; + lightness = { + }; + color_align = { + mode = "horizontal"; + }; }; }; - }; - fastfetch.enable = cfg.hyfetch.enable; + fastfetch.enable = cfg.hyfetch.enable; - fish = { - plugins = [ - { - name = "tide"; - inherit (pkgs.fishPlugins.tide) src; + fish = { + plugins = [ + { + name = "tide"; + inherit (pkgs.fishPlugins.tide) src; + } + { + name = "!!"; + inherit (pkgs.fishPlugins.bang-bang) src; + } + ]; + shellAliases = { } - { - name = "!!"; - inherit (pkgs.fishPlugins.bang-bang) src; - } - ]; - shellAliases = - { } // lib.optionalAttrs (!host.darwin) { reboot-windows = "sudo efibootmgr --bootnext 0000; sudo reboot -h now"; }; - shellInit = '' - batman --export-env | source - test -r '/Users/${user.username}/.opam/opam-init/init.fish' && source '/Users/${user.username}/.opam/opam-init/init.fish' > /dev/null 2> /dev/null; or true - ''; - }; + shellInit = '' + batman --export-env | source + test -r '/Users/${user.username}/.opam/opam-init/init.fish' && source '/Users/${user.username}/.opam/opam-init/init.fish' > /dev/null 2> /dev/null; or true + ''; + }; - ghostty.settings.custom-shader = lib.mkIf ( - cfg.ghostty.shader != null - ) "${../../files/ghostty}/${cfg.ghostty.shader}"; + ghostty.settings.custom-shader = lib.mkIf ( + cfg.ghostty.shader != null + ) "${../../files/ghostty}/${cfg.ghostty.shader}"; + }; }; } diff --git a/modules/nixos/ld.nix b/modules/nixos/ld.nix index 0bb6938..fc09f68 100644 --- a/modules/nixos/ld.nix +++ b/modules/nixos/ld.nix @@ -63,7 +63,7 @@ nss openssl pango - # pipewire + pipewire stdenv.cc.cc systemd vulkan-loader @@ -82,5 +82,13 @@ xorg.libxkbfile xorg.libxshmfence zlib + libxslt + + # Stolen from https://github.com/Mic92/dotfiles/blob/57cf7fdf8705a5362fc19114b8395cdbf7668e94/nixos/modules/nix-ld.nix#L6-L58 + flite + gtk2 + gtk2-x11 + libsecret + xorg.libXinerama ]; } diff --git a/users/natalie/home.nix b/users/natalie/home.nix index 526e94c..9dfdb5c 100644 --- a/users/natalie/home.nix +++ b/users/natalie/home.nix @@ -12,6 +12,7 @@ direnv.enable = true; fish.enable = true; man.generateCaches = false; + lsd.enable = true; # sort-lines:end };