diff --git a/flake.lock b/flake.lock index 43be47a..e3fdf12 100644 --- a/flake.lock +++ b/flake.lock @@ -1,23 +1,33 @@ { "nodes": { - "haumea": { - "inputs": { - "nixpkgs": [ - "nixpkgs" - ] - }, + "catppuccin": { "locked": { - "lastModified": 1685133229, - "narHash": "sha256-FePm/Gi9PBSNwiDFq3N+DWdfxFq0UKsVVTJS3cQPn94=", - "owner": "nix-community", - "repo": "haumea", - "rev": "34dd58385092a23018748b50f9b23de6266dffc2", + "lastModified": 1716884128, + "narHash": "sha256-hzTzcX/qIGf93WVvk2jlLL3N7IgIlWylOBQkgwfTq8w=", + "owner": "catppuccin", + "repo": "nix", + "rev": "296adaf9331cd2c1eb479a25d5207508fbd06188", "type": "github" }, "original": { - "owner": "nix-community", - "ref": "v0.2.2", - "repo": "haumea", + "owner": "catppuccin", + "repo": "nix", + "type": "github" + } + }, + "hardware": { + "locked": { + "lastModified": 1716881121, + "narHash": "sha256-oTf3enbe/lbiNzsyZ8ria+422hx4e/FB3xQcY2LPnJw=", + "owner": "NixOS", + "repo": "nixos-hardware", + "rev": "806e9d4a933dd1e75592e88894d4bd2f296f5bbf", + "type": "github" + }, + "original": { + "owner": "NixOS", + "ref": "master", + "repo": "nixos-hardware", "type": "github" } }, @@ -28,11 +38,11 @@ ] }, "locked": { - "lastModified": 1715930644, - "narHash": "sha256-W9pyM3/vePxrffHtzlJI6lDS3seANQ+Nqp+i58O46LI=", + "lastModified": 1716908526, + "narHash": "sha256-Zl6e/sEVDh07K47XxDGPsXTYT4nI6llUDbQ4xMIwp7k=", "owner": "nix-community", "repo": "home-manager", - "rev": "e3ad5108f54177e6520535768ddbf1e6af54b59d", + "rev": "373ead20606efa9181cd15ba19a5deac7ead1492", "type": "github" }, "original": { @@ -44,11 +54,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1715787315, - "narHash": "sha256-cYApT0NXJfqBkKcci7D9Kr4CBYZKOQKDYA23q8XNuWg=", + "lastModified": 1716509168, + "narHash": "sha256-4zSIhSRRIoEBwjbPm3YiGtbd8HDWzFxJjw5DYSDy1n8=", "owner": "nixos", "repo": "nixpkgs", - "rev": "33d1e753c82ffc557b4a585c77de43d4c922ebb5", + "rev": "bfb7a882678e518398ce9a31a881538679f6f092", "type": "github" }, "original": { @@ -58,6 +68,22 @@ "type": "github" } }, + "nixpkgs-catppuccin": { + "locked": { + "lastModified": 1716835396, + "narHash": "sha256-H2dN5tooIaHqbU52ldreAhbxE33fxASflPqvMsoQFQc=", + "owner": "isabelroses", + "repo": "nixpkgs", + "rev": "a554569da3b72f2896aa26537a4339ac45a15f66", + "type": "github" + }, + "original": { + "owner": "isabelroses", + "ref": "update-catppuccin", + "repo": "nixpkgs", + "type": "github" + } + }, "plasma-manager": { "inputs": { "home-manager": [ @@ -68,11 +94,11 @@ ] }, "locked": { - "lastModified": 1714856962, - "narHash": "sha256-2te5GG8TVNBF44uMF4G0XFGW+Jt02i/ZkspSNFzjgT0=", + "lastModified": 1716902607, + "narHash": "sha256-jShqpVupP/7ksp6gCBVG9/05zYSX8Q+z6eGe9HLYtUs=", "owner": "pjones", "repo": "plasma-manager", - "rev": "1554e19ede17de46106dd95820eeea05086a5720", + "rev": "4a255e5ea6bf2c7815d893a693c5c801d835ba6b", "type": "github" }, "original": { @@ -83,9 +109,11 @@ }, "root": { "inputs": { - "haumea": "haumea", + "catppuccin": "catppuccin", + "hardware": "hardware", "home-manager": "home-manager", "nixpkgs": "nixpkgs", + "nixpkgs-catppuccin": "nixpkgs-catppuccin", "plasma-manager": "plasma-manager" } } diff --git a/flake.nix b/flake.nix index ab40ff0..ed36c9d 100644 --- a/flake.nix +++ b/flake.nix @@ -18,14 +18,14 @@ inputs.home-manager.follows = "home-manager"; }; - # Haumea (map directory structure into an attribute set) - haumea = { - url = "github:nix-community/haumea/v0.2.2"; - inputs.nixpkgs.follows = "nixpkgs"; - }; + hardware.url = "github:NixOS/nixos-hardware/master"; + + catppuccin.url = "github:catppuccin/nix"; + + nixpkgs-catppuccin.url = "github:isabelroses/nixpkgs/update-catppuccin"; }; - outputs = { self, nixpkgs, home-manager, plasma-manager, haumea, ... } @inputs: + outputs = { self, nixpkgs, home-manager, plasma-manager, hardware, catppuccin, nixpkgs-catppuccin, ... } @inputs: let inherit (self) outputs; diff --git a/hosts/puzzlevision/configuration.nix b/hosts/puzzlevision/configuration.nix index 743f446..cf3d168 100644 --- a/hosts/puzzlevision/configuration.nix +++ b/hosts/puzzlevision/configuration.nix @@ -8,10 +8,10 @@ }: { # You can import other NixOS modules here imports = [ - # If you want to use modules from other flakes (such as nixos-hardware): - # inputs.hardware.nixosModules.common-cpu-amd - # inputs.hardware.nixosModules.common-ssd - outputs.nixosModules.desktop.kde + inputs.hardware.nixosModules.common-pc-laptop + inputs.hardware.nixosModules.common-cpu-intel + inputs.hardware.nixosModules.common-pc-laptop-ssd + outputs.nixosModules.desktop.gnome ./hardware-configuration.nix ]; @@ -46,13 +46,16 @@ options = "--delete-older-than 3d"; }; }; + + # Set hostname + networking.hostName = "puzzlevision"; + + # Enable networking + networking.networkmanager.enable = true; # Install the latest kernel boot.kernelPackages = pkgs.linuxPackages_latest; - # Improve SSD performance - fileSystems."/".options = [ "noatime" "nodiratime" "discard" ]; - # Bootloader. boot.loader.grub = { enable = true; @@ -70,11 +73,6 @@ ''; }; - networking.hostName = "puzzlevision"; - - # Enable networking - networking.networkmanager.enable = true; - # Set your time zone. time.timeZone = "Europe/Berlin"; @@ -114,8 +112,16 @@ }; # Enable bluetooth on boot - hardware.bluetooth.enable = true; - hardware.bluetooth.powerOnBoot = true; + hardware.bluetooth = { + enable = true; + powerOnBoot = true; + + settings = { + General = { + Disable = "Handsfree"; + }; + }; + }; # Enable automatic screen rotation and similar features hardware.sensor.iio.enable = true; @@ -134,11 +140,11 @@ users.defaultUserShell = pkgs.fish; programs.fish.enable = true; - # Define a user account. + # Define user accounts users.users = { jo = { isNormalUser = true; - description = "Personal account for general tasks"; + description = "Jo"; initialPassword = "jo"; extraGroups = [ "networkmanager" "wheel" "docker" "tty" "dialout" ]; }; diff --git a/modules/home-manager/default.nix b/modules/home-manager/default.nix index 559cfc5..6a2b195 100644 --- a/modules/home-manager/default.nix +++ b/modules/home-manager/default.nix @@ -3,6 +3,11 @@ gruvbox = { plasma = import ./themes/gruvbox/plasma.nix; }; + + catppuccin = { + gnome = import ./themes/catppuccin/gnome.nix; + global = import ./themes/catppuccin/global.nix; + }; }; development = { diff --git a/modules/home-manager/development/ssh.nix b/modules/home-manager/development/ssh.nix index 8b2b540..66ef821 100644 --- a/modules/home-manager/development/ssh.nix +++ b/modules/home-manager/development/ssh.nix @@ -9,8 +9,6 @@ in { openssh ]; - services.ssh-agent.enable = true; - programs.ssh = { enable = true; extraConfig = '' diff --git a/modules/home-manager/themes/catppuccin/global.nix b/modules/home-manager/themes/catppuccin/global.nix new file mode 100644 index 0000000..cd2f047 --- /dev/null +++ b/modules/home-manager/themes/catppuccin/global.nix @@ -0,0 +1,17 @@ +{ + inputs, + pkgs, + outputs, + lib, + ... +}: { + imports = [ + inputs.catppuccin.homeManagerModules.catppuccin + ]; + + catppuccin = { + enable = true; + accent = "blue"; + flavor = "macchiato"; + }; +} \ No newline at end of file diff --git a/modules/home-manager/themes/catppuccin/gnome.nix b/modules/home-manager/themes/catppuccin/gnome.nix new file mode 100644 index 0000000..348e453 --- /dev/null +++ b/modules/home-manager/themes/catppuccin/gnome.nix @@ -0,0 +1,12 @@ +{ + inputs, + pkgs, + outputs, + lib, + ... +}: { + gtk = { + enable = true; + catppuccin.enable = true; + }; +} \ No newline at end of file diff --git a/modules/nixos/desktop/gnome.nix b/modules/nixos/desktop/gnome.nix index f153ec3..8f7ba51 100644 --- a/modules/nixos/desktop/gnome.nix +++ b/modules/nixos/desktop/gnome.nix @@ -9,6 +9,35 @@ services.xserver.enable = true; # Enable the GNOME Desktop Environment. - services.displayManager.gdm.enable = true; - services.desktopManager.gnome.enable = true; -} + services.xserver.displayManager.gdm.enable = true; + services.xserver.desktopManager.gnome.enable = true; + + environment.gnome.excludePackages = (with pkgs; [ + gnome-tour + gedit + ]) ++ (with pkgs.gnome; [ + cheese + gnome-music + epiphany # Gnome web + tali # Poker game + iagno # Go game + hitori # Sudoku game + yelp # Help view + gnome-contacts + gnome-initial-setup + geary + ]); + + programs.dconf.enable = true; + + services.gnome.gnome-keyring.enable = true; + + programs.kdeconnect = { + enable = true; + package = pkgs.gnomeExtensions.gsconnect; + }; + + environment.systemPackages = with pkgs; [ + gnome.gnome-tweaks + ]; +} \ No newline at end of file diff --git a/pkgs/default.nix b/pkgs/default.nix index 0c5e483..7cb14e4 100644 --- a/pkgs/default.nix +++ b/pkgs/default.nix @@ -5,4 +5,8 @@ pkgs: { themes = { kde-gruvbox-colors = pkgs.callPackage ./themes/kde-gruvbox-colors.nix { }; }; + + gnomeExtensions = { + rounded-window-corners = pkgs.callPackage ./gnomeExtensions/rounded-window-corners.nix { }; + }; } diff --git a/pkgs/gnomeExtensions/rounded-window-corners.nix b/pkgs/gnomeExtensions/rounded-window-corners.nix new file mode 100644 index 0000000..f504a9d --- /dev/null +++ b/pkgs/gnomeExtensions/rounded-window-corners.nix @@ -0,0 +1,26 @@ +{ stdenv, fetchFromGitHub, pkgs }: + +stdenv.mkDerivation rec { + pname = "rounded-window-corners"; + version = "1.0.0"; + + src = fetchFromGitHub { + owner = "flexagoon"; + repo = pname; + rev = "61c326e3d6cba36fe3d07cf1c15e6c74d3f9abb1"; + sha256 = "sha256-jS6G9wSKSXAxNhCmuew6pTcYa1gTZqbfrcAZ0ky4vkc="; + }; + + buildInputs = with pkgs; [ nodejs_22 gettext just ]; + + installPhase = '' + runHook preInstall + + just install + + mkdir -p $out/share/gnome-shell/extensions + cp ~/.local/share/gnome-shell/extensions/rounded-window-corners@fxgn $out/share/gnome-shell/extensions/rounded-window-corners@fxgn + + runHook postInstall + ''; +} \ No newline at end of file diff --git a/resources/wallpapers/animals_at_campfire.jpg b/resources/wallpapers/animals_at_campfire.jpg new file mode 100644 index 0000000..cc76e9a Binary files /dev/null and b/resources/wallpapers/animals_at_campfire.jpg differ diff --git a/users/gaming/home.nix b/users/gaming/home.nix index e219d92..9c5d872 100644 --- a/users/gaming/home.nix +++ b/users/gaming/home.nix @@ -30,6 +30,7 @@ lutris vesktop steam + lunar-client ]; # Enable home-manager diff --git a/users/jo/desktop/gnome.nix b/users/jo/desktop/gnome.nix new file mode 100644 index 0000000..1fcc6c8 --- /dev/null +++ b/users/jo/desktop/gnome.nix @@ -0,0 +1,72 @@ +{ + inputs, + pkgs, + outputs, + lib, + ... +}: { + home.packages = with pkgs.gnomeExtensions; [ + dash-to-dock + user-themes + blur-my-shell + appindicator + unite + ]; + + gtk = { + enable = true; + catppuccin.enable = true; + }; + + # Use `dconf watch /` to track stateful changes you are doing, then set them here. + dconf.settings = { + "org/gnome/desktop/interface" = { + color-scheme = "prefer-dark"; + }; + + "org/gnome/shell" = { + favorite-apps = [ + "org.gnome.Nautilus.desktop" + "firefox.desktop" + "spotify.desktop" + "phpstorm.desktop" + ]; + + enabled-extensions = [ + "user-theme@gnome-shell-extensions.gcampax.github.com" + "dash-to-dock@micxgx.gmail.com" + "blur-my-shell@aunetx" + "appindicatorsupport@rgcjonas.gmail.com" + "unite@hardpixel.eu" + ]; + }; + + "org/gnome/desktop/wm/preferences" = { + workspace-names = [ "Main" ]; + }; + + "org/gnome/desktop/background" = { + picture-uri = "${outputs.resources.wallpapers}/animals_at_campfire.jpg"; + picture-uri-dark = "${outputs.resources.wallpapers}/animals_at_campfire.jpg"; + }; + + "org/gnome/shell/extensions/unite" = { + use-activities-text = false; + extend-left-box = false; + reduce-panel-spacing = false; + window-buttons-placement = "first"; + show-legacy-tray = false; + show-appmenu-button = false; + show-desktop-name = false; + enable-titlebar-actions = false; + restrict-to-primary-screen = true; + hide-activities-button = "never"; + hide-window-titlebars = "maximized"; + show-window-title = false; + autofocus-windows = true; + show-window-buttons = "maximized"; + notifications-position = "right"; + window-buttons-theme = "catppuccin"; + }; + }; +} diff --git a/users/jo/home.nix b/users/jo/home.nix index 95a88fa..ef91c2d 100644 --- a/users/jo/home.nix +++ b/users/jo/home.nix @@ -7,7 +7,8 @@ ... }: { imports = [ - ./desktop/kde.nix + ./desktop/gnome.nix + outputs.homeManagerModules.themes.catppuccin.global outputs.homeManagerModules.development.ssh ]; @@ -31,6 +32,7 @@ qflipper wineWowPackages.waylandFull vesktop + lunar-client # For development avra @@ -38,7 +40,11 @@ vscodium jetbrains.phpstorm git - bun + nodejs_22 + + # Work stuff for when I'm not actually working + teams-for-linux + enpass ]; # Enable home-manager