This commit is contained in:
Varris 2022-08-21 02:18:19 +02:00
parent 1c57d88365
commit d92d59462d
4 changed files with 65 additions and 28 deletions

View File

@ -2,9 +2,7 @@
description = "My personal dotfiles"; description = "My personal dotfiles";
inputs = { inputs = {
nixpkgs = { nixpkgs.url = "nixpkgs/nixpkgs-unstable";
url = "nixpkgs/nixpkgs-unstable";
};
home-manager = { home-manager = {
url = "github:nix-community/home-manager"; url = "github:nix-community/home-manager";
@ -37,10 +35,12 @@
url = "github:bardisty/gruvbox-rofi"; url = "github:bardisty/gruvbox-rofi";
flake = false; flake = false;
}; };
grub2-themes.url = "github:vinceliuice/grub2-themes";
}; };
outputs = { self, nixpkgs, home-manager, nur, ... }@inputs: outputs = { self, nixpkgs, home-manager, nur, grub2-themes, ... }@inputs:
let let
username = "manuel"; username = "manuel";
hostname = "terra"; hostname = "terra";
@ -55,21 +55,15 @@
}; };
overlays = [ self.overlays.default nur.overlay ]; overlays = [ self.overlays.default nur.overlay ];
}; };
in in
{ {
overlays.default = overlays.default =
(final: prev: rec { (final: prev: rec {
nerdfonts = prev.nerdfonts.override { nerdfonts = prev.nerdfonts.override {
fonts = [ fonts = [
"JetBrainsMono" "JetBrainsMono"
]; ];
}; };
discord = prev.discord.override {
# withOpenASAR = true;
};
}); });
nixosConfigurations.${hostname} = nixpkgs.lib.nixosSystem nixosConfigurations.${hostname} = nixpkgs.lib.nixosSystem
@ -90,6 +84,7 @@
}; };
}; };
} }
grub2-themes.nixosModule
]; ];
}; };
}; };

View File

@ -2,7 +2,7 @@
# your system. Help is available in the configuration.nix(5) man page # your system. Help is available in the configuration.nix(5) man page
# and in the NixOS manual (accessible by running nixos-help). # and in the NixOS manual (accessible by running nixos-help).
{ config, pkgs, ... }: { config, pkgs, lib, ... }:
{ {
imports = imports =
@ -11,22 +11,42 @@
./hardware-configuration.nix ./hardware-configuration.nix
]; ];
nixpkgs.config = { nixpkgs.config.allowUnfree = true;
allowUnfree = true;
boot = {
consoleLogLevel = 3;
kernelParams = [
"quiet"
"udev.log_level=3"
"amdgpu.ppfeaturemask=0xffffffff"
];
loader = {
efi = {
canTouchEfiVariables = true;
efiSysMountPoint = "/boot/efi";
};
grub = {
enable = true;
useOSProber = true;
efiSupport = true;
device = "nodev";
};
grub2-theme = {
enable = true;
theme = "vimix";
screen = "2k";
};
};
initrd.availableKernelModules = [ "amdgpu" ];
kernelPackages = pkgs.linuxPackages_latest;
kernelModules = [ "i2c-dev" "i2c-piix4" ];
}; };
# Use the systemd-boot EFI boot loader.
boot.loader.systemd-boot = {
enable = true;
configurationLimit = 10;
};
boot.loader.efi.canTouchEfiVariables = true;
boot.initrd.availableKernelModules = [ "amdgpu" ];
boot.kernelPackages = pkgs.linuxPackages_latest;
boot.kernelModules = [ "i2c-dev" "i2c-piix4" ];
networking.hostName = "terra"; # Define your hostname. networking.hostName = "terra"; # Define your hostname.
# Set your time zone. # Set your time zone.
@ -72,6 +92,16 @@
pulse.enable = true; pulse.enable = true;
}; };
services.locate = {
enable = true;
locate = pkgs.plocate;
localuser = null;
prunePaths = lib.mkOptionDefault [
"/mnt/btrfs"
];
interval = "hourly";
};
security.doas.enable = true; security.doas.enable = true;
security.sudo.enable = false; security.sudo.enable = false;
@ -88,7 +118,7 @@
# Define a user account. Don't forget to set a password with passwd. # Define a user account. Don't forget to set a password with passwd.
users.users.manuel = { users.users.manuel = {
isNormalUser = true; isNormalUser = true;
extraGroups = [ "users" "wheel" "audio" "video" "games" "input" "geoclue" ]; # Enable sudo for the user. extraGroups = [ "users" "wheel" "audio" "video" "games" "input" "geoclue" ];
shell = pkgs.fish; shell = pkgs.fish;
}; };
@ -147,6 +177,17 @@
nssmdns = true; nssmdns = true;
}; };
services.greetd = {
enable = true;
settings = {
default_session = {
vt = 1;
command = "${pkgs.greetd.tuigreet}/bin/tuigreet --cmd sway";
};
user = "manuel";
};
};
nix.gc = { nix.gc = {
persistent = true; persistent = true;
automatic = true; automatic = true;

View File

@ -21,7 +21,7 @@
options = [ "subvol=@nixos-root" "compress-force=zstd" ]; options = [ "subvol=@nixos-root" "compress-force=zstd" ];
}; };
fileSystems."/boot" = fileSystems."/boot/efi" =
{ {
device = "/dev/disk/by-uuid/1AC9-E1AD"; device = "/dev/disk/by-uuid/1AC9-E1AD";
fsType = "vfat"; fsType = "vfat";

View File

@ -209,6 +209,7 @@ in
}; };
colors = { colors = {
alpha = "0.95";
background = "282828"; background = "282828";
foreground = "ebdbb2"; foreground = "ebdbb2";
regular0 = "282828"; regular0 = "282828";