From c9cee3835da65232ee497afedf6e3111599e3f0a Mon Sep 17 00:00:00 2001 From: Nichkara Date: Tue, 10 Feb 2026 13:55:20 +0100 Subject: [PATCH] Switching to hyprland and hyprland conf --- configuration.nix | 8 ++------ desktop-environment.nix | 44 +++++++++++++++++++++++++++++++++++++++++ 2 files changed, 46 insertions(+), 6 deletions(-) create mode 100644 desktop-environment.nix diff --git a/configuration.nix b/configuration.nix index dd493b0..34e3b63 100755 --- a/configuration.nix +++ b/configuration.nix @@ -8,6 +8,7 @@ imports = [ # Include the results of the hardware scan. ./hardware-configuration.nix + ./desktop-environment.nix ]; # Bootloader. @@ -17,10 +18,6 @@ networking.hostName = "amelia"; # Define your hostname. # networking.wireless.enable = true; # Enables wireless support via wpa_supplicant. - # Configure network proxy if necessary - # networking.proxy.default = "http://user:password@proxy:port/"; - # networking.proxy.noProxy = "127.0.0.1,localhost,internal.domain"; - # Enable networking networking.networkmanager.enable = true; @@ -52,7 +49,7 @@ services.xserver.enable = true; services.xserver.displayManager.sddm.enable = true; services.xserver.displayManager.sddm.wayland.enable = true; - services.xserver.desktopManager.plasma6.enable = true; + services.xserver.desktopManager.plasma6.enable = false; # Configure console keymap console.keyMap = "de"; @@ -78,7 +75,6 @@ epiphany nodejs_24 cmake - kitty hyfetch elan gnat15 diff --git a/desktop-environment.nix b/desktop-environment.nix new file mode 100644 index 0000000..82afcac --- /dev/null +++ b/desktop-environment.nix @@ -0,0 +1,44 @@ +{ pkgs, ... }: +{ + programs.hyprland = { + enable = true; + xwayland.enable = true; + }; + + environment.systemPackages = with pkgs; [ + hyprland + kitty + waybar + wofi + hyprpaper + ]; + + services.dbus.enable = true; + programs.dconf.enable = true; + hardware.opengl.enable = true; + + services.greetd.enable = true; + services.greetd.settings.default_session.command = "Hyprland"; + + xdg.portal = { + enable = true; + extraPortals = [ pkgs.xdg-desktop-portal-hyprland ]; + }; + + systemd.user.services.hyprland-config = { + description = "Hyprland config synchronization."; + serviceConfig = { + Type = "oneshot"; + ExecStart = '' + HYPR="$HOME/.config/hypr" + if [ ! -d "$HYPR/.git" ]; then + git clone ssh://git@git.nichkara.eu/dotfiles/hypr.git "$HYPR" + else + git -C "$HYPR" pull --ff-only + fi + ''; + }; + + wantedBy = [ "default.target" ]; + }; +}