Added a post-download hook for applying processing of downloaded audio before adding to library.
🏗️ Build Plugin / build (push) Successful in 2m4s
🧪 Test Plugin / test (push) Successful in 58s
🚀 Release Plugin / build-and-release (push) Successful in 2m1s

This commit is contained in:
2025-12-21 13:59:42 +01:00
parent bc24b40bf2
commit 9ac32e11b5
4 changed files with 311 additions and 11 deletions
@@ -166,6 +166,29 @@
</div>
</div>
<!-- Post-Download Processing -->
<div class="verticalSection">
<h3 class="sectionTitle">Post-Download Processing</h3>
<div class="inputContainer">
<label class="inputLabel inputLabelUnfocused" for="PostDownloadScriptPath">
Post-Download Script Path
</label>
<input id="PostDownloadScriptPath" name="PostDownloadScriptPath" type="text" is="emby-input" />
<div class="fieldDescription">
Optional script to process episodes after download. Called as: script input_file output_file
</div>
</div>
<div class="inputContainer">
<label class="inputLabel inputLabelUnfocused" for="PostDownloadScriptTimeout">
Script Timeout (seconds)
</label>
<input id="PostDownloadScriptTimeout" name="PostDownloadScriptTimeout" type="number" is="emby-input" min="1" max="3600" />
<div class="fieldDescription">
Maximum time to wait for script completion (default: 60 seconds)
</div>
</div>
</div>
<div>
<button is="emby-button" type="submit" class="raised button-submit block emby-button">
<span>Save Settings</span>
@@ -229,6 +252,8 @@
document.querySelector('#MaxConcurrentDownloads').value = config.MaxConcurrentDownloads;
document.querySelector('#MaxEpisodesPerPodcast').value = config.MaxEpisodesPerPodcast;
document.querySelector('#CreatePodcastFolders').checked = config.CreatePodcastFolders;
document.querySelector('#PostDownloadScriptPath').value = config.PostDownloadScriptPath || '';
document.querySelector('#PostDownloadScriptTimeout').value = config.PostDownloadScriptTimeout || 60;
Dashboard.hideLoadingMsg();
});
}
@@ -408,6 +433,8 @@
config.MaxConcurrentDownloads = parseInt(document.querySelector('#MaxConcurrentDownloads').value, 10);
config.MaxEpisodesPerPodcast = parseInt(document.querySelector('#MaxEpisodesPerPodcast').value, 10);
config.CreatePodcastFolders = document.querySelector('#CreatePodcastFolders').checked;
config.PostDownloadScriptPath = document.querySelector('#PostDownloadScriptPath').value;
config.PostDownloadScriptTimeout = parseInt(document.querySelector('#PostDownloadScriptTimeout').value, 10);
ApiClient.updatePluginConfiguration(JellypodConfig.pluginUniqueId, config).then(function (result) {
Dashboard.processPluginConfigurationUpdateResult(result);
});