From bff6f475287205b8b1709fcdafd403430967a0c5 Mon Sep 17 00:00:00 2001 From: Manuel Thalmann Date: Wed, 15 May 2024 17:45:24 +0200 Subject: [PATCH] Add support for WebDAV providers --- lib/modules/rclone.nix | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/lib/modules/rclone.nix b/lib/modules/rclone.nix index 2c7a599..447ec14 100644 --- a/lib/modules/rclone.nix +++ b/lib/modules/rclone.nix @@ -33,6 +33,24 @@ let ; }; + mkWebdavProvider = { vendor, vendorName }: ( + mkProvider { + displayName = vendorName; + + options = { + vendor = lib.mkOption { + type = lib.types.str; + description = "The vendor of the WebDAV share."; + default = vendor; + }; + + url = lib.mkOption { + type = lib.types.str; + description = "The WebDAV URL of the ${vendorName} server to connect to."; + }; + }; + }); + syncProviders = { nextcloud = mkProvider {}; proton = mkProvider {};