Reuse flake `homeConfigurations` in nixos home manager setup

I would like to reuse the Home Manager configuration i have as homeConfigurations flake output with home-manager.lib.homeManagerConfiguration in nixOS Home Manager setup with Home Manager nixOS module (home-manager.nixosModules.home-manager). Is it somehow possible to achieve this?

yes :slight_smile: the easiest path to that is including your very same home-manager module on both configurations.

lib.homeManagerConfiguration { modules = [ ./your-hm-module.nix ]; }

# and inside a nixos config:

home-manager.users.your-user.imports = [ ./your-hm-module.nix ];

something like that, haven’t tried the exact code, but that is the principle to follow.