anchor.diff:              "--keep-monthly 12"
               "--keep-yearly 75"
             ];
  +        };
  +
  +        dynamicFilesFrom = mkOption {
  +          type = with types; nullOr str;
  +          default = null;
  +          description = ''
  +            A script that produces a list of files to back up.  The
  +            results of this command are given to the '--files-from'
  +            option.
  +          '';
  +          example = "find /home/matt/git -type d -name .git";
           };
         };
       }));
  
positive.code:         let
            extraOptions = concatMapStrings (arg: " -o ${arg}") backup.extraOptions;
            resticCmd = "${pkgs.restic}/bin/restic${extraOptions}";
            pruneCmd = if (builtins.length backup.pruneOpts > 0)
                       then [ ( resticCmd + " forget --prune " +
                                (concatStringsSep " " backup.pruneOpts) )
  
negative.code:           restartIfChanged = false;
            serviceConfig = {
              Type = "oneshot";
              ExecStart = [ "${resticCmd} backup ${concatStringsSep " " backup.extraBackupArgs} ${backupPaths}" ] ++ pruneCmd;
              User = backup.user;
              RuntimeDirectory = "restic-backups-${name}";
            } // optionalAttrs (backup.s3CredentialsFile != null) {
              EnvironmentFile = backup.s3CredentialsFile;
            };
          }
          // preStartAttr
          // optionalAttrs (backup.dynamicFilesFrom != null) {
            postStart = ''
              rm ${filesFromTmpFile}
            '';
          })
        ) config.services.restic.backups;
  