diff options
| -rw-r--r-- | hosts/sagittarius/home.nix | 8 | ||||
| -rw-r--r-- | hosts/wonderland/default.nix | 3 | ||||
| -rw-r--r-- | hosts/wonderland/home.nix | 78 | ||||
| -rw-r--r-- | share/home/hyprdesktop.nix | 70 | ||||
| -rw-r--r-- | share/home/minimal.nix (renamed from share/home/default.nix) | 42 |
5 files changed, 92 insertions, 109 deletions
diff --git a/hosts/sagittarius/home.nix b/hosts/sagittarius/home.nix index 24d742d..11d2b06 100644 --- a/hosts/sagittarius/home.nix +++ b/hosts/sagittarius/home.nix @@ -3,13 +3,7 @@ useGlobalPkgs = true; useUserPackages = true; sharedModules = [ - { imports = [ (flakeRoot + /share/home) ]; } - { - programs.direnv = { - enable = true; - nix-direnv.enable = true; - }; - } + { imports = [ (flakeRoot + /share/home/minimal.nix) ]; } ]; users = { diff --git a/hosts/wonderland/default.nix b/hosts/wonderland/default.nix index a314706..2510696 100644 --- a/hosts/wonderland/default.nix +++ b/hosts/wonderland/default.nix @@ -1,4 +1,4 @@ -{ config, pkgs, flakeRoot, ... }: { +{ config, pkgs, flakeRoot, inputs, ... }: { imports = [ # Include the results of the hardware scan. ./hardware.nix @@ -7,6 +7,7 @@ (flakeRoot + /share/system/steam.nix) (flakeRoot + /share/system/hyprland.nix) #(flakeRoot + /share/system/spotifyd.nix) + { _module.args = { inherit inputs; }; } ]; nixpkgs.config.allowUnfree = true; diff --git a/hosts/wonderland/home.nix b/hosts/wonderland/home.nix index 05d726e..3ca97a0 100644 --- a/hosts/wonderland/home.nix +++ b/hosts/wonderland/home.nix @@ -2,85 +2,29 @@ , flakeRoot , inputs , ... -}: -let - desktop-pkgs = with pkgs; [ - mullvad - calibre - beekeeper-studio - thunderbird - brightnessctl - cmus # music player - - libreoffice-qt - discord - - nsxiv - inputs.scripts.packages.${pkgs.system}.image-move - - wineWowPackages.full - winetricks - ]; -in -{ +}: { home-manager = { useGlobalPkgs = true; useUserPackages = true; - sharedModules = [{ imports = [ (flakeRoot + /share/home) ]; }]; + sharedModules = [{ imports = [ (flakeRoot + /share/home/hyprdesktop.nix) ]; }]; + extraSpecialArgs = { inherit inputs; }; }; home-manager.users.alice = { - imports = - let - home = flakeRoot + /share/home; - in - [ - # Config - (home + /hyprland.nix) - (home + /git.nix) - (home + /gallery-dl.nix) - (home + /mpv.nix) - (home + /firefox) - ]; - home.packages = with pkgs; - [ - signal-desktop - tdesktop # Telegram desktop - qbittorrent - emacs - # spotify-qt librespot - fluffychat # matrix client - - # Various utils - # qemu_kvm - tokei # counts lines of code - btop # modern top - qemu_kvm - - # Gaming - jdk17_headless - superTuxKart - ] - ++ desktop-pkgs; + imports = [ + (flakeRoot + /share/home/gallery-dl.nix) + ]; services.poweralertd.enable = true; + home.packages = with pkgs; [ + emacs + mullvad + ]; + home.stateVersion = "22.05"; }; # End of users.alice home-manager.users.madhatter = { - home.packages = desktop-pkgs; - imports = - let - home = flakeRoot + /share/home; - in - [ - # Config - (home + /kitty.nix) - (home + /git.nix) - (home + /mpv.nix) - (home + /firefox) - ]; - home.stateVersion = "23.05"; }; diff --git a/share/home/hyprdesktop.nix b/share/home/hyprdesktop.nix new file mode 100644 index 0000000..fc657ea --- /dev/null +++ b/share/home/hyprdesktop.nix @@ -0,0 +1,70 @@ +# Module containing a bunch of things that make up a `desktop environment` built +# off of hyprland. I install this on all my desktop/laptop machines. +{ pkgs, config, inputs, ... }: { + imports = [ + ./minimal.nix + ./hyprland.nix + ./git.nix + ./mpv.nix + ./kitty.nix + ./firefox + ]; + + home.packages = with pkgs; [ + xh # Nice to use HTTP client + bc # CLI calculator + amfora # Gemini CLI browser + trashy # Trash CLI + tokei # counts lines of code + btop # modern top + brightnessctl + wineWowPackages.full + winetricks + inputs.scripts.packages.${pkgs.system}.image-move + qemu_kvm + + # TUI/GUI programs + cmus # music player + calibre # Document organisation/reading program + libreoffice-qt + beekeeper-studio # SQL database client + thunderbird # email client + nsxiv # image viewer + discord + signal-desktop + tdesktop # Telegram desktop + fluffychat # matrix client + qbittorrent # bittorrent client + + # Gaming + jdk17_headless + superTuxKart + ]; + + programs.direnv = { + enable = true; + nix-direnv.enable = true; + }; + + xdg = { + systemDirs.data = + let + gds = pkgs.gsettings-desktop-schemas; + gtk3 = pkgs.gtk3; + in + [ + "${gds}/share/gsettings-schemas/${gds.name}" + "${gtk3}/share/gsettings-schemas/${gtk3.name}" + ]; + userDirs = + let + home = config.home.homeDirectory; + in + { + enable = true; + createDirectories = true; + pictures = "${home}/Annex/Pictures"; + music = "${home}/Annex/Music"; + }; + }; +} diff --git a/share/home/default.nix b/share/home/minimal.nix index 6213e8b..c844000 100644 --- a/share/home/default.nix +++ b/share/home/minimal.nix @@ -1,5 +1,5 @@ -# Minimal home configuration containing everything that I want on all of -# my machines +# This module contains a bunch of things that make up a minimal environment that +# I want on ALL of my machines. { pkgs, config, ... }: { imports = [ ./helix.nix ./zsh.nix ]; @@ -8,7 +8,7 @@ git age gnupg - xh + ffmpeg # Modern unix ripgrep # grep @@ -16,10 +16,6 @@ sd # sed dua # du - bc # CLI calculator - ffmpeg - amfora # Gemini CLI browser - trashy # Trash CLI git-annex git-remote-gcrypt @@ -32,36 +28,14 @@ nix-tree ]; - programs.direnv = { - enable = true; - nix-direnv.enable = true; - }; - - xdg = { - enable = true; - systemDirs.data = - let - gds = pkgs.gsettings-desktop-schemas; - gtk3 = pkgs.gtk3; - in - [ - "${gds}/share/gsettings-schemas/${gds.name}" - "${gtk3}/share/gsettings-schemas/${gtk3.name}" - ]; - userDirs = - let - home = config.home.homeDirectory; - in - { - enable = true; - createDirectories = true; - pictures = "${home}/Annex/Pictures"; - music = "${home}/Annex/Music"; - }; - }; + xdg.enable = true; # Lots of these are courtesy of xdg-ninja # https://github.com/b3nj5m1n/xdg-ninja + # + # Even though these tools may or may not be installed on any particular system + # having these variables here is a preventative measure to make sure that + # $HOME doesn't get polluted home.sessionVariables = with config.xdg; { CARGO_HOME = "${dataHome}/cargo"; GOPATH = "${dataHome}/go"; |
