---
Function {
 argument: None,
 arguments: FunctionArguments {
  arguments: [
   FunctionArgument {
    identifier: "pkgs",
    default: None,
   },
   FunctionArgument {
    identifier: "lib",
    default: None,
   },
   FunctionArgument {
    identifier: "config",
    default: None,
   },
  ],
  ellipsis: true,
 },
 definition: With {
  expression: Variable {
   identifier: "lib",
   position: (3, 6),
  },
  target: LetIn {
   bindings: [
    KeyValue(
     AttributePath {
      attributes: [
       Raw {
        content: "cfg",
        position: (6, 3),
       },
      ],
     },
     PropertyAccess {
      expression: Variable {
       identifier: "config",
       position: (6, 9),
      },
      attribute_path: AttributePath {
       attributes: [
        Raw {
         content: "services",
         position: (6, 16),
        },
        Raw {
         content: "weechat",
         position: (6, 25),
        },
       ],
      },
      default: None,
     },
    ),
   ],
   target: Map {
    bindings: [
     KeyValue(
      AttributePath {
       attributes: [
        Raw {
         content: "options",
         position: (10, 3),
        },
        Raw {
         content: "services",
         position: (10, 11),
        },
        Raw {
         content: "weechat",
         position: (10, 20),
        },
       ],
      },
      Map {
       bindings: [
        KeyValue(
         AttributePath {
          attributes: [
           Raw {
            content: "enable",
            position: (11, 5),
           },
          ],
         },
         FunctionApplication {
          function: Variable {
           identifier: "mkEnableOption",
           position: (11, 14),
          },
          arguments: [
           String {
            parts: [
             Raw {
              content: "weechat",
              position: (11, 30),
             },
            ],
           },
          ],
         },
        ),
        KeyValue(
         AttributePath {
          attributes: [
           Raw {
            content: "root",
            position: (12, 5),
           },
          ],
         },
         FunctionApplication {
          function: Variable {
           identifier: "mkOption",
           position: (12, 12),
          },
          arguments: [
           Map {
            bindings: [
             KeyValue(
              AttributePath {
               attributes: [
                Raw {
                 content: "description",
                 position: (13, 7),
                },
               ],
              },
              String {
               parts: [
                Raw {
                 content: "Weechat state directory.",
                 position: (13, 22),
                },
               ],
              },
             ),
             KeyValue(
              AttributePath {
               attributes: [
                Raw {
                 content: "type",
                 position: (14, 7),
                },
               ],
              },
              PropertyAccess {
               expression: Variable {
                identifier: "types",
                position: (14, 14),
               },
               attribute_path: AttributePath {
                attributes: [
                 Raw {
                  content: "str",
                  position: (14, 20),
                 },
                ],
               },
               default: None,
              },
             ),
             KeyValue(
              AttributePath {
               attributes: [
                Raw {
                 content: "default",
                 position: (15, 7),
                },
               ],
              },
              String {
               parts: [
                Raw {
                 content: "/var/lib/weechat",
                 position: (15, 18),
                },
               ],
              },
             ),
            ],
            recursive: false,
            position: (12, 21),
           },
          ],
         },
        ),
        KeyValue(
         AttributePath {
          attributes: [
           Raw {
            content: "sessionName",
            position: (17, 5),
           },
          ],
         },
         FunctionApplication {
          function: Variable {
           identifier: "mkOption",
           position: (17, 19),
          },
          arguments: [
           Map {
            bindings: [
             KeyValue(
              AttributePath {
               attributes: [
                Raw {
                 content: "description",
                 position: (18, 7),
                },
               ],
              },
              String {
               parts: [
                Raw {
                 content: "Name of the `screen' session for weechat.",
                 position: (18, 22),
                },
               ],
              },
             ),
             KeyValue(
              AttributePath {
               attributes: [
                Raw {
                 content: "default",
                 position: (19, 7),
                },
               ],
              },
              String {
               parts: [
                Raw {
                 content: "weechat-screen",
                 position: (19, 18),
                },
               ],
              },
             ),
             KeyValue(
              AttributePath {
               attributes: [
                Raw {
                 content: "type",
                 position: (20, 7),
                },
               ],
              },
              PropertyAccess {
               expression: Variable {
                identifier: "types",
                position: (20, 14),
               },
               attribute_path: AttributePath {
                attributes: [
                 Raw {
                  content: "str",
                  position: (20, 20),
                 },
                ],
               },
               default: None,
              },
             ),
            ],
            recursive: false,
            position: (17, 28),
           },
          ],
         },
        ),
        KeyValue(
         AttributePath {
          attributes: [
           Raw {
            content: "binary",
            position: (22, 5),
           },
          ],
         },
         FunctionApplication {
          function: Variable {
           identifier: "mkOption",
           position: (22, 14),
          },
          arguments: [
           Map {
            bindings: [
             KeyValue(
              AttributePath {
               attributes: [
                Raw {
                 content: "type",
                 position: (23, 7),
                },
               ],
              },
              PropertyAccess {
               expression: Variable {
                identifier: "types",
                position: (23, 14),
               },
               attribute_path: AttributePath {
                attributes: [
                 Raw {
                  content: "path",
                  position: (23, 20),
                 },
                ],
               },
               default: None,
              },
             ),
             KeyValue(
              AttributePath {
               attributes: [
                Raw {
                 content: "description",
                 position: (24, 7),
                },
               ],
              },
              String {
               parts: [
                Raw {
                 content: "Binary to execute.",
                 position: (24, 22),
                },
               ],
              },
             ),
             KeyValue(
              AttributePath {
               attributes: [
                Raw {
                 content: "default",
                 position: (25, 7),
                },
               ],
              },
              String {
               parts: [
                Expression {
                 expression: PropertyAccess {
                  expression: Variable {
                   identifier: "pkgs",
                   position: (25, 20),
                  },
                  attribute_path: AttributePath {
                   attributes: [
                    Raw {
                     content: "weechat",
                     position: (25, 25),
                    },
                   ],
                  },
                  default: None,
                 },
                },
                Raw {
                 content: "/bin/weechat",
                 position: (25, 33),
                },
               ],
              },
             ),
             KeyValue(
              AttributePath {
               attributes: [
                Raw {
                 content: "defaultText",
                 position: (26, 7),
                },
               ],
              },
              FunctionApplication {
               function: Variable {
                identifier: "literalExpression",
                position: (26, 21),
               },
               arguments: [
                String {
                 parts: [
                  Raw {
                   content: "\"",
                   position: (26, 41),
                  },
                  Raw {
                   content: "$",
                   position: (26, 42),
                  },
                  Raw {
                   content: "{pkgs.weechat}/bin/weechat\"",
                   position: (26, 45),
                  },
                 ],
                },
               ],
              },
             ),
             KeyValue(
              AttributePath {
               attributes: [
                Raw {
                 content: "example",
                 position: (27, 7),
                },
               ],
              },
              FunctionApplication {
               function: Variable {
                identifier: "literalExpression",
                position: (27, 17),
               },
               arguments: [
                String {
                 parts: [
                  Raw {
                   content: "\"",
                   position: (27, 37),
                  },
                  Raw {
                   content: "$",
                   position: (27, 38),
                  },
                  Raw {
                   content: "{pkgs.weechat}/bin/weechat-headless\"",
                   position: (27, 41),
                  },
                 ],
                },
               ],
              },
             ),
            ],
            recursive: false,
            position: (22, 23),
           },
          ],
         },
        ),
       ],
       recursive: false,
       position: (10, 30),
      },
     ),
     KeyValue(
      AttributePath {
       attributes: [
        Raw {
         content: "config",
         position: (31, 3),
        },
       ],
      },
      FunctionApplication {
       function: Variable {
        identifier: "mkIf",
        position: (31, 12),
       },
       arguments: [
        PropertyAccess {
         expression: Variable {
          identifier: "cfg",
          position: (31, 17),
         },
         attribute_path: AttributePath {
          attributes: [
           Raw {
            content: "enable",
            position: (31, 21),
           },
          ],
         },
         default: None,
        },
        Map {
         bindings: [
          KeyValue(
           AttributePath {
            attributes: [
             Raw {
              content: "users",
              position: (32, 5),
             },
            ],
           },
           Map {
            bindings: [
             KeyValue(
              AttributePath {
               attributes: [
                Raw {
                 content: "groups",
                 position: (33, 7),
                },
                Raw {
                 content: "weechat",
                 position: (33, 14),
                },
               ],
              },
              Map {
               bindings: [],
               recursive: false,
               position: (33, 24),
              },
             ),
             KeyValue(
              AttributePath {
               attributes: [
                Raw {
                 content: "users",
                 position: (34, 7),
                },
                Raw {
                 content: "weechat",
                 position: (34, 13),
                },
               ],
              },
              Map {
               bindings: [
                KeyValue(
                 AttributePath {
                  attributes: [
                   Raw {
                    content: "createHome",
                    position: (35, 9),
                   },
                  ],
                 },
                 Variable {
                  identifier: "true",
                  position: (35, 22),
                 },
                ),
                KeyValue(
                 AttributePath {
                  attributes: [
                   Raw {
                    content: "group",
                    position: (36, 9),
                   },
                  ],
                 },
                 String {
                  parts: [
                   Raw {
                    content: "weechat",
                    position: (36, 18),
                   },
                  ],
                 },
                ),
                KeyValue(
                 AttributePath {
                  attributes: [
                   Raw {
                    content: "home",
                    position: (37, 9),
                   },
                  ],
                 },
                 PropertyAccess {
                  expression: Variable {
                   identifier: "cfg",
                   position: (37, 16),
                  },
                  attribute_path: AttributePath {
                   attributes: [
                    Raw {
                     content: "root",
                     position: (37, 20),
                    },
                   ],
                  },
                  default: None,
                 },
                ),
                KeyValue(
                 AttributePath {
                  attributes: [
                   Raw {
                    content: "isSystemUser",
                    position: (38, 9),
                   },
                  ],
                 },
                 Variable {
                  identifier: "true",
                  position: (38, 24),
                 },
                ),
               ],
               recursive: false,
               position: (34, 23),
              },
             ),
            ],
            recursive: false,
            position: (32, 13),
           },
          ),
          KeyValue(
           AttributePath {
            attributes: [
             Raw {
              content: "systemd",
              position: (42, 5),
             },
             Raw {
              content: "services",
              position: (42, 13),
             },
             Raw {
              content: "weechat",
              position: (42, 22),
             },
            ],
           },
           Map {
            bindings: [
             KeyValue(
              AttributePath {
               attributes: [
                Raw {
                 content: "environment",
                 position: (43, 7),
                },
                Raw {
                 content: "WEECHAT_HOME",
                 position: (43, 19),
                },
               ],
              },
              PropertyAccess {
               expression: Variable {
                identifier: "cfg",
                position: (43, 34),
               },
               attribute_path: AttributePath {
                attributes: [
                 Raw {
                  content: "root",
                  position: (43, 38),
                 },
                ],
               },
               default: None,
              },
             ),
             KeyValue(
              AttributePath {
               attributes: [
                Raw {
                 content: "serviceConfig",
                 position: (44, 7),
                },
               ],
              },
              Map {
               bindings: [
                KeyValue(
                 AttributePath {
                  attributes: [
                   Raw {
                    content: "User",
                    position: (45, 9),
                   },
                  ],
                 },
                 String {
                  parts: [
                   Raw {
                    content: "weechat",
                    position: (45, 17),
                   },
                  ],
                 },
                ),
                KeyValue(
                 AttributePath {
                  attributes: [
                   Raw {
                    content: "Group",
                    position: (46, 9),
                   },
                  ],
                 },
                 String {
                  parts: [
                   Raw {
                    content: "weechat",
                    position: (46, 18),
                   },
                  ],
                 },
                ),
                KeyValue(
                 AttributePath {
                  attributes: [
                   Raw {
                    content: "RemainAfterExit",
                    position: (47, 9),
                   },
                  ],
                 },
                 String {
                  parts: [
                   Raw {
                    content: "yes",
                    position: (47, 28),
                   },
                  ],
                 },
                ),
               ],
               recursive: false,
               position: (44, 23),
              },
             ),
             KeyValue(
              AttributePath {
               attributes: [
                Raw {
                 content: "script",
                 position: (49, 7),
                },
               ],
              },
              String {
               parts: [
                Raw {
                 content: "exec ",
                 position: (49, 17),
                },
                Expression {
                 expression: PropertyAccess {
                  expression: Variable {
                   identifier: "config",
                   position: (49, 24),
                  },
                  attribute_path: AttributePath {
                   attributes: [
                    Raw {
                     content: "security",
                     position: (49, 31),
                    },
                    Raw {
                     content: "wrapperDir",
                     position: (49, 40),
                    },
                   ],
                  },
                  default: None,
                 },
                },
                Raw {
                 content: "/screen -Dm -S ",
                 position: (49, 51),
                },
                Expression {
                 expression: PropertyAccess {
                  expression: Variable {
                   identifier: "cfg",
                   position: (49, 68),
                  },
                  attribute_path: AttributePath {
                   attributes: [
                    Raw {
                     content: "sessionName",
                     position: (49, 72),
                    },
                   ],
                  },
                  default: None,
                 },
                },
                Raw {
                 content: " ",
                 position: (49, 84),
                },
                Expression {
                 expression: PropertyAccess {
                  expression: Variable {
                   identifier: "cfg",
                   position: (49, 87),
                  },
                  attribute_path: AttributePath {
                   attributes: [
                    Raw {
                     content: "binary",
                     position: (49, 91),
                    },
                   ],
                  },
                  default: None,
                 },
                },
               ],
              },
             ),
             KeyValue(
              AttributePath {
               attributes: [
                Raw {
                 content: "wantedBy",
                 position: (50, 7),
                },
               ],
              },
              List {
               elements: [
                String {
                 parts: [
                  Raw {
                   content: "multi-user.target",
                   position: (50, 21),
                  },
                 ],
                },
               ],
               position: (50, 18),
              },
             ),
             KeyValue(
              AttributePath {
               attributes: [
                Raw {
                 content: "wants",
                 position: (51, 7),
                },
               ],
              },
              List {
               elements: [
                String {
                 parts: [
                  Raw {
                   content: "network.target",
                   position: (51, 18),
                  },
                 ],
                },
               ],
               position: (51, 15),
              },
             ),
            ],
            recursive: false,
            position: (42, 32),
           },
          ),
          KeyValue(
           AttributePath {
            attributes: [
             Raw {
              content: "security",
              position: (54, 5),
             },
             Raw {
              content: "wrappers",
              position: (54, 14),
             },
             Raw {
              content: "screen",
              position: (54, 23),
             },
            ],
           },
           Map {
            bindings: [
             KeyValue(
              AttributePath {
               attributes: [
                Raw {
                 content: "setuid",
                 position: (55, 9),
                },
               ],
              },
              Variable {
               identifier: "true",
               position: (55, 18),
              },
             ),
             KeyValue(
              AttributePath {
               attributes: [
                Raw {
                 content: "owner",
                 position: (56, 9),
                },
               ],
              },
              String {
               parts: [
                Raw {
                 content: "root",
                 position: (56, 18),
                },
               ],
              },
             ),
             KeyValue(
              AttributePath {
               attributes: [
                Raw {
                 content: "group",
                 position: (57, 9),
                },
               ],
              },
              String {
               parts: [
                Raw {
                 content: "root",
                 position: (57, 18),
                },
               ],
              },
             ),
             KeyValue(
              AttributePath {
               attributes: [
                Raw {
                 content: "source",
                 position: (58, 9),
                },
               ],
              },
              String {
               parts: [
                Expression {
                 expression: PropertyAccess {
                  expression: Variable {
                   identifier: "pkgs",
                   position: (58, 21),
                  },
                  attribute_path: AttributePath {
                   attributes: [
                    Raw {
                     content: "screen",
                     position: (58, 26),
                    },
                   ],
                  },
                  default: None,
                 },
                },
                Raw {
                 content: "/bin/screen",
                 position: (58, 33),
                },
               ],
              },
             ),
            ],
            recursive: false,
            position: (55, 7),
           },
          ),
         ],
         recursive: false,
         position: (31, 28),
        },
       ],
      },
     ),
     KeyValue(
      AttributePath {
       attributes: [
        Raw {
         content: "meta",
         position: (62, 3),
        },
        Raw {
         content: "doc",
         position: (62, 8),
        },
       ],
      },
      Path {
       parts: [
        Raw {
         content: "./weechat.xml",
         position: (62, 14),
        },
       ],
      },
     ),
    ],
    recursive: false,
    position: (9, 1),
   },
   position: (5, 1),
  },
  position: (3, 1),
 },
 position: (1, 1),
}