Duncan Tourolle d890c11a9b
All checks were successful
🏗️ Build Plugin / build (push) Successful in 2m1s
🧪 Test Plugin / test (push) Successful in 1m0s
🚀 Release Plugin / build-and-release (push) Successful in 2m1s
Add a retention timer for podcast
2025-12-30 16:20:26 +01:00

80 lines
2.6 KiB
C#

using MediaBrowser.Model.Plugins;
namespace Jellyfin.Plugin.Jellypod.Configuration;
/// <summary>
/// Plugin configuration for Jellypod.
/// </summary>
public class PluginConfiguration : BasePluginConfiguration
{
/// <summary>
/// Initializes a new instance of the <see cref="PluginConfiguration"/> class.
/// </summary>
public PluginConfiguration()
{
PodcastStoragePath = string.Empty;
UpdateIntervalHours = 6;
GlobalAutoDownloadEnabled = true;
MaxConcurrentDownloads = 2;
MaxEpisodesPerPodcast = 50;
MaxEpisodeAgeDays = 0;
CreatePodcastFolders = true;
DownloadNewEpisodesOnly = true;
PostDownloadScriptPath = string.Empty;
PostDownloadScriptTimeout = 60;
}
/// <summary>
/// Gets or sets the path where podcasts will be stored.
/// Leave empty to use the default Jellyfin data path.
/// </summary>
public string PodcastStoragePath { get; set; }
/// <summary>
/// Gets or sets the update interval in hours for checking new episodes.
/// </summary>
public int UpdateIntervalHours { get; set; }
/// <summary>
/// Gets or sets a value indicating whether auto-download is enabled globally.
/// </summary>
public bool GlobalAutoDownloadEnabled { get; set; }
/// <summary>
/// Gets or sets the maximum number of concurrent downloads.
/// </summary>
public int MaxConcurrentDownloads { get; set; }
/// <summary>
/// Gets or sets the maximum episodes to keep per podcast (0 = unlimited).
/// </summary>
public int MaxEpisodesPerPodcast { get; set; }
/// <summary>
/// Gets or sets the maximum age in days for downloaded episodes (0 = unlimited).
/// Episodes older than this will be automatically deleted.
/// </summary>
public int MaxEpisodeAgeDays { get; set; }
/// <summary>
/// Gets or sets a value indicating whether to create subfolders for each podcast.
/// </summary>
public bool CreatePodcastFolders { get; set; }
/// <summary>
/// Gets or sets a value indicating whether to only download new episodes after subscription.
/// </summary>
public bool DownloadNewEpisodesOnly { get; set; }
/// <summary>
/// Gets or sets the path to post-download processing script.
/// Script is called with: script input_file output_file.
/// </summary>
public string PostDownloadScriptPath { get; set; }
/// <summary>
/// Gets or sets the timeout in seconds for post-download script execution.
/// </summary>
public int PostDownloadScriptTimeout { get; set; }
}