aboutsummaryrefslogtreecommitdiff
path: root/share/hm-modules
diff options
context:
space:
mode:
Diffstat (limited to 'share/hm-modules')
-rw-r--r--share/hm-modules/default.nix7
-rw-r--r--share/hm-modules/hyprdesktop.nix189
2 files changed, 195 insertions, 1 deletions
diff --git a/share/hm-modules/default.nix b/share/hm-modules/default.nix
new file mode 100644
index 0000000..834d9ea
--- /dev/null
+++ b/share/hm-modules/default.nix
@@ -0,0 +1,7 @@
+{ ... }: {
+ imports = [
+ ./hyprdesktop.nix
+ ./tofi.nix
+ ./wpaperd.nix
+ ];
+}
diff --git a/share/hm-modules/hyprdesktop.nix b/share/hm-modules/hyprdesktop.nix
index ffcd441..1b6fe96 100644
--- a/share/hm-modules/hyprdesktop.nix
+++ b/share/hm-modules/hyprdesktop.nix
@@ -1 +1,188 @@
-{ }
+{ config, pkgs, lib, ... }:
+let
+ inherit (lib) mkIf mkOption mkEnableOption types mdDoc lists;
+ cfg = config.custom.hyprdesktop;
+in
+{
+ imports = [ ../home/minimal.nix ];
+
+ options.custom.hyprdesktop = {
+ enable = mkEnableOption "Enable hyprdesktop";
+
+ mainUser = mkOption {
+ type = types.str;
+ example = "alice";
+ description = mdDoc "Main superuser's username.";
+ };
+
+ hasBluetooth = mkOption {
+ type = types.bool;
+ default = false;
+ example = "true";
+ };
+ hasBrightnessCtl = mkOption {
+ type = types.bool;
+ default = false;
+ example = "true";
+ };
+ hasBattery = mkOption {
+ type = types.bool;
+ default = false;
+ example = "true";
+ };
+
+ enableGaming = mkOption {
+ type = types.bool;
+ default = false;
+ example = "true";
+ };
+ enableWindowsCompat = mkOption {
+ type = types.bool;
+ default = false;
+ example = "true";
+ };
+ enableGitAnnex = mkOption {
+ type = types.bool;
+ default = true;
+ example = "false";
+ };
+ };
+
+ config = mkIf cfg.enable {
+ 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
+ wireplumber # session & policy manager for pipewire
+ grim # screenshot utility for wayland
+ slurp # region selection UI for wayland
+ wl-clipboard # clipboard utility
+ nushell # next-generation shell
+ ffmpeg
+ imagemagick
+ exiftool
+ sl
+ jaq # json query tool
+ mullvad
+ # tools for dealing with all sorts archives
+ atool
+ unzip
+ gnutar
+ unrar-wrapper
+ # Useful nix tooling
+ nix-tree
+ fzf
+
+ # 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
+ zathura # document reader
+ bitwarden # password manager
+ heroic # FOSS game launcher for GOG & Epic
+ foliate
+
+ # Other
+ # It seems that not all gtk icon themes contain all icons? At least the
+ # Flat-Remix icon themes don't contain all the icons that Foliate uses,
+ # so I'm bringing in the adwaita icons as a fallback.
+ gnome3.adwaita-icon-theme
+ ] ++ lists.optionals cfg.hasBluetooth [ overskride ]
+ ++ lists.optionals cfg.enableGaming [
+ jdk17_headless
+ superTuxKart
+ wineWowPackages.full
+ winetricks
+ ]
+ ++ lists.optionals (cfg.enableWindowsCompat || cfg.enableGaming) [
+ wineWowPackages.full
+ winetricks
+ qemu_kvm
+ ]
+ ++ lists.optionals cfg.hasBrightnessCtl [
+ brightnessctl
+ ]
+ ++ lists.optionals cfg.enableGitAnnex [
+ git-annex
+ git-remote-gcrypt
+ ];
+
+ home.shellAliases = {
+ sl = "sl -awFc5";
+ };
+
+ services.dunst.enable = true;
+ services.wpaperd.enable = true;
+ services.poweralertd.enable = cfg.hasBattery;
+
+ programs.mpv.enable = true;
+ programs.git.enable = true;
+ programs.kitty.enable = true;
+ programs.waybar.enable = true;
+ programs.firefox.enable = true;
+ programs.tofi.enable = true;
+
+ programs.gallery-dl.enable = true;
+
+ programs.fish.enable = true;
+ programs.eza.enable = true;
+ programs.starship.enable = true;
+ programs.atuin.enable = true;
+ programs.nix-index.enable = true;
+
+ programs.direnv = {
+ enable = true;
+ nix-direnv.enable = true;
+ };
+ programs.helix = {
+ enable = true;
+ defaultEditor = 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
+ annex = "${config.home.homeDirectory}/Annex";
+ in
+ {
+ enable = true;
+ createDirectories = true;
+ } // mkIf cfg.enableGitAnnex {
+ pictures = "${annex}/Pictures";
+ music = "${annex}/Music";
+ documents = "${annex}/Documents";
+ };
+ };
+
+ gtk = {
+ theme = {
+ package = pkgs.flat-remix-gtk;
+ name = "Flat-Remix-GTK-Blue-Darkest";
+ };
+ iconTheme = {
+ package = pkgs.flat-remix-icon-theme;
+ name = "Flat-Remix-Blue-Dark";
+ };
+ };
+ };
+}