36 lines
584 B
Nix
36 lines
584 B
Nix
{
|
|
pkgs,
|
|
config,
|
|
lib,
|
|
inputs,
|
|
...
|
|
}: let
|
|
service = "syncthing";
|
|
cfg = config.darwin.${service};
|
|
in {
|
|
|
|
options.darwin.${service} = {
|
|
enable = lib.mkEnableOption "enables syncthing";
|
|
host = lib.mkOption {
|
|
type = lib.types.nullOr lib.types.str;
|
|
default = config.networking.hostName;
|
|
};
|
|
};
|
|
|
|
config = lib.mkIf cfg.enable {
|
|
# environment.systemPackages = with pkgs; [
|
|
# syncthing
|
|
# syncthingtray
|
|
# ];
|
|
#
|
|
homebrew = {
|
|
# brews = [
|
|
# "syncthing"
|
|
# ];
|
|
casks = [
|
|
"syncthing-app"
|
|
];
|
|
};
|
|
};
|
|
}
|