rearrange for modularity

This commit is contained in:
Polen 2024-10-28 11:17:43 -04:00
parent 48b18aa671
commit 71ec2a349f
8 changed files with 20 additions and 19 deletions

Binary file not shown.

After

Width:  |  Height:  |  Size: 858 KiB

View file

@ -0,0 +1,150 @@
# 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).
{ config, pkgs, ... }:
{
imports = [ # Include the results of the hardware scan.
./hardware-configuration.nix
];
hardware.bluetooth = {
enable = true;
powerOnBoot = true;
};
services.blueman.enable = true;
virtualisation.waydroid.enable = true;
# Bootloader.
boot.loader.systemd-boot.enable = true;
boot.loader.efi.canTouchEfiVariables = true;
networking.hostName = "nixos"; # Define your hostname.
# networking.wireless.enable = true; # Enables wireless support via wpa_supplicant.
nix.settings.experimental-features = [ "nix-command" "flakes" ];
# 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;
# Set your time zone.
time.timeZone = "America/Toronto";
# Select internationalisation properties.
i18n.defaultLocale = "en_CA.UTF-8";
# Configure keymap in X11
services.xserver = {
enable = true;
xkb.layout = "us";
xkb.variant = "";
};
services.displayManager.sddm = {
enable = true;
theme = "${import ./sddm-theme.nix { inherit pkgs; }}";
};
# Define a user account. Don't forget to set a password with passwd.
users.users.polen = {
isNormalUser = true;
description = "polen";
extraGroups = [ "networkmanager" "wheel" ];
shell = pkgs.zsh;
};
#users.defaultUserShell = pkgs.zsh
# Allow unfree packages
nixpkgs.config.allowUnfree = true;
# List packages installed in system profile. To search, run:
# $ nix search wget
environment.systemPackages = with pkgs; [
alacritty
neovim
wget
htop-vim
ranger
git
home-manager
waybar
mako
swww
wdisplays
libnotify
bemenu
pavucontrol
networkmanagerapplet
wl-clipboard
libsForQt5.qt5.qtquickcontrols2
libsForQt5.qt5.qtgraphicaleffects
];
programs.zsh.enable = true;
programs.hyprland = {
enable = true;
xwayland.enable = true;
};
services.gvfs.enable = true;
# to make pass work
services.passSecretService.enable = true;
services.pcscd.enable = true;
programs.gnupg.agent = {
enable = true;
pinentryPackage = pkgs.pinentry-gnome3;
enableSSHSupport = true;
};
programs.seahorse.enable = true;
xdg.portal.enable = true;
xdg.portal.extraPortals = [ pkgs.xdg-desktop-portal-gtk ];
environment.sessionVariables = {
NIXOS_OZONE_WL = "1";
QT_SCALE_FACTOR_ROUNDING_POLICY = "RoundPreferFloor";
};
# List services that you want to enable:
security.rtkit.enable = true;
services.pipewire = {
enable = true;
alsa.enable = true;
pulse.enable = true;
jack.enable = true;
};
services.printing.enable = true;
services.avahi = {
enable = true;
nssmdns4 = true;
openFirewall = true;
};
# Enable the OpenSSH daemon.
# services.openssh.enable = true;
# Open ports in the firewall.
# networking.firewall.allowedTCPPorts = [ ... ];
# networking.firewall.allowedUDPPorts = [ ... ];
# Or disable the firewall altogether.
# networking.firewall.enable = false;
# This value determines the NixOS release from which the default
# settings for stateful data, like file locations and database versions
# on your system were taken. Its perfectly fine and recommended to leave
# this value at the release version of the first install of this system.
# Before changing this value read the documentation for this option
# (e.g. man configuration.nix or on https://nixos.org/nixos/options.html).
system.stateVersion = "23.11"; # Did you read the comment?
}

View file

@ -0,0 +1,42 @@
# Do not modify this file! It was generated by nixos-generate-config
# and may be overwritten by future invocations. Please make changes
# to /etc/nixos/configuration.nix instead.
{ config, lib, pkgs, modulesPath, ... }:
{
imports =
[ (modulesPath + "/installer/scan/not-detected.nix")
];
boot.initrd.availableKernelModules = [ "xhci_pci" "nvme" "usb_storage" "sd_mod" "rtsx_pci_sdmmc" ];
boot.initrd.kernelModules = [ ];
boot.kernelModules = [ "kvm-intel" ];
boot.extraModulePackages = [ ];
fileSystems."/" =
{ device = "/dev/disk/by-uuid/6faa62c9-8566-4ed7-b372-355e04ac4ca6";
fsType = "ext4";
};
fileSystems."/boot" =
{ device = "/dev/disk/by-uuid/A769-2F96";
fsType = "vfat";
};
fileSystems."/home" =
{ device = "/dev/disk/by-uuid/8b28694c-3401-4545-9974-521674baa450";
fsType = "ext4";
};
swapDevices = [ ];
# Enables DHCP on each ethernet and wireless interface. In case of scripted networking
# (the default) this is the recommended approach. When using systemd-networkd it's
# still possible to use this option, but it's recommended to use it in conjunction
# with explicit per-interface declarations with `networking.interfaces.<interface>.useDHCP`.
networking.useDHCP = lib.mkDefault true;
# networking.interfaces.wlp2s0.useDHCP = lib.mkDefault true;
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
}

View file

@ -0,0 +1,20 @@
{ pkgs }:
let
image = ./assets/a_forest_of_trees_with_fog.jpg;
in
pkgs.stdenv.mkDerivation {
name = "sddm-theme";
src = pkgs.fetchFromGitHub {
owner = "MarianArlt";
repo = "sddm-sugar-dark";
rev = "ceb2c455663429be03ba62d9f898c571650ef7fe";
sha256 = "0153z1kylbhc9d12nxy9vpn0spxgrhgy36wy37pk6ysq7akaqlvy";
};
installPhase = ''
mkdir -p $out
cp -R ./* $out/
cd $out/
rm Background.jpg
cp -r ${image} $out/Background.jpg
'';
}