mirror of
https://github.com/lidarr/lidarr.git
synced 2025-08-23 06:45:19 -07:00
Clean up download clients to use radarr as label, fix hoduken, and blackhole. (#635)
* change default label to radarr for rtorrent * change utorrent default label to radarr * change hadoken to use radarr label * change blackhole default to radarr, update hoduken * Episodes don't work, but it needs to be here * Fix blackhole xD
This commit is contained in:
parent
96741570c5
commit
736e0d2e70
6 changed files with 28 additions and 20 deletions
|
@ -39,6 +39,17 @@ namespace NzbDrone.Core.Download.Clients.Blackhole
|
||||||
}
|
}
|
||||||
|
|
||||||
protected override string AddFromMagnetLink(RemoteEpisode remoteEpisode, string hash, string magnetLink)
|
protected override string AddFromMagnetLink(RemoteEpisode remoteEpisode, string hash, string magnetLink)
|
||||||
|
{
|
||||||
|
throw new NotImplementedException("Episodes are not working with Radarr");
|
||||||
|
}
|
||||||
|
|
||||||
|
protected override string AddFromTorrentFile(RemoteEpisode remoteEpisode, string hash, string filename, byte[] fileContent)
|
||||||
|
{
|
||||||
|
throw new NotImplementedException("Episodes are not working with Radarr");
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
protected override string AddFromMagnetLink(RemoteMovie remoteEpisode, string hash, string magnetLink)
|
||||||
{
|
{
|
||||||
if (!Settings.SaveMagnetFiles)
|
if (!Settings.SaveMagnetFiles)
|
||||||
{
|
{
|
||||||
|
@ -62,7 +73,7 @@ namespace NzbDrone.Core.Download.Clients.Blackhole
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
protected override string AddFromTorrentFile(RemoteEpisode remoteEpisode, string hash, string filename, byte[] fileContent)
|
protected override string AddFromTorrentFile(RemoteMovie remoteEpisode, string hash, string filename, byte[] fileContent)
|
||||||
{
|
{
|
||||||
var title = remoteEpisode.Release.Title;
|
var title = remoteEpisode.Release.Title;
|
||||||
|
|
||||||
|
@ -93,7 +104,7 @@ namespace NzbDrone.Core.Download.Clients.Blackhole
|
||||||
{
|
{
|
||||||
DownloadClient = Definition.Name,
|
DownloadClient = Definition.Name,
|
||||||
DownloadId = Definition.Name + "_" + item.DownloadId,
|
DownloadId = Definition.Name + "_" + item.DownloadId,
|
||||||
Category = "sonarr",
|
Category = "radarr",
|
||||||
Title = item.Title,
|
Title = item.Title,
|
||||||
|
|
||||||
TotalSize = item.TotalSize,
|
TotalSize = item.TotalSize,
|
||||||
|
|
|
@ -34,20 +34,7 @@ namespace NzbDrone.Core.Download.Clients.Blackhole
|
||||||
|
|
||||||
protected override string AddFromNzbFile(RemoteEpisode remoteEpisode, string filename, byte[] fileContents)
|
protected override string AddFromNzbFile(RemoteEpisode remoteEpisode, string filename, byte[] fileContents)
|
||||||
{
|
{
|
||||||
var title = remoteEpisode.Release.Title;
|
throw new NotImplementedException("Episodes are not working with Radarr");
|
||||||
|
|
||||||
title = FileNameBuilder.CleanFileName(title);
|
|
||||||
|
|
||||||
var filepath = Path.Combine(Settings.NzbFolder, title + ".nzb");
|
|
||||||
|
|
||||||
using (var stream = _diskProvider.OpenWriteStream(filepath))
|
|
||||||
{
|
|
||||||
stream.Write(fileContents, 0, fileContents.Length);
|
|
||||||
}
|
|
||||||
|
|
||||||
_logger.Debug("NZB Download succeeded, saved to: {0}", filepath);
|
|
||||||
|
|
||||||
return null;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
protected override string AddFromNzbFile(RemoteMovie remoteMovie, string filename, byte[] fileContents)
|
protected override string AddFromNzbFile(RemoteMovie remoteMovie, string filename, byte[] fileContents)
|
||||||
|
|
|
@ -150,13 +150,23 @@ namespace NzbDrone.Core.Download.Clients.Hadouken
|
||||||
}
|
}
|
||||||
|
|
||||||
protected override string AddFromMagnetLink(RemoteEpisode remoteEpisode, string hash, string magnetLink)
|
protected override string AddFromMagnetLink(RemoteEpisode remoteEpisode, string hash, string magnetLink)
|
||||||
|
{
|
||||||
|
throw new NotImplementedException("Episodes are not working with Radarr");
|
||||||
|
}
|
||||||
|
|
||||||
|
protected override string AddFromTorrentFile(RemoteEpisode remoteEpisode, string hash, string filename, byte[] fileContent)
|
||||||
|
{
|
||||||
|
throw new NotImplementedException("Episodes are not working with Radarr");
|
||||||
|
}
|
||||||
|
|
||||||
|
protected override string AddFromMagnetLink(RemoteMovie remoteEpisode, string hash, string magnetLink)
|
||||||
{
|
{
|
||||||
_proxy.AddTorrentUri(Settings, magnetLink);
|
_proxy.AddTorrentUri(Settings, magnetLink);
|
||||||
|
|
||||||
return hash.ToUpper();
|
return hash.ToUpper();
|
||||||
}
|
}
|
||||||
|
|
||||||
protected override string AddFromTorrentFile(RemoteEpisode remoteEpisode, string hash, string filename, byte[] fileContent)
|
protected override string AddFromTorrentFile(RemoteMovie remoteEpisode, string hash, string filename, byte[] fileContent)
|
||||||
{
|
{
|
||||||
return _proxy.AddTorrentFile(Settings, fileContent).ToUpper();
|
return _proxy.AddTorrentFile(Settings, fileContent).ToUpper();
|
||||||
}
|
}
|
||||||
|
|
|
@ -28,7 +28,7 @@ namespace NzbDrone.Core.Download.Clients.Hadouken
|
||||||
{
|
{
|
||||||
Host = "localhost";
|
Host = "localhost";
|
||||||
Port = 7070;
|
Port = 7070;
|
||||||
Category = "sonarr-tv";
|
Category = "radarr";
|
||||||
}
|
}
|
||||||
|
|
||||||
[FieldDefinition(0, Label = "Host", Type = FieldType.Textbox)]
|
[FieldDefinition(0, Label = "Host", Type = FieldType.Textbox)]
|
||||||
|
|
|
@ -26,7 +26,7 @@ namespace NzbDrone.Core.Download.Clients.RTorrent
|
||||||
Host = "localhost";
|
Host = "localhost";
|
||||||
Port = 8080;
|
Port = 8080;
|
||||||
UrlBase = "RPC2";
|
UrlBase = "RPC2";
|
||||||
MovieCategory = "movies-radarr";
|
MovieCategory = "radarr";
|
||||||
}
|
}
|
||||||
|
|
||||||
[FieldDefinition(0, Label = "Host", Type = FieldType.Textbox)]
|
[FieldDefinition(0, Label = "Host", Type = FieldType.Textbox)]
|
||||||
|
|
|
@ -23,7 +23,7 @@ namespace NzbDrone.Core.Download.Clients.UTorrent
|
||||||
{
|
{
|
||||||
Host = "localhost";
|
Host = "localhost";
|
||||||
Port = 9091;
|
Port = 9091;
|
||||||
TvCategory = "tv-sonarr";
|
TvCategory = "radarr";
|
||||||
}
|
}
|
||||||
|
|
||||||
[FieldDefinition(0, Label = "Host", Type = FieldType.Textbox)]
|
[FieldDefinition(0, Label = "Host", Type = FieldType.Textbox)]
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue