diff options
author | Leonardo Santiago <[email protected]> | 2025-05-08 00:48:42 -0300 |
---|---|---|
committer | Leonardo Santiago <[email protected]> | 2025-05-08 00:48:42 -0300 |
commit | dab1895180c9554abc2ca60d00e106bee393f640 (patch) | |
tree | 77f3f3e0729afcc7a1eb2d6011b84790f7303996 /modules/gnome/default.nix | |
parent | cd2a8d670aa8dbcc9be199797315e6a45adc1279 (diff) |
chore(gnome): rewrite extension logic to be able to more easily enable them separately
Diffstat (limited to 'modules/gnome/default.nix')
-rw-r--r-- | modules/gnome/default.nix | 84 |
1 files changed, 68 insertions, 16 deletions
diff --git a/modules/gnome/default.nix b/modules/gnome/default.nix index 8cf11c5..4422eef 100644 --- a/modules/gnome/default.nix +++ b/modules/gnome/default.nix @@ -1,27 +1,44 @@ { config, lib, pkgs, ...}: with lib; { imports = [ - ./gnome-config.nix + ./extensions.nix ]; - options.santi-modules.gnome.enable = mkEnableOption "Enable gnome"; + options.santi-modules.gnome = { + enable = mkEnableOption "Enable gnome"; + extensions = mkOption { + description = "Extensions to gnome"; + type = with types; attrsOf (submodule { + options = { + package = mkOption { + type = package; + description = "Extension package"; + }; + email = mkOption { + type = str; + description = "Extensions' maintainer email"; + }; + dconf-settings = mkOption { + type = attrs; + default = {}; + description = "Extra configuration to be passed to dconf"; + }; + enabled = mkEnableOption { + description = "Enable extension"; + }; + }; + }); + }; + }; config = mkIf config.santi-modules.gnome.enable { programs.dconf.enable = true; - environment.systemPackages = with pkgs; [ - gnome-tweaks - tela-icon-theme - hackneyed - ] ++ (with gnomeExtensions; [ - appindicator - vitals - user-themes - graphite-gtk-theme - x11-gestures - gsconnect - openweather-refined - ]); - environment.gnome.excludePackages = with pkgs; [ + gnome-font-viewer + gnome-connections + simple-scan + gnome-contacts gnome-photos gnome-tour + gnome-notes + gnome-text-editor gedit cheese gnome-terminal @@ -42,11 +59,46 @@ wayland = true; }; desktopManager.gnome.enable = true; + excludePackages = [ pkgs.xterm ]; }; services.udev.packages = [ pkgs.gnome-settings-daemon ]; services.gnome = { gnome-browser-connector.enable = true; gnome-keyring.enable = true; }; + home-manager.users.leonardo.dconf.settings = { + "org/gnome/desktop/background" = { + picture-uri = "${../../wallpaper.png}"; + picture-uri-dark = "${../../wallpaper.png}"; + picture-options = "zoom"; + }; + "org/gnome/desktop/interface" = { + color-scheme="prefer-dark"; + enable-hot-corners=false; + font-antialiasing="grayscale"; + font-hinting="slight"; + gtk-theme="Adwaita"; + cursor-theme="Hackneyed"; + icon-theme="Tela-brown-light"; + show-battery-percentage=true; + }; + "org/gnome/settings-daemon/plugins/power" = { + power-button-action="hibernate"; + sleep-inactive-ac-type="nothing"; + }; + "org/gnome/mutter" = { + dynamic-workspaces= true; + edge-tiling= true; + workspaces-only-on-primary= true; + experimental-features = [ "scale-monitor-framebuffer" "variable-refresh-rate"]; + }; + "org/gnome/shell" = { + disabled-extensions= [ + ]; + }; + "org/gnome/shell/app-switcher".current-workspace-only = true; + }; }; } |