profiles: convert to list same as modules

This commit is contained in:
Timothy DeHerrera 2020-01-04 16:23:15 -07:00
parent ae303b39fd
commit a3dcc4f6bc
No known key found for this signature in database
GPG key ID: 8985725DB5B0C122
2 changed files with 20 additions and 16 deletions

View file

@ -29,14 +29,18 @@
};
nixosModules = let
moduleList = import ./modules;
modulesAttrs = listToAttrs (map (path: {
prep = map (path: {
name = removeSuffix ".nix" (baseNameOf path);
value = import path;
}) moduleList);
});
profilesAttrs = { profiles = import ./profiles; };
moduleList = import ./modules;
modulesAttrs = listToAttrs (prep moduleList);
profilesList = import ./profiles;
profilesAttrs = { profiles = listToAttrs (prep profilesList); };
in modulesAttrs // profilesAttrs;
};
}

View file

@ -1,11 +1,11 @@
{
graphical = import ./graphical;
sway = import ./graphical/sway;
qutebrowser = import ./graphical/qutebrowser;
develop = import ./develop;
zsh = import ./develop/zsh;
tmux = import ./develop/tmux;
kakoune = import ./develop/kakoune;
misc = import ./misc;
games = import ./game;
}
[
./graphical
./graphical/sway
./graphical/qutebrowser
./develop
./develop/zsh
./develop/tmux
./develop/kakoune
./misc
./games
]