about summary refs log tree commit diff stats
path: root/nix/modules/source-options.nix
blob: 4757c89ad396967afb0fa1eff138eaabd58810b6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
{ cfg }:
{ config, lib, name, ... }:
let
  inherit (lib) literalExpression mkOption mkEnableOption types;
in
{
  options = {
    key = mkOption {
      type = types.strMatching "[a-z0-9_-]*";
      default = name;
      description = "URL-safe name for this source.";
    };

    enable = mkEnableOption "Whether to enable this source.";
  };
}