diff --git a/hosts/kachu-laptop/configuration.nix b/hosts/kachu-laptop/configuration.nix index 7a698ff..af11b2b 100644 --- a/hosts/kachu-laptop/configuration.nix +++ b/hosts/kachu-laptop/configuration.nix @@ -5,11 +5,17 @@ config, lib, pkgs, + inputs, ... }: { + nixpkgs.overlays = [ + (final: prev: { + wezterm = final.callPackage ../../drvs/wezterm-stable-bin.nix {}; + sddm-astronaut-theme = final.callPackage ../../drvs/sddm-astronaut-theme.nix {}; + }) + ]; + imports = [ - # Include the results of the hardware scan. - ./hardware-configuration.nix ]; # Use the systemd-boot EFI boot loader. @@ -81,25 +87,6 @@ LC_TIME = "ru_RU.UTF-8"; }; - # Configure keymap in X11 - # services.xserver.xkb.layout = "us"; - # services.xserver.xkb.options = "eurosign:e,caps:escape"; - - # Enable CUPS to print documents. - # services.printing.enable = true; - - # Enable sound. - # services.pulseaudio.enable = true; - # OR - # services.pipewire = { - # enable = true; - # pulse.enable = true; - # }; - - # Enable touchpad support (enabled default in most desktopManager). - # services.libinput.enable = true; - - # Define a user account. Don't forget to set a password with ‘passwd’. users.users.kachu = { isNormalUser = true; extraGroups = ["wheel"]; # Enable ‘sudo’ for the user. @@ -116,6 +103,7 @@ v2rayn telegram-desktop ]; + shell = pkgs.zsh; }; programs.firefox.enable = true; @@ -132,6 +120,17 @@ kdePackages.kio-extras sbctl ]; + + programs.fuse.enable = true; + programs.zsh.enable = true; + + programs.nix-ld.enable = true; + programs.nix-ld.libraries = with pkgs; [ + ]; + + fonts.packages = [ + inputs.monaco-nerd-font.packages.${pkgs.system}.monaco + ]; # Some programs need SUID wrappers, can be configured further or are # started in user sessions. # programs.mtr.enable = true; @@ -149,7 +148,7 @@ # networking.firewall.allowedTCPPorts = [ ... ]; # networking.firewall.allowedUDPPorts = [ ... ]; # Or disable the firewall altogether. - # networking.firewall.enable = false; + networking.firewall.enable = false; # Copy the NixOS configuration file and link it from the resulting system # (/run/current-system/configuration.nix). This is useful in case you diff --git a/hosts/kachu-laptop/hardware-configuration.nix b/hosts/kachu-laptop/hardware-configuration.nix index e7ee3f6..794b927 100644 --- a/hosts/kachu-laptop/hardware-configuration.nix +++ b/hosts/kachu-laptop/hardware-configuration.nix @@ -74,4 +74,23 @@ nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux"; hardware.cpu.amd.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware; + + services.xserver.videoDrivers = ["nvidia" "amdgpu"]; + hardware.nvidia = { + open = true; + nvidiaSettings = true; + package = config.boot.kernelPackages.nvidiaPackages.stable; + powerManagement.enable = true; + powerManagement.finegrained = true; + + prime = { + offload = { + enable = true; + enableOffloadCmd = true; + }; + + amdgpuBusId = "PCI:0:36:0"; + nvidiaBusId = "PCI:0:1:0"; + }; + }; }