How to recursively import nix files (eg program modules) for Home Manager using lib.fileset?

I’m trying to import all my home manager program module configs in nixpkgs/pkgs-home-manager/modules-macos-active and its subdirectories without a default.nix (and one per subdirectory if that’s the default behaviour), as follows:


imports = [ ./pkgs-home-manager/modules-macos-active ./options-home-manager.nix ];

I’ve seen umport, which looks great, but I have no idea how to use it (as I’m noob and can’t find its package) and I’d prefer to use lib.fileset because it’s part of Nix and more supported.

Are there any basic examples of how to use lib.fileset for use cases like mine and is it possible, or would I be better to use umport, and if so, how do I use it?