refactor: clean up

This commit is contained in:
Mohammad Rafiq 2025-03-12 03:49:11 +08:00
parent 45c4e136c4
commit 630b3ce27b
25 changed files with 195 additions and 210 deletions

View file

@ -0,0 +1,6 @@
{
# Use the extlinux boot loader. (NixOS wants to enable GRUB by default)
boot.loader.grub.enable = false;
# Enables the generation of /boot/extlinux/extlinux.conf
boot.loader.generic-extlinux-compatible.enable = true;
}

View file

@ -5,12 +5,11 @@
extraGroups = ["networkmanager" "wheel"];
openssh.authorizedKeys.keys = [
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAILv8HqazE294YdyGaXK6q2EniDlTpGaUL071kk9+W0GJ rafiq@nemesis"
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAICbZfOYt6zydLyO4f9JAsxb1i6kHAjYzqa0SOqef6MKM rafiq@orpheus"
];
};
security.sudo = {
wheelNeedsPassword = false;
};
security.sudo.wheelNeedsPassword = false;
# Enable basic fonts for reasonable Unicode coverage
fonts.enableDefaultPackages = true;

View file

@ -1,6 +1,10 @@
{ pkgs, config, ... }: {
{
pkgs,
config,
...
}: {
fonts.packages = with pkgs; [
nerd-fonts.terminess-ttf
nerd-fonts.terminess-ttf
];
stylix.fonts = {
serif = config.stylix.fonts.monospace;

View file

@ -1,5 +1,5 @@
{ pkgs, ... }: {
services.xserver.videoDrivers = [ "nvidia" ];
{pkgs, ...}: {
services.xserver.videoDrivers = ["nvidia"];
hardware.graphics = {
enable = true;
extraPackages = with pkgs; [

View file

@ -6,17 +6,15 @@
imports = [
./programs/tailscale.nix
];
networking = {
# Enable networkManager
# TODO: Look into the networkManager options.
networkmanager.enable = true;
# Configures a simple stateful firewall.
# By default, it doesn't allow any incoming connections.
firewall = {
enable = true;
allowedTCPPorts = [
enable = true;
allowedTCPPorts = [
22 # SSH
];
allowedUDPPorts = [];
@ -26,17 +24,16 @@
# Add binary caches to avoid having to compile them
nix.settings = {
substituters = [
"https://hyprland.cachix.org"
"https://cuda-maintainers.cachix.org"
"https://nix-community.cachix.org"
"https://hyprland.cachix.org"
"https://cuda-maintainers.cachix.org"
"https://nix-community.cachix.org"
];
trusted-public-keys = [
"hyprland.cachix.org-1:a7pgxzMz7+chwVL3/pzj6jIBMioiJM7ypFP8PwtkuGc="
"hyprland.cachix.org-1:a7pgxzMz7+chwVL3/pzj6jIBMioiJM7ypFP8PwtkuGc="
"cuda-maintainers.cachix.org-1:0dq3bujKpuEPMCX6U4WylrUDZ9JyUG0VpVZa7CNfq5E="
"nix-community.cachix.org-1:mB9FSh9qf2dCimDSUo8Zy7bkq5CX+/rkCWyvRCYg3Fs="
];
};
# TODO: look into openssh and tailscale settings.
services.openssh.enable = true;
}

View file

@ -1,4 +1,8 @@
{ inputs, pkgs, ... }: {
{
inputs,
pkgs,
...
}: {
programs.uwsm = {
enable = false;
};

View file

@ -1,5 +1,5 @@
{ inputs, ... }: {
imports = [
{inputs, ...}: {
imports = [
inputs.stylix.nixosModules.stylix
./themes/catppuccin.nix
./fonts/terminess.nix

View file

@ -1,3 +1,3 @@
{ pkgs, ... }: {
{pkgs, ...}: {
stylix.base16Scheme = "${pkgs.base16-schemes}/share/themes/catppuccin-mocha.yaml";
}