mirror of
https://github.com/foo-dogsquared/nixos-config.git
synced 2025-02-07 12:19:07 +00:00
flake-parts/setups: add configName
option
This commit is contained in:
parent
e22a197e37
commit
f5c9f0f876
@ -135,7 +135,7 @@ let
|
||||
|
||||
config = {
|
||||
modules = [
|
||||
../../../configs/home-manager/${name}
|
||||
../../../configs/home-manager/${config.configName}
|
||||
|
||||
(
|
||||
let
|
||||
|
@ -302,7 +302,7 @@ let
|
||||
config.modules = [
|
||||
# Bring in the required modules.
|
||||
inputs.${config.homeManagerBranch}.nixosModules.home-manager
|
||||
../../../configs/nixos/${name}
|
||||
../../../configs/nixos/${config.configName}
|
||||
|
||||
# Mapping the declarative home-manager users (if it has one) into NixOS
|
||||
# users.
|
||||
@ -403,7 +403,7 @@ let
|
||||
programs.nixvim = { ... }: {
|
||||
enable = lib.mkDefault true;
|
||||
imports =
|
||||
partsConfig.setups.nixvim.${config.nixvim.instance}.modules
|
||||
partsConfig.setups.nixvim.configs.${config.nixvim.instance}.modules
|
||||
++ partsConfig.setups.nixvim.sharedModules
|
||||
++ setupConfig.nixvim.additionalModules;
|
||||
};
|
||||
|
@ -69,7 +69,7 @@ let
|
||||
|
||||
config = {
|
||||
modules = [
|
||||
../../../configs/nixvim/${name}
|
||||
../../../configs/nixvim/${config.configName}
|
||||
];
|
||||
};
|
||||
};
|
||||
|
@ -1,4 +1,4 @@
|
||||
{ lib, systems, ... }: {
|
||||
{ lib, name, systems, ... }: {
|
||||
options = {
|
||||
systems = lib.mkOption {
|
||||
type = with lib.types; listOf str;
|
||||
@ -18,5 +18,15 @@
|
||||
A list of NixOS modules specific for that host.
|
||||
'';
|
||||
};
|
||||
|
||||
configName = lib.mkOption {
|
||||
type = lib.types.nonEmptyStr;
|
||||
default = name;
|
||||
example = "plover";
|
||||
description = ''
|
||||
The name of the configuration to be used. Useful for creating variants
|
||||
of the same declarative environment.
|
||||
'';
|
||||
};
|
||||
};
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user