[HomeManager] Use git repo instead of nix channel

Prepare for flakes
This commit is contained in:
Antoine Viallon 2022-06-09 01:16:07 +02:00
parent 9cbbc8ec6f
commit 522d19bf5b
Signed by: aviallon
GPG key ID: 186FC35EDEB25716

View file

@ -1,16 +1,28 @@
{config, pkgs, lib, ...}:
{config, pkgs, lib, utils, ...}:
with lib;
let
cfg = config.aviallon.home-manager;
usersCfg = config.users;
usersCfg = attrByPath [ "users" ] { users = {}; groups = {}; } config;
defaultUsers = attrNames (filterAttrs (name: value: value.isNormalUser) usersCfg.users);
hmUserCfg = u: config.home-manager.users.${u};
userCfg = u: config.users.users.${u};
getUserCfgPath = u: "${(userCfg u).home}/.config/nixpkgs/home.nix";
homeManager = fetchGit {
url = "https://github.com/nix-community/home-manager";
ref = "release-22.05";
};
homeManagerNixos = import "${homeManager}/nixos" {
inherit config;
inherit pkgs;
inherit lib;
inherit utils;
};
in
{
imports = [
<home-manager/nixos>
homeManagerNixos
];
options.aviallon.home-manager = {