94 lines
3.0 KiB
Nix
94 lines
3.0 KiB
Nix
{ inputs, lib, config, pkgs, ... }: {
|
|
imports = [
|
|
./hardware-configuration.nix # Current system hardware config
|
|
|
|
../common/stefan.nix
|
|
# ../modules/gnome.nix
|
|
];
|
|
|
|
nixpkgs.config.allowUnfree = true; # Allow proprietary packages
|
|
|
|
nix = { # Nix package manager settings
|
|
registry = lib.mapAttrs (_: value: { flake = value; }) inputs; # Adds each flake input to make nix3 commands consistent to flake
|
|
|
|
# This will additionally add your inputs to the system's legacy channels
|
|
# Making legacy nix commands consistent as well, awesome!
|
|
nixPath = lib.mapAttrsToList (key: value: "${key}=${value.to.path}") config.nix.registry;
|
|
|
|
settings = {
|
|
experimental-features = "nix-command flakes"; # Enable flake support
|
|
auto-optimise-store = true; # Duplicate and optimize nix store
|
|
};
|
|
gc = { # Automatic garbage collection
|
|
automatic = true;
|
|
dates = "weekly";
|
|
options = "--delete-older-than 2d";
|
|
};
|
|
};
|
|
|
|
boot = {
|
|
#kernelPackages = pkgs.linuxPackages_latest; # Latest stable kernel
|
|
loader = {
|
|
systemd-boot = {
|
|
enable = true;
|
|
configurationLimit = 5; # Limit the amount of configuration
|
|
};
|
|
efi.canTouchEfiVariables = true;
|
|
timeout = 1; # Grub autoselect time
|
|
};
|
|
};
|
|
|
|
networking = { # Network settings
|
|
hostName = "merkur";
|
|
networkmanager.enable = true;
|
|
};
|
|
|
|
security = {
|
|
rtkit.enable = true; # RealTimeKit ex. PulseAudio
|
|
polkit.enable = true;
|
|
};
|
|
|
|
i18n = { # internationalisation properties
|
|
defaultLocale = "de_DE.UTF-8";
|
|
extraLocaleSettings = {
|
|
LC_ADDRESS = "de_DE.UTF-8";
|
|
LC_IDENTIFICATION = "de_DE.UTF-8";
|
|
LC_MEASUREMENT = "de_DE.UTF-8";
|
|
LC_MONETARY = "de_DE.UTF-8";
|
|
LC_NAME = "de_DE.UTF-8";
|
|
LC_NUMERIC = "de_DE.UTF-8";
|
|
LC_PAPER = "de_DE.UTF-8";
|
|
LC_TELEPHONE = "de_DE.UTF-8";
|
|
LC_TIME = "de_DE.UTF-8";
|
|
};
|
|
};
|
|
|
|
services = {
|
|
xserver = {
|
|
layout = "de"; # X11 keymap
|
|
xkbVariant = "";
|
|
};
|
|
pipewire = { # Sound
|
|
enable = true;
|
|
alsa = {
|
|
enable = true;
|
|
support32Bit = true;
|
|
};
|
|
pulse.enable = true;
|
|
jack.enable = true;
|
|
};
|
|
};
|
|
|
|
environment = {
|
|
systemPackages = with pkgs; [
|
|
wget
|
|
tree
|
|
];
|
|
};
|
|
|
|
# Configure console keymap
|
|
console.keyMap = "de"; # Console keymap settings
|
|
|
|
system.stateVersion = "23.05"; # https://nixos.wiki/wiki/FAQ/When_do_I_update_stateVersion
|
|
}
|