dotfiles.nix/me/default.nix

34 lines
853 B
Nix

{ lib, ... }:
let
userSubmodule = lib.types.submodule {
options = {
name = lib.mkOption {
type = lib.types.str;
description = ''
full name
'';
};
username = lib.mkOption {
type = lib.types.str;
description = ''
user account name
'';
};
email = lib.mkOption { type = lib.types.str; };
sshKeys = lib.mkOption {
type = lib.types.listOf lib.types.str;
description = ''
SSH public keys
'';
};
};
};
in
{
options.me = lib.mkOption { type = userSubmodule; };
# TODO: currently multiplexing this on the work branch
# how can we vary the config username based on the hostname?
# e.g. https://github.com/srid/nixos-flake/discussions/22#discussioncomment-5909499
config.me = import ./config.nix;
}