2023-12-14 00:09:39 +01:00
|
|
|
|
# Edit this configuration file to define what should be installed on
|
|
|
|
|
# your system. Help is available in the configuration.nix(5) man page
|
|
|
|
|
# and in the NixOS manual (accessible by running ‘nixos-help’).
|
|
|
|
|
|
2024-01-13 07:05:01 +01:00
|
|
|
|
{ inputs, config, pkgs, username,
|
|
|
|
|
hostname, gitUsername, theLocale,
|
|
|
|
|
theTimezone, ... }:
|
2023-12-14 00:09:39 +01:00
|
|
|
|
|
|
|
|
|
{
|
|
|
|
|
imports =
|
2024-01-09 23:50:24 +01:00
|
|
|
|
[ # Include the results of the hardware scan.
|
|
|
|
|
./hardware-configuration.nix
|
2023-12-14 00:09:39 +01:00
|
|
|
|
];
|
|
|
|
|
|
2024-01-09 23:50:24 +01:00
|
|
|
|
# Bootloader.
|
2023-12-14 00:09:39 +01:00
|
|
|
|
boot.loader.systemd-boot.enable = true;
|
|
|
|
|
boot.loader.efi.canTouchEfiVariables = true;
|
2024-01-09 23:50:24 +01:00
|
|
|
|
boot.kernelModules = [ "v4l2loopback" ];
|
|
|
|
|
boot.extraModulePackages = [ config.boot.kernelPackages.v4l2loopback ];
|
2023-12-14 00:09:39 +01:00
|
|
|
|
|
2024-01-12 09:00:46 +01:00
|
|
|
|
networking.hostName = "${hostname}"; # Define your hostname.
|
2023-12-14 00:09:39 +01:00
|
|
|
|
|
2024-01-09 23:50:24 +01:00
|
|
|
|
# Enable networking
|
|
|
|
|
networking.networkmanager.enable = true;
|
|
|
|
|
|
2023-12-14 00:09:39 +01:00
|
|
|
|
# Set your time zone.
|
2024-01-13 07:05:01 +01:00
|
|
|
|
time.timeZone = "${theTimezone}";
|
2023-12-14 00:09:39 +01:00
|
|
|
|
|
|
|
|
|
# Select internationalisation properties.
|
2024-01-13 07:05:01 +01:00
|
|
|
|
i18n.defaultLocale = "${theLocale}";
|
2023-12-14 00:09:39 +01:00
|
|
|
|
|
|
|
|
|
i18n.extraLocaleSettings = {
|
2024-01-13 07:05:01 +01:00
|
|
|
|
LC_ADDRESS = "${theLocale}";
|
|
|
|
|
LC_IDENTIFICATION = "${theLocale}";
|
|
|
|
|
LC_MEASUREMENT = "${theLocale}";
|
|
|
|
|
LC_MONETARY = "${theLocale}";
|
|
|
|
|
LC_NAME = "${theLocale}";
|
|
|
|
|
LC_NUMERIC = "${theLocale}";
|
|
|
|
|
LC_PAPER = "${theLocale}";
|
|
|
|
|
LC_TELEPHONE = "${theLocale}";
|
|
|
|
|
LC_TIME = "${theLocale}";
|
2023-12-14 00:09:39 +01:00
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
# Define a user account. Don't forget to set a password with ‘passwd’.
|
2024-01-12 09:00:46 +01:00
|
|
|
|
users.users."${username}" = {
|
2024-01-11 07:19:08 +01:00
|
|
|
|
homeMode = "755";
|
2023-12-14 00:09:39 +01:00
|
|
|
|
isNormalUser = true;
|
2024-01-13 07:05:01 +01:00
|
|
|
|
description = "${gitUsername}";
|
2024-01-09 23:50:24 +01:00
|
|
|
|
extraGroups = [ "networkmanager" "wheel" ];
|
2023-12-14 00:09:39 +01:00
|
|
|
|
packages = with pkgs; [];
|
|
|
|
|
};
|
|
|
|
|
|
2024-01-09 23:50:24 +01:00
|
|
|
|
# Allow unfree packages
|
|
|
|
|
nixpkgs.config.allowUnfree = true;
|
2023-12-14 00:09:39 +01:00
|
|
|
|
|
|
|
|
|
# List packages installed in system profile. To search, run:
|
|
|
|
|
# $ nix search wget
|
|
|
|
|
environment.systemPackages = with pkgs; [
|
2024-01-16 21:07:33 +01:00
|
|
|
|
vim wget curl libsForQt5.qtstyleplugin-kvantum libsForQt5.qt5ct
|
2023-12-14 00:09:39 +01:00
|
|
|
|
];
|
|
|
|
|
|
2023-12-14 09:35:46 +01:00
|
|
|
|
fonts.packages = with pkgs; [
|
|
|
|
|
(nerdfonts.override { fonts = [ "JetBrainsMono" ]; })
|
|
|
|
|
];
|
2023-12-14 00:09:39 +01:00
|
|
|
|
|
|
|
|
|
# Steam Configuration
|
|
|
|
|
programs.steam = {
|
|
|
|
|
enable = true;
|
|
|
|
|
remotePlay.openFirewall = true;
|
|
|
|
|
dedicatedServer.openFirewall = true;
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
# OpenGL
|
|
|
|
|
hardware.opengl = {
|
|
|
|
|
enable = true;
|
|
|
|
|
driSupport = true;
|
|
|
|
|
driSupport32Bit = true;
|
|
|
|
|
};
|
|
|
|
|
|
2024-01-16 21:07:33 +01:00
|
|
|
|
nixpkgs.config.qt5 = {
|
|
|
|
|
enable = true;
|
|
|
|
|
platformTheme = "qt5ct";
|
|
|
|
|
style = {
|
|
|
|
|
package = pkgs.utterly-nord-plasma;
|
|
|
|
|
name = "Utterly Nord Plasma";
|
|
|
|
|
};
|
|
|
|
|
};
|
|
|
|
|
|
2024-01-09 23:50:24 +01:00
|
|
|
|
programs.hyprland = {
|
|
|
|
|
enable = true;
|
|
|
|
|
package = inputs.hyprland.packages.${pkgs.system}.hyprland;
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
# Some programs need SUID wrappers, can be configured further or are
|
|
|
|
|
# started in user sessions.
|
|
|
|
|
programs.mtr.enable = true;
|
|
|
|
|
programs.gnupg.agent = {
|
|
|
|
|
enable = true;
|
|
|
|
|
enableSSHSupport = true;
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
# List services that you want to enable:
|
|
|
|
|
services.openssh.enable = true;
|
|
|
|
|
services.fstrim.enable = true;
|
|
|
|
|
services.xserver = {
|
2024-01-11 06:57:01 +01:00
|
|
|
|
enable = true;
|
2024-01-09 23:50:24 +01:00
|
|
|
|
layout = "us";
|
|
|
|
|
xkbVariant = "";
|
|
|
|
|
libinput.enable = true;
|
|
|
|
|
videoDrivers = [ "amdgpu" ];
|
2024-01-11 06:50:20 +01:00
|
|
|
|
displayManager.gdm = {
|
|
|
|
|
enable = true;
|
|
|
|
|
wayland = true;
|
|
|
|
|
};
|
2024-01-09 23:50:24 +01:00
|
|
|
|
};
|
|
|
|
|
services.pipewire = {
|
|
|
|
|
enable = true;
|
|
|
|
|
alsa.enable = true;
|
|
|
|
|
alsa.support32Bit = true;
|
|
|
|
|
pulse.enable = true;
|
|
|
|
|
jack.enable = true;
|
|
|
|
|
};
|
|
|
|
|
hardware.pulseaudio.enable = false;
|
|
|
|
|
sound.enable = true;
|
|
|
|
|
security.rtkit.enable = true;
|
2024-01-11 05:03:15 +01:00
|
|
|
|
programs.thunar.enable = true;
|
|
|
|
|
services.gvfs.enable = true;
|
|
|
|
|
services.tumbler.enable = true;
|
2024-01-09 23:50:24 +01:00
|
|
|
|
|
|
|
|
|
system.stateVersion = "23.11";
|
2023-12-14 00:09:39 +01:00
|
|
|
|
nix = {
|
|
|
|
|
settings.auto-optimise-store = true;
|
|
|
|
|
gc = {
|
|
|
|
|
automatic = true;
|
|
|
|
|
dates = "weekly";
|
|
|
|
|
options = "--delete-older-than 7d";
|
|
|
|
|
};
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
# Set Environment Variables
|
|
|
|
|
environment.variables={
|
|
|
|
|
NIXOS_OZONE_WL = "1";
|
|
|
|
|
PATH = [
|
|
|
|
|
"\${HOME}/.local/bin"
|
|
|
|
|
"\${HOME}/.cargo/bin"
|
|
|
|
|
"\$/usr/local/bin"
|
|
|
|
|
];
|
|
|
|
|
NIXPKGS_ALLOW_UNFREE = "1";
|
|
|
|
|
SCRIPTDIR = "\${HOME}/.local/share/scriptdeps";
|
|
|
|
|
XDG_CURRENT_DESKTOP = "Hyprland";
|
|
|
|
|
XDG_SESSION_TYPE = "wayland";
|
|
|
|
|
XDG_SESSION_DESKTOP = "Hyprland";
|
|
|
|
|
GDK_BACKEND = "wayland";
|
|
|
|
|
CLUTTER_BACKEND = "wayland";
|
|
|
|
|
SDL_VIDEODRIVER = "x11";
|
|
|
|
|
XCURSOR_SIZE = "24";
|
|
|
|
|
XCURSOR_THEME = "Bibata-Modern-Ice";
|
|
|
|
|
QT_QPA_PLATFORM = "wayland";
|
|
|
|
|
QT_QPA_PLATFORMTHEME = "qt5ct";
|
|
|
|
|
QT_WAYLAND_DISABLE_WINDOWDECORATION = "1";
|
|
|
|
|
QT_AUTO_SCREEN_SCALE_FACTOR = "1";
|
|
|
|
|
MOZ_ENABLE_WAYLAND = "1";
|
|
|
|
|
};
|
2024-01-09 23:50:24 +01:00
|
|
|
|
nix.settings.experimental-features = [ "nix-command" "flakes" ];
|
2023-12-14 00:09:39 +01:00
|
|
|
|
}
|