---
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: "uid",
        position: (7, 3),
       },
      ],
     },
     PropertyAccess {
      expression: Variable {
       identifier: "config",
       position: (7, 9),
      },
      attribute_path: AttributePath {
       attributes: [
        Raw {
         content: "ids",
         position: (7, 16),
        },
        Raw {
         content: "uids",
         position: (7, 20),
        },
        Raw {
         content: "gpsd",
         position: (7, 25),
        },
       ],
      },
      default: None,
     },
    ),
    KeyValue(
     AttributePath {
      attributes: [
       Raw {
        content: "gid",
        position: (8, 3),
       },
      ],
     },
     PropertyAccess {
      expression: Variable {
       identifier: "config",
       position: (8, 9),
      },
      attribute_path: AttributePath {
       attributes: [
        Raw {
         content: "ids",
         position: (8, 16),
        },
        Raw {
         content: "gids",
         position: (8, 20),
        },
        Raw {
         content: "gpsd",
         position: (8, 25),
        },
       ],
      },
      default: None,
     },
    ),
    KeyValue(
     AttributePath {
      attributes: [
       Raw {
        content: "cfg",
        position: (9, 3),
       },
      ],
     },
     PropertyAccess {
      expression: Variable {
       identifier: "config",
       position: (9, 9),
      },
      attribute_path: AttributePath {
       attributes: [
        Raw {
         content: "services",
         position: (9, 16),
        },
        Raw {
         content: "gpsd",
         position: (9, 25),
        },
       ],
      },
      default: None,
     },
    ),
   ],
   target: Map {
    bindings: [
     KeyValue(
      AttributePath {
       attributes: [
        Raw {
         content: "options",
         position: (17, 3),
        },
       ],
      },
      Map {
       bindings: [
        KeyValue(
         AttributePath {
          attributes: [
           Raw {
            content: "services",
            position: (19, 5),
           },
           Raw {
            content: "gpsd",
            position: (19, 14),
           },
          ],
         },
         Map {
          bindings: [
           KeyValue(
            AttributePath {
             attributes: [
              Raw {
               content: "enable",
               position: (21, 7),
              },
             ],
            },
            FunctionApplication {
             function: Variable {
              identifier: "mkOption",
              position: (21, 16),
             },
             arguments: [
              Map {
               bindings: [
                KeyValue(
                 AttributePath {
                  attributes: [
                   Raw {
                    content: "type",
                    position: (22, 9),
                   },
                  ],
                 },
                 PropertyAccess {
                  expression: Variable {
                   identifier: "types",
                   position: (22, 16),
                  },
                  attribute_path: AttributePath {
                   attributes: [
                    Raw {
                     content: "bool",
                     position: (22, 22),
                    },
                   ],
                  },
                  default: None,
                 },
                ),
                KeyValue(
                 AttributePath {
                  attributes: [
                   Raw {
                    content: "default",
                    position: (23, 9),
                   },
                  ],
                 },
                 Variable {
                  identifier: "false",
                  position: (23, 19),
                 },
                ),
                KeyValue(
                 AttributePath {
                  attributes: [
                   Raw {
                    content: "description",
                    position: (24, 9),
                   },
                  ],
                 },
                 String {
                  parts: [
                   Raw {
                    content: "Whether to enable `gpsd', a GPS service daemon.\n",
                    position: (25, 1),
                   },
                  ],
                 },
                ),
               ],
               recursive: false,
               position: (21, 25),
              },
             ],
            },
           ),
           KeyValue(
            AttributePath {
             attributes: [
              Raw {
               content: "device",
               position: (29, 7),
              },
             ],
            },
            FunctionApplication {
             function: Variable {
              identifier: "mkOption",
              position: (29, 16),
             },
             arguments: [
              Map {
               bindings: [
                KeyValue(
                 AttributePath {
                  attributes: [
                   Raw {
                    content: "type",
                    position: (30, 9),
                   },
                  ],
                 },
                 PropertyAccess {
                  expression: Variable {
                   identifier: "types",
                   position: (30, 16),
                  },
                  attribute_path: AttributePath {
                   attributes: [
                    Raw {
                     content: "str",
                     position: (30, 22),
                    },
                   ],
                  },
                  default: None,
                 },
                ),
                KeyValue(
                 AttributePath {
                  attributes: [
                   Raw {
                    content: "default",
                    position: (31, 9),
                   },
                  ],
                 },
                 String {
                  parts: [
                   Raw {
                    content: "/dev/ttyUSB0",
                    position: (31, 20),
                   },
                  ],
                 },
                ),
                KeyValue(
                 AttributePath {
                  attributes: [
                   Raw {
                    content: "description",
                    position: (32, 9),
                   },
                  ],
                 },
                 String {
                  parts: [
                   Raw {
                    content: "A device may be a local serial device for GPS input, or a URL of the form:\n     <literal>[{dgpsip|ntrip}://][user:passwd@]host[:port][/stream]</literal>\nin which case it specifies an input source for DGPS or ntrip data.\n",
                    position: (33, 1),
                   },
                  ],
                 },
                ),
               ],
               recursive: false,
               position: (29, 25),
              },
             ],
            },
           ),
           KeyValue(
            AttributePath {
             attributes: [
              Raw {
               content: "readonly",
               position: (39, 7),
              },
             ],
            },
            FunctionApplication {
             function: Variable {
              identifier: "mkOption",
              position: (39, 18),
             },
             arguments: [
              Map {
               bindings: [
                KeyValue(
                 AttributePath {
                  attributes: [
                   Raw {
                    content: "type",
                    position: (40, 9),
                   },
                  ],
                 },
                 PropertyAccess {
                  expression: Variable {
                   identifier: "types",
                   position: (40, 16),
                  },
                  attribute_path: AttributePath {
                   attributes: [
                    Raw {
                     content: "bool",
                     position: (40, 22),
                    },
                   ],
                  },
                  default: None,
                 },
                ),
                KeyValue(
                 AttributePath {
                  attributes: [
                   Raw {
                    content: "default",
                    position: (41, 9),
                   },
                  ],
                 },
                 Variable {
                  identifier: "true",
                  position: (41, 19),
                 },
                ),
                KeyValue(
                 AttributePath {
                  attributes: [
                   Raw {
                    content: "description",
                    position: (42, 9),
                   },
                  ],
                 },
                 String {
                  parts: [
                   Raw {
                    content: "Whether to enable the broken-device-safety, otherwise\nknown as read-only mode.  Some popular bluetooth and USB\nreceivers lock up or become totally inaccessible when\nprobed or reconfigured.  This switch prevents gpsd from\nwriting to a receiver.  This means that gpsd cannot\nconfigure the receiver for optimal performance, but it\nalso means that gpsd cannot break the receiver.  A better\nsolution would be for Bluetooth to not be so fragile.  A\nplatform independent method to identify\nserial-over-Bluetooth devices would also be nice.\n",
                    position: (43, 1),
                   },
                  ],
                 },
                ),
               ],
               recursive: false,
               position: (39, 27),
              },
             ],
            },
           ),
           KeyValue(
            AttributePath {
             attributes: [
              Raw {
               content: "nowait",
               position: (56, 7),
              },
             ],
            },
            FunctionApplication {
             function: Variable {
              identifier: "mkOption",
              position: (56, 16),
             },
             arguments: [
              Map {
               bindings: [
                KeyValue(
                 AttributePath {
                  attributes: [
                   Raw {
                    content: "type",
                    position: (57, 9),
                   },
                  ],
                 },
                 PropertyAccess {
                  expression: Variable {
                   identifier: "types",
                   position: (57, 16),
                  },
                  attribute_path: AttributePath {
                   attributes: [
                    Raw {
                     content: "bool",
                     position: (57, 22),
                    },
                   ],
                  },
                  default: None,
                 },
                ),
                KeyValue(
                 AttributePath {
                  attributes: [
                   Raw {
                    content: "default",
                    position: (58, 9),
                   },
                  ],
                 },
                 Variable {
                  identifier: "false",
                  position: (58, 19),
                 },
                ),
                KeyValue(
                 AttributePath {
                  attributes: [
                   Raw {
                    content: "description",
                    position: (59, 9),
                   },
                  ],
                 },
                 String {
                  parts: [
                   Raw {
                    content: "don't wait for client connects to poll GPS\n",
                    position: (60, 1),
                   },
                  ],
                 },
                ),
               ],
               recursive: false,
               position: (56, 25),
              },
             ],
            },
           ),
           KeyValue(
            AttributePath {
             attributes: [
              Raw {
               content: "port",
               position: (64, 7),
              },
             ],
            },
            FunctionApplication {
             function: Variable {
              identifier: "mkOption",
              position: (64, 14),
             },
             arguments: [
              Map {
               bindings: [
                KeyValue(
                 AttributePath {
                  attributes: [
                   Raw {
                    content: "type",
                    position: (65, 9),
                   },
                  ],
                 },
                 PropertyAccess {
                  expression: Variable {
                   identifier: "types",
                   position: (65, 16),
                  },
                  attribute_path: AttributePath {
                   attributes: [
                    Raw {
                     content: "port",
                     position: (65, 22),
                    },
                   ],
                  },
                  default: None,
                 },
                ),
                KeyValue(
                 AttributePath {
                  attributes: [
                   Raw {
                    content: "default",
                    position: (66, 9),
                   },
                  ],
                 },
                 Int {
                  value: 2947,
                  position: (66, 19),
                 },
                ),
                KeyValue(
                 AttributePath {
                  attributes: [
                   Raw {
                    content: "description",
                    position: (67, 9),
                   },
                  ],
                 },
                 String {
                  parts: [
                   Raw {
                    content: "The port where to listen for TCP connections.\n",
                    position: (68, 1),
                   },
                  ],
                 },
                ),
               ],
               recursive: false,
               position: (64, 23),
              },
             ],
            },
           ),
           KeyValue(
            AttributePath {
             attributes: [
              Raw {
               content: "debugLevel",
               position: (72, 7),
              },
             ],
            },
            FunctionApplication {
             function: Variable {
              identifier: "mkOption",
              position: (72, 20),
             },
             arguments: [
              Map {
               bindings: [
                KeyValue(
                 AttributePath {
                  attributes: [
                   Raw {
                    content: "type",
                    position: (73, 9),
                   },
                  ],
                 },
                 PropertyAccess {
                  expression: Variable {
                   identifier: "types",
                   position: (73, 16),
                  },
                  attribute_path: AttributePath {
                   attributes: [
                    Raw {
                     content: "int",
                     position: (73, 22),
                    },
                   ],
                  },
                  default: None,
                 },
                ),
                KeyValue(
                 AttributePath {
                  attributes: [
                   Raw {
                    content: "default",
                    position: (74, 9),
                   },
                  ],
                 },
                 Int {
                  value: 0,
                  position: (74, 19),
                 },
                ),
                KeyValue(
                 AttributePath {
                  attributes: [
                   Raw {
                    content: "description",
                    position: (75, 9),
                   },
                  ],
                 },
                 String {
                  parts: [
                   Raw {
                    content: "The debugging level.\n",
                    position: (76, 1),
                   },
                  ],
                 },
                ),
               ],
               recursive: false,
               position: (72, 29),
              },
             ],
            },
           ),
          ],
          recursive: false,
          position: (19, 21),
         },
        ),
       ],
       recursive: false,
       position: (17, 13),
      },
     ),
     KeyValue(
      AttributePath {
       attributes: [
        Raw {
         content: "config",
         position: (87, 3),
        },
       ],
      },
      FunctionApplication {
       function: Variable {
        identifier: "mkIf",
        position: (87, 12),
       },
       arguments: [
        PropertyAccess {
         expression: Variable {
          identifier: "cfg",
          position: (87, 17),
         },
         attribute_path: AttributePath {
          attributes: [
           Raw {
            content: "enable",
            position: (87, 21),
           },
          ],
         },
         default: None,
        },
        Map {
         bindings: [
          KeyValue(
           AttributePath {
            attributes: [
             Raw {
              content: "users",
              position: (89, 5),
             },
             Raw {
              content: "users",
              position: (89, 11),
             },
             Raw {
              content: "gpsd",
              position: (89, 17),
             },
            ],
           },
           Map {
            bindings: [
             Inherit(
              None,
              [
               Raw {
                content: "uid",
                position: (90, 17),
               },
              ],
             ),
             KeyValue(
              AttributePath {
               attributes: [
                Raw {
                 content: "group",
                 position: (91, 9),
                },
               ],
              },
              String {
               parts: [
                Raw {
                 content: "gpsd",
                 position: (91, 18),
                },
               ],
              },
             ),
             KeyValue(
              AttributePath {
               attributes: [
                Raw {
                 content: "description",
                 position: (92, 9),
                },
               ],
              },
              String {
               parts: [
                Raw {
                 content: "gpsd daemon user",
                 position: (92, 24),
                },
               ],
              },
             ),
             KeyValue(
              AttributePath {
               attributes: [
                Raw {
                 content: "home",
                 position: (93, 9),
                },
               ],
              },
              String {
               parts: [
                Raw {
                 content: "/var/empty",
                 position: (93, 17),
                },
               ],
              },
             ),
            ],
            recursive: false,
            position: (90, 7),
           },
          ),
          KeyValue(
           AttributePath {
            attributes: [
             Raw {
              content: "users",
              position: (96, 5),
             },
             Raw {
              content: "groups",
              position: (96, 11),
             },
             Raw {
              content: "gpsd",
              position: (96, 18),
             },
            ],
           },
           Map {
            bindings: [
             Inherit(
              None,
              [
               Raw {
                content: "gid",
                position: (96, 35),
               },
              ],
             ),
            ],
            recursive: false,
            position: (96, 25),
           },
          ),
          KeyValue(
           AttributePath {
            attributes: [
             Raw {
              content: "systemd",
              position: (98, 5),
             },
             Raw {
              content: "services",
              position: (98, 13),
             },
             Raw {
              content: "gpsd",
              position: (98, 22),
             },
            ],
           },
           Map {
            bindings: [
             KeyValue(
              AttributePath {
               attributes: [
                Raw {
                 content: "description",
                 position: (99, 7),
                },
               ],
              },
              String {
               parts: [
                Raw {
                 content: "GPSD daemon",
                 position: (99, 22),
                },
               ],
              },
             ),
             KeyValue(
              AttributePath {
               attributes: [
                Raw {
                 content: "wantedBy",
                 position: (100, 7),
                },
               ],
              },
              List {
               elements: [
                String {
                 parts: [
                  Raw {
                   content: "multi-user.target",
                   position: (100, 21),
                  },
                 ],
                },
               ],
               position: (100, 18),
              },
             ),
             KeyValue(
              AttributePath {
               attributes: [
                Raw {
                 content: "after",
                 position: (101, 7),
                },
               ],
              },
              List {
               elements: [
                String {
                 parts: [
                  Raw {
                   content: "network.target",
                   position: (101, 18),
                  },
                 ],
                },
               ],
               position: (101, 15),
              },
             ),
             KeyValue(
              AttributePath {
               attributes: [
                Raw {
                 content: "serviceConfig",
                 position: (102, 7),
                },
               ],
              },
              Map {
               bindings: [
                KeyValue(
                 AttributePath {
                  attributes: [
                   Raw {
                    content: "Type",
                    position: (103, 9),
                   },
                  ],
                 },
                 String {
                  parts: [
                   Raw {
                    content: "forking",
                    position: (103, 17),
                   },
                  ],
                 },
                ),
                KeyValue(
                 AttributePath {
                  attributes: [
                   Raw {
                    content: "ExecStart",
                    position: (104, 9),
                   },
                  ],
                 },
                 String {
                  parts: [
                   Raw {
                    content: "",
                    position: (105, 1),
                   },
                   Expression {
                    expression: PropertyAccess {
                     expression: Variable {
                      identifier: "pkgs",
                      position: (105, 13),
                     },
                     attribute_path: AttributePath {
                      attributes: [
                       Raw {
                        content: "gpsd",
                        position: (105, 18),
                       },
                      ],
                     },
                     default: None,
                    },
                   },
                   Raw {
                    content: "/sbin/gpsd -D \"",
                    position: (105, 23),
                   },
                   Expression {
                    expression: FunctionApplication {
                     function: Variable {
                      identifier: "toString",
                      position: (105, 40),
                     },
                     arguments: [
                      PropertyAccess {
                       expression: Variable {
                        identifier: "cfg",
                        position: (105, 49),
                       },
                       attribute_path: AttributePath {
                        attributes: [
                         Raw {
                          content: "debugLevel",
                          position: (105, 53),
                         },
                        ],
                       },
                       default: None,
                      },
                     ],
                    },
                   },
                   Raw {
                    content: "\"  \\\n  -S \"",
                    position: (105, 64),
                   },
                   Expression {
                    expression: FunctionApplication {
                     function: Variable {
                      identifier: "toString",
                      position: (106, 19),
                     },
                     arguments: [
                      PropertyAccess {
                       expression: Variable {
                        identifier: "cfg",
                        position: (106, 28),
                       },
                       attribute_path: AttributePath {
                        attributes: [
                         Raw {
                          content: "port",
                          position: (106, 32),
                         },
                        ],
                       },
                       default: None,
                      },
                     ],
                    },
                   },
                   Raw {
                    content: "\"                             \\\n  ",
                    position: (106, 37),
                   },
                   Expression {
                    expression: FunctionApplication {
                     function: Variable {
                      identifier: "optionalString",
                      position: (107, 15),
                     },
                     arguments: [
                      PropertyAccess {
                       expression: Variable {
                        identifier: "cfg",
                        position: (107, 30),
                       },
                       attribute_path: AttributePath {
                        attributes: [
                         Raw {
                          content: "readonly",
                          position: (107, 34),
                         },
                        ],
                       },
                       default: None,
                      },
                      String {
                       parts: [
                        Raw {
                         content: "-b",
                         position: (107, 44),
                        },
                       ],
                      },
                     ],
                    },
                   },
                   Raw {
                    content: "                   \\\n  ",
                    position: (107, 48),
                   },
                   Expression {
                    expression: FunctionApplication {
                     function: Variable {
                      identifier: "optionalString",
                      position: (108, 15),
                     },
                     arguments: [
                      PropertyAccess {
                       expression: Variable {
                        identifier: "cfg",
                        position: (108, 30),
                       },
                       attribute_path: AttributePath {
                        attributes: [
                         Raw {
                          content: "nowait",
                          position: (108, 34),
                         },
                        ],
                       },
                       default: None,
                      },
                      String {
                       parts: [
                        Raw {
                         content: "-n",
                         position: (108, 42),
                        },
                       ],
                      },
                     ],
                    },
                   },
                   Raw {
                    content: "                     \\\n  \"",
                    position: (108, 46),
                   },
                   Expression {
                    expression: PropertyAccess {
                     expression: Variable {
                      identifier: "cfg",
                      position: (109, 16),
                     },
                     attribute_path: AttributePath {
                      attributes: [
                       Raw {
                        content: "device",
                        position: (109, 20),
                       },
                      ],
                     },
                     default: None,
                    },
                   },
                   Raw {
                    content: "\"\n",
                    position: (109, 27),
                   },
                  ],
                 },
                ),
               ],
               recursive: false,
               position: (102, 23),
              },
             ),
            ],
            recursive: false,
            position: (98, 29),
           },
          ),
         ],
         recursive: false,
         position: (87, 28),
        },
       ],
      },
     ),
    ],
    recursive: false,
    position: (13, 1),
   },
   position: (5, 1),
  },
  position: (3, 1),
 },
 position: (1, 1),
}