nixos-configs/common/default.nix

124 lines
2.2 KiB
Nix
Raw Normal View History

{ config
, home-manager
, lib
, nixpkgs
, nixpkgs-wayland
2023-11-22 14:36:42 -05:00
, nix-index-database
, nh
, nur
, nix-melt
, nurl
, coc-stylelintplus
, pkgs
, ...
}: {
2023-10-15 14:43:23 -04:00
imports = [
./cachix.nix
./overlays
./device-vars.nix
2023-10-15 14:43:23 -04:00
home-manager.nixosModules.default
2023-11-19 15:32:28 -05:00
nh.nixosModules.default
2023-10-15 16:05:28 -04:00
./modules/programs.nix
2023-10-15 16:47:26 -04:00
./modules/locale.nix
2023-10-15 14:43:23 -04:00
];
nixpkgs.config.allowUnfree = true;
nix = {
# Edit nix.conf
settings = {
experimental-features = [ "nix-command" "flakes" ];
keep-outputs = true;
keep-derivations = true;
auto-optimise-store = true;
warn-dirty = false;
};
# Minimize dowloads of indirect nixpkgs flakes
registry.nixpkgs = {
flake = nixpkgs;
exact = false;
};
};
nixpkgs.overlays = [
nixpkgs-wayland.overlay
coc-stylelintplus.overlay
];
2023-11-19 15:32:28 -05:00
nh = {
enable = true;
# weekly cleanup
clean = {
enable = true;
extraArgs = "--keep-since 30d";
};
2023-11-19 15:32:28 -05:00
};
environment.variables.FLAKE = "/home/matt/.nix";
services.xserver = {
layout = "ca";
xkbVariant = "multix";
};
2023-10-15 14:30:30 -04:00
home-manager.users = let
default = {
imports = [
2023-10-15 14:43:23 -04:00
nur.hmModules.nur
2023-11-22 14:36:42 -05:00
nix-index-database.hmModules.nix-index
{
programs = {
nix-index-database.comma.enable = true;
nix-index = {
enable = true;
enableBashIntegration = true;
};
};
}
./home/bash
./home/git.nix
./home/neovim
./home/tmux.nix
./device-vars.nix
({ osConfig, ... }: {
services.device-vars = osConfig.services.device-vars;
})
2023-10-15 14:30:30 -04:00
];
home.packages = [
2023-11-19 15:32:28 -05:00
nix-melt.packages.x86_64-linux.default
nurl.packages.x86_64-linux.default
] ++
(with config.nur.repos.rycee; [
mozilla-addons-to-nix
]) ++
(with pkgs.nodePackages; [
undollar
]) ++
(with pkgs; [
2023-10-15 16:47:26 -04:00
dracula-theme
neofetch
progress
wget
tree
mosh
rsync
killall
imagemagick
usbutils
]);
2023-10-15 14:30:30 -04:00
home.stateVersion = lib.mkDefault "23.05";
};
in {
root = default;
matt = default;
};
2023-10-15 14:43:23 -04:00
}