Release v2.2.0

This commit is contained in:
Hadi
2024-08-19 20:32:10 +02:00
parent caaa500232
commit e6f66110f0
22 changed files with 194 additions and 191 deletions

View File

@@ -0,0 +1,9 @@
{ config, ... }: {
system.autoUpgrade = {
enable = config.var.autoUpgrade;
dates = "04:00";
flake = "${config.var.configDirectory}";
flags = [ "--update-input" "nixpkgs" "--commit-lock-file" ];
allowReboot = false;
};
}

View File

@@ -4,4 +4,6 @@
enable = true;
powerOnBoot = true;
};
services.blueman.enable = true;
}

View File

@@ -0,0 +1,7 @@
{ inputs, ... }: {
home-manager = {
useGlobalPkgs = true;
useUserPackages = true;
extraSpecialArgs = { inherit inputs; };
};
}

View File

@@ -0,0 +1,6 @@
{ pkgs, ... }: {
networking.networkmanager.enable = true;
systemd.services.NetworkManager-wait-online.enable = false;
environment.systemPackages = with pkgs; [ networkmanagerapplet ];
}

22
hosts/modules/nix.nix Normal file
View File

@@ -0,0 +1,22 @@
{ config, ... }: {
nixpkgs.config.allowUnfree = true;
nix = {
extraOptions = ''
warn-dirty = false
'';
settings = {
auto-optimise-store = true;
experimental-features = [ "nix-command" "flakes" ];
substituters = [ "https://hyprland.cachix.org" ];
trusted-public-keys = [
"hyprland.cachix.org-1:a7pgxzMz7+chwVL3/pzj6jIBMioiJM7ypFP8PwtkuGc="
];
};
gc = {
automatic = config.var.autoGarbageCollector;
persistent = true;
dates = "weekly";
options = "--delete-older-than 7d";
};
};
}

View File

@@ -0,0 +1 @@
{ config, ... }: { services.tailscale.enable = config.var.tailscale; }

View File

@@ -1,7 +1,10 @@
{ config, ... }: {
users.users.${config.var.username} = {
isNormalUser = true;
description = "${config.var.username} account";
extraGroups = [ "networkmanager" "wheel" ];
{ config, pkgs, ... }: {
users = {
defaultUserShell = pkgs.zsh;
users.${config.var.username} = {
isNormalUser = true;
description = "${config.var.username} account";
extraGroups = [ "networkmanager" "wheel" ];
};
};
}

42
hosts/modules/utils.nix Normal file
View File

@@ -0,0 +1,42 @@
{ pkgs, config, ... }: {
networking.hostName = config.var.hostname;
services = {
xserver = {
enable = true;
xkb.layout = config.var.keyboardLayout;
xkb.variant = "";
};
gnome.gnome-keyring.enable = true;
};
console.keyMap = config.var.keyboardLayout;
environment.variables = {
XDG_DATA_HOME = "$HOME/.local/share";
PASSWORD_STORE_DIR = "$HOME/.local/share/password-store";
EDITOR = "nvim";
};
services.libinput.enable = true;
programs.dconf.enable = true;
services.dbus.enable = true;
# Faster rebuilding
documentation = {
enable = true;
doc.enable = false;
man.enable = true;
dev.enable = false;
};
environment.systemPackages = with pkgs; [
fd
bc
gcc
git-ignore
xdg-utils
wget
curl
];
}

8
hosts/modules/zsh.nix Normal file
View File

@@ -0,0 +1,8 @@
{
programs.zsh = {
enable = true;
loginShellInit = ''
dbus-update-activation-environment --systemd DISPLAY
'';
};
}