fix: remove double-lambda in mkHome (was rejecting 'sets' argument)
This commit is contained in:
@@ -1,11 +1,5 @@
|
|||||||
# lib/default.nix — Entry point for m3ta-home library functions.
|
# lib/default.nix — Entry point for m3ta-home library functions.
|
||||||
#
|
#
|
||||||
# Provides:
|
# Called by flake.nix: import ./lib { inherit inputs; }
|
||||||
# mkHome — compose a complete HM config from user + identity + context + sets
|
# Re-exports mkHome and future library functions.
|
||||||
# mkDevShell — create project-level dev shells from language sets
|
{inputs}: import ./mkHome.nix {inherit inputs;}
|
||||||
{inputs}: {
|
|
||||||
mkHome = import ./mkHome.nix {inherit inputs;};
|
|
||||||
|
|
||||||
# TODO: mkDevShell for project-level flake devShells
|
|
||||||
# mkDevShell = import ./mkDevShell.nix { inherit inputs; };
|
|
||||||
}
|
|
||||||
|
|||||||
@@ -19,31 +19,8 @@
|
|||||||
# m3ta.home.sets.coding.languages.python.extra = true;
|
# m3ta.home.sets.coding.languages.python.extra = true;
|
||||||
# wayland.windowManager.hyprland.settings.monitor = [ ... ];
|
# wayland.windowManager.hyprland.settings.monitor = [ ... ];
|
||||||
#
|
#
|
||||||
{inputs}:
|
{inputs}: let
|
||||||
{lib ? inputs.nixpkgs.lib}:
|
lib = inputs.nixpkgs.lib;
|
||||||
let
|
|
||||||
# --- Module path helpers ---
|
|
||||||
profilePath = ../profiles;
|
|
||||||
userPath = ../users;
|
|
||||||
|
|
||||||
# Always loaded — CLI tools, shell, secrets, overlays
|
|
||||||
baseModule = "${profilePath}/base";
|
|
||||||
|
|
||||||
# Context modules — mutually exclusive (desktop or server)
|
|
||||||
contextModuleMap = {
|
|
||||||
desktop = "${profilePath}/contexts/desktop";
|
|
||||||
server = "${profilePath}/contexts/server";
|
|
||||||
};
|
|
||||||
|
|
||||||
# Feature sets — freely combinable, some have context guards
|
|
||||||
setModuleMap = {
|
|
||||||
coding = "${profilePath}/sets/coding";
|
|
||||||
gaming = "${profilePath}/sets/gaming";
|
|
||||||
media = "${profilePath}/sets/media";
|
|
||||||
};
|
|
||||||
|
|
||||||
# Sets that require desktop context
|
|
||||||
desktopOnlySets = ["gaming" "media"];
|
|
||||||
in {
|
in {
|
||||||
mkHome = {
|
mkHome = {
|
||||||
user ? "m3tam3re",
|
user ? "m3tam3re",
|
||||||
@@ -51,6 +28,29 @@ in {
|
|||||||
context ? null,
|
context ? null,
|
||||||
sets ? [],
|
sets ? [],
|
||||||
}: let
|
}: let
|
||||||
|
# --- Module path helpers ---
|
||||||
|
profilePath = ../profiles;
|
||||||
|
userPath = ../users;
|
||||||
|
|
||||||
|
# Always loaded — CLI tools, shell, secrets, overlays
|
||||||
|
baseModule = "${profilePath}/base";
|
||||||
|
|
||||||
|
# Context modules — mutually exclusive (desktop or server)
|
||||||
|
contextModuleMap = {
|
||||||
|
desktop = "${profilePath}/contexts/desktop";
|
||||||
|
server = "${profilePath}/contexts/server";
|
||||||
|
};
|
||||||
|
|
||||||
|
# Feature sets — freely combinable, some have context guards
|
||||||
|
setModuleMap = {
|
||||||
|
coding = "${profilePath}/sets/coding";
|
||||||
|
gaming = "${profilePath}/sets/gaming";
|
||||||
|
media = "${profilePath}/sets/media";
|
||||||
|
};
|
||||||
|
|
||||||
|
# Sets that require desktop context
|
||||||
|
desktopOnlySets = ["gaming" "media"];
|
||||||
|
|
||||||
# User preferences — always loaded (shell style, editor config, etc.)
|
# User preferences — always loaded (shell style, editor config, etc.)
|
||||||
preferencesPath = "${userPath}/${user}/preferences";
|
preferencesPath = "${userPath}/${user}/preferences";
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user