1 { pkgs, config, lib, ...}:
4 cfg = config.programs.mepo;
7 options.programs.mepo = {
8 enable = mkEnableOption (mdDoc "Mepo");
14 description = mdDoc ''
15 Whether to enable location detection via gpsd.
16 This may require additional configuration of gpsd, see [here](#opt-services.gpsd.enable)
23 description = mdDoc "Whether to enable location detection via geoclue";
28 config = mkIf cfg.enable {
29 environment.systemPackages = with pkgs; [
31 ] ++ lib.optional cfg.locationBackends.geoclue geoclue2-with-demo-agent
32 ++ lib.optional cfg.locationBackends.gpsd gpsd;
34 services.geoclue2 = mkIf cfg.locationBackends.geoclue {
36 appConfig.where-am-i = {
42 services.gpsd.enable = cfg.locationBackends.gpsd;
45 meta.maintainers = with maintainers; [ laalsaas ];