<commit_before>{ config, lib, pkgs, ... }:

let
  inherit (lib) mkEnableOption mkIf mkOption singleton types;
  inherit (pkgs) bird;
  cfg = config.services.bird;

  configFile = pkgs.writeText "bird.conf" ''
    ${cfg.config}
  '';
in

{

  ###### interface

  options = {

    services.bird = {

      enable = mkEnableOption "BIRD Internet Routing Daemon";

      config = mkOption {
        type = types.string;
        description = ''
          BIRD Internet Routing Daemon configuration file.
          <link xlink:href='http://bird.network.cz/'/>
        '';
      };

      user = mkOption {
        type = types.string;
        default = "ircd";
        description = ''
          BIRD Internet Routing Daemon user.
        '';
      };

      group = mkOption {
        type = types.string;
        default = "ircd";
        description = ''
          BIRD Internet Routing Daemon group.
        '';
      };

    };

  };


  ###### implementation
<commit_msg>bird module: run as user/group `bird`, not `ircd`<commit_after>{ config, lib, pkgs, ... }:

let
  inherit (lib) mkEnableOption mkIf mkOption singleton types;
  inherit (pkgs) bird;
  cfg = config.services.bird;

  configFile = pkgs.writeText "bird.conf" ''
    ${cfg.config}
  '';
in

{

  ###### interface

  options = {

    services.bird = {

      enable = mkEnableOption "BIRD Internet Routing Daemon";

      config = mkOption {
        type = types.string;
        description = ''
          BIRD Internet Routing Daemon configuration file.
          <link xlink:href='http://bird.network.cz/'/>
        '';
      };

      user = mkOption {
        type = types.string;
        default = "bird";
        description = ''
          BIRD Internet Routing Daemon user.
        '';
      };

      group = mkOption {
        type = types.string;
        default = "bird";
        description = ''
          BIRD Internet Routing Daemon group.
        '';
      };

    };

  };


  ###### implementation

{'fraction_non_alphanumeric': 0.1297979797979798, 'fraction_numerical': 0.0, 'mean_word_length': 1.8503597122302158, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7648232', 'n_tokens_mistral': 604, 'n_tokens_neox': 573, 'n_words': 145}