added basis of saturn config

This commit is contained in:
Bit Borealis 2023-03-26 19:36:47 +00:00
parent 010bb95d65
commit e20f30d35a
Signed by: theotheroracle
GPG Key ID: 2D816A2DCA6E5649
6 changed files with 40 additions and 11 deletions

View File

@ -9,7 +9,8 @@ in {
imports = [
home-manager
./hosts/vulkan
./modules/machine-info.nix
./modules
./saturn/system.nix
];
# nix options

7
modules/default.nix Normal file
View File

@ -0,0 +1,7 @@
{ ... }:
{
imports = [
./saturnConfig.nix
./machineInfo.nix
];
}

23
modules/saturnConfig.nix Normal file
View File

@ -0,0 +1,23 @@
{ lib, ... }: with lib;
{
options.saturn = {
user = mkOption {
type = types.str;
default = "saturn";
description = mdDoc "The name of the user of the system.";
};
hostname = mkOption {
type = types.strMatching
"[a-zA-Z0-9]([a-zA-Z0-9\-]{0,61}[a-zA-Z0-9])?";
default = "saturnOS-device";
description = mdDoc "The network hostname of the system, which must only contain letters,
numbers, and dashes, and cannot start or end with a dash.";
};
prettyHostname = mkOption {
type = types.str;
default = "🪐 saturnOS";
description = mdDoc "The pretty hostname is used for things like bluetooth pairing,
device sharing, and is fully unicode.";
};
};
}

View File

@ -1,2 +0,0 @@
{
}

View File

@ -1,10 +1,10 @@
## not real code yet
{ config, ... }:
{
user = "hive";
hostname = "vulkan";
prett_hostname = "🌋 vulkan";
packages = {
}
user_packages = {
}
saturn.user = "hive";
saturn.hostname = "vulkan";
saturn.prettyHostname = "🌋 vulkan";
# packages = {
# }
# userPackages = {
# }
}