switch to home-manager module

This commit is contained in:
tx0 2025-03-12 21:24:24 +05:00
parent fc4f825cc3
commit f0529eed85
5 changed files with 13 additions and 62 deletions

View file

@ -26,17 +26,16 @@
./hosts/common
./hosts/earth
# universe
];
};
homeConfigurations.tx0 = inputs.home-manager.lib.homeManagerConfiguration {
pkgs = import inputs.nixpkgs {
inherit system;
};
inputs.home-manager.nixosModules.home-manager
{
home-manager = {
useGlobalPkgs = true;
useUserPackages = true;
backupFileExtension = "hm-old";
users.tx0 = import ./home;
extraSpecialArgs = {inherit system inputs u;};
modules = [
./home
./universe.nix
};
}
];
};
};

View file

@ -1,14 +1,10 @@
{
pkgs,
config,
...
}: {
{config, ...}: {
home = {
username = "tx0";
homeDirectory = "/home/tx0";
stateVersion = "24.11";
sessionVariables = {
EDITOR = "${config.home.homeDirectory}/.nix-profile/bin/nvim";
EDITOR = "nvim";
HYPRSHOT_DIR = "${config.home.homeDirectory}/Pictures/Screenshots/";
FLAKE = "${config.home.homeDirectory}/universe/";
NIXOS_OZONE_WL = 1;

View file

@ -1,35 +0,0 @@
{
inputs,
config,
pkgs,
...
}: {
nix = {
package = pkgs.nix;
nixPath = ["nixpkgs=${inputs.nixpkgs}"];
settings = {
extra-substituters = [
"https://cache.garnix.io"
"https://nix-community.cachix.org"
"https://cache.nixos.org/"
"https://hyprland.cachix.org"
];
extra-trusted-public-keys = [
"cache.garnix.io:CTFPyKSLcx5RMJKfLo5EEPUObbA78b0YQ2DTCJXqr9g="
"nix-community.cachix.org-1:mB9FSh9qf2dCimDSUo8Zy7bkq5CX+/rkCWyvRCYg3Fs="
"cache.nixos.org-1:6NCHdD59X431o0gWypbMrAURkbJ16ZPMQFGspcDShjY="
"hyprland.cachix.org-1:a7pgxzMz7+chwVL3/pzj6jIBMioiJM7ypFP8PwtkuGc="
];
builders-use-substitutes = true;
auto-optimise-store = true;
trusted-users = [
config.home.username
"root"
"@wheel"
];
warn-dirty = false;
extra-experimental-features = ["nix-command" "flakes"];
accept-flake-config = true;
};
};
}

View file

@ -1,9 +0,0 @@
{...}: {
nixpkgs.config = {
allowUnfree = true;
allowBroken = true;
allowAliases = true;
allowInsecure = true;
allowUnfreePredicate = _: true;
};
}

View file

@ -7,7 +7,7 @@
theme.stylix = {
base16Scheme = "${pkgs.base16-schemes}/share/themes/gruvbox-material-dark-medium.yaml";
# base16Scheme = "${pkgs.base16-schemes}/share/themes/catppuccin-mocha.yaml";
wallpapers = ./wallpaper.png;
wallpapers = ../wallpaper.png;
useLutgen = true;
};
};