refactor base system

This commit is contained in:
2023-07-24 13:47:01 +02:00
parent 20fd2b839c
commit c03c8ab0c7
9 changed files with 56 additions and 41 deletions

View File

@@ -1,10 +1,6 @@
{ config, pkgs, ... }:
{
imports =
[
./hardware-configuration.nix
];
nix = {
package = pkgs.nixFlakes;

View File

@@ -14,13 +14,19 @@
modules = [
home-manager.nixosModules.home-manager
./configuration.nix
./system/boot.nix
./system/i18n.nix
./system/network.nix
./system/sound.nix
./system/xserver.nix
./system/virtualisation.nix
./system/packages.nix
./hw/lenovo-thinkpad-e14.nix
./system/base.nix
./users/demo.nix
./users/master.nix
];
};
testos = nixpkgs.lib.nixosSystem {
system = "x86_64-linux";
modules = [
home-manager.nixosModules.home-manager
./configuration.nix
./hw/lenovo-thinkpad-e14.nix
./system/base.nix
./users/demo.nix
./users/master.nix
];

12
os/system/base.nix Normal file
View File

@@ -0,0 +1,12 @@
{ pkgs, ... }: {
imports = [
./boot.nix
./security.nix
./i18n.nix
./network.nix
./sound.nix
./xserver.nix
./virtualisation.nix
./packages.nix
];
}

View File

@@ -26,8 +26,6 @@
gcc
unzip
wget
plasma5Packages.bismuth
kdeconnect
firefox
thunderbird
remmina

4
os/system/security.nix Normal file
View File

@@ -0,0 +1,4 @@
{ pkgs, ... }: {
security.polkit.enable = true;
security.rtkit.enable = true;
}

View File

@@ -1,7 +1,6 @@
{ pkgs, ... }: {
sound.enable = true;
hardware.pulseaudio.enable = false;
security.rtkit.enable = true;
services.pipewire = {
enable = true;
alsa.enable = true;

View File

@@ -13,6 +13,8 @@
home.username = "master";
home.homeDirectory = "/home/master";
home.packages = with pkgs; [
plasma5Packages.bismuth
kdeconnect
nerdfonts
tmux
btop
@@ -29,32 +31,30 @@
obsidian
];
programs.home-manager.enable = true;
programs.bash = {
enable = true;
};
programs.direnv = {
enable = true;
nix-direnv.enable = true;
};
programs.starship = {
enable = true;
enableBashIntegration = true;
settings = {
directory.fish_style_pwd_dir_length = 1;
directory.truncation_length = 2;
programs = {
home-manager.enable = true;
bash = {
enable = true;
};
direnv = {
enable = true;
nix-direnv.enable = true;
};
starship = {
enable = true;
enableBashIntegration = true;
settings = {
directory.fish_style_pwd_dir_length = 1;
directory.truncation_length = 2;
};
};
neovim = {
enable = true;
defaultEditor = true;
viAlias = true;
vimAlias = true;
vimdiffAlias = true;
};
};
programs.neovim = {
enable = true;
defaultEditor = true;
viAlias = true;
vimAlias = true;
vimdiffAlias = true;
};
services = {