Merge branch 'develop' of https://github.com/Radarr/Radarr into develop

pull/2/head
Tim Turner 8 years ago
commit 281e516495

18
.gitignore vendored

@ -101,16 +101,21 @@ App_Data/*.ldf
_NCrunch_* _NCrunch_*
_TeamCity* _TeamCity*
# Sonarr # Radarr
config.xml Backups/
nzbdrone.log*txt logs/
MediaCover/
UpdateLogs/ UpdateLogs/
xdg/
config.xml
logs.db*
nzbdrone.db*
nzbdrone.pid
*workspace.xml *workspace.xml
*.test-cache *.test-cache
*.userprefs *.userprefs
*/test-results/* */test-results/*
src/UI/.idea/* src/UI/.idea/*
*log.txt
node_modules/ node_modules/
_output* _output*
_rawPackage/ _rawPackage/
@ -132,13 +137,16 @@ Radarr_*/
Radarr_*.zip Radarr_*.zip
Radarr_*.gz Radarr_*.gz
#OS X metadata files # macOS metadata files
._* ._*
.DS_Store .DS_Store
_start _start
_temp_*/**/* _temp_*/**/*
# Windows thumbnail cache files
Thumbs.db
# AppVeyor # AppVeyor
/tools-cake/ /tools-cake/
/_artifacts/ /_artifacts/

@ -1,12 +1,14 @@
language: csharp language: csharp
solution: src/NzbDrone.sln solution: src/NzbDrone.sln
script: # the following commands are just examples, use whatever your build process requires addons:
apt:
packages:
- nodejs
- npm
script:
- ./build.sh - ./build.sh
- chmod +x test.sh - chmod +x test.sh
# - ./test.sh Linux Unit Takes far too long, maybe even crashes travis :/ # - ./test.sh Linux Unit Takes far too long, maybe even crashes travis :/
install:
- sudo apt-get install nodejs
- sudo apt-get install npm
after_success: after_success:
- chmod +x package.sh - chmod +x package.sh
- ./package.sh - ./package.sh

Binary file not shown.

@ -1,47 +1,50 @@
# Radarr ## Status
[![GitHub issues](https://img.shields.io/github/issues/radarr/radarr.svg?maxAge=60&style=flat-square)](https://github.com/Radarr/Radarr/issues)
[![GitHub pull requests](https://img.shields.io/github/issues-pr/radarr/radarr.svg?maxAge=60&style=flat-square)](https://github.com/Radarr/Radarr/pulls)
[![GNU GPL v3](https://img.shields.io/badge/license-GNU%20GPL%20v3-blue.svg?maxAge=60&style=flat-square)](http://www.gnu.org/licenses/gpl.html)
[![Copyright 2010-2017](https://img.shields.io/badge/copyright-2017-blue.svg?maxAge=60&style=flat-square)](https://github.com/Radarr/Radarr)
| Service | Master | Develop | | Service | Master | Develop |
|----------|:---------------------------:|:----------------------------:| |----------|:---------------------------:|:----------------------------:|
| AppVeyor | [![AppVeyor](https://img.shields.io/appveyor/ci/galli-leo/Radarr/master.svg?maxAge=60&style=flat-square)](https://ci.appveyor.com/project/galli-leo/Radarr) | [![AppVeyor](https://img.shields.io/appveyor/ci/galli-leo/Radarr-usby1/develop.svg?maxAge=60&style=flat-square)](https://ci.appveyor.com/project/galli-leo/Radarr-usby1) | | AppVeyor | [![AppVeyor](https://img.shields.io/appveyor/ci/galli-leo/Radarr/master.svg?maxAge=60&style=flat-square)](https://ci.appveyor.com/project/galli-leo/Radarr) | [![AppVeyor](https://img.shields.io/appveyor/ci/galli-leo/Radarr-usby1/develop.svg?maxAge=60&style=flat-square)](https://ci.appveyor.com/project/galli-leo/Radarr-usby1) |
| Travis | [![Travis](https://img.shields.io/travis/galli-leo/Radarr/master.svg?maxAge=60&style=flat-square)](https://travis-ci.org/galli-leo/Radarr) | [![Travis](https://img.shields.io/travis/galli-leo/Radarr/develop.svg?maxAge=60&style=flat-square)](https://travis-ci.org/galli-leo/Radarr) | | Travis | [![Travis](https://img.shields.io/travis/Radarr/Radarr/master.svg?maxAge=60&style=flat-square)](https://travis-ci.org/Radarr/Radarr) | [![Travis](https://img.shields.io/travis/Radarr/Radarr/develop.svg?maxAge=60&style=flat-square)](https://travis-ci.org/Radarr/Radarr) |
This fork of Sonarr aims to turn it into something like Couchpotato. This fork of Sonarr aims to turn it into something like CouchPotato.
## Currently working: ## Downloads
* Adding new movies [![GitHub Releases](https://img.shields.io/badge/downloads-releases-brightgreen.svg?maxAge=60&style=flat-square)](https://github.com/Radarr/Radarr/releases)
* Manually searching for releases of movies.
* Automatically searching for releases. [![AppVeyor Builds](https://img.shields.io/badge/downloads-continuous-green.svg?maxAge=60&style=flat-square)](https://ci.appveyor.com/project/galli-leo/radarr-usby1/build/artifacts)
* Automatically importing downloaded movies.
* Recognizing Special Editions, Director's Cut, etc.
* Identifying releases with hardcoded subs.
* Rarbg.to, Torznab and Newznab Indexer.
* QBittorrent and Deluge download client (Other clients are coming)
* New TorrentPotato Indexer (Works well with [Jackett](https://github.com/Jackett/Jackett))
## Planned Features: [![Docker x64](https://img.shields.io/badge/docker-x64-blue.svg?maxAge=60&style=flat-square)](https://store.docker.com/community/images/linuxserver/radarr)
[![Docker armhf](https://img.shields.io/badge/docker-armhf-blue.svg?maxAge=60&style=flat-square)](https://store.docker.com/community/images/lsioarmhf/radarr)
[![Docker aarch64](https://img.shields.io/badge/docker-aarch64-blue.svg?maxAge=60&style=flat-square)](https://store.docker.com/community/images/lsioarmhf/radarr-aarch64)
* Scanning PreDB to know when a new release is available. To connect to the UI, fire up your browser and open <http://localhost:7878> or <http://your-ip:7878>.
* Fixing the other Indexers and download clients.
* Importing of Sonarr config.
## Download ## Features
The latest precompiled binary versions can be found here: https://github.com/galli-leo/Radarr/releases. ### Currently Working
To connect to the UI, fire up your browser and open localhost:7878 or your-ip:7878. * Adding new movies
* Manually searching for releases of movies
* Automatically searching for releases
* Automatically importing downloaded movies
* Recognizing Special Editions, Director's Cut, etc.
* Identifying releases with hardcoded subs
* Rarbg.to, Torznab and Newznab Indexer
* QBittorrent and Deluge download client (Other clients are coming)
* New TorrentPotato Indexer (Works well with [Jackett](https://github.com/Jackett/Jackett))
Docker containers from [linuxserver.io](https://linuxserver.io) can be found here. ### Planned Features
* [Radarr (x64)](https://hub.docker.com/r/linuxserver/radarr/)
* [Radarr (armhf)](https://hub.docker.com/r/lsioarmhf/radarr/)
* [Radarr (aarch64)](https://hub.docker.com/r/lsioarmhf/radarr-aarch64/)
For more up to date versions (but also sometimes broken), daily builds can be found here: * Scanning PreDB to know when a new release is available
* [OSX](https://leonardogalli.ch/radarr/builds/latest.php?os=osx) * Fixing the other Indexers and download clients
* [Windows](https://leonardogalli.ch/radarr/builds/latest.php?os=windows) * Importing of Sonarr config
* [Linux](https://leonardogalli.ch/radarr/builds/latest.php?os=mono)
## Major Features Include: ### Major Features
* Support for major platforms: Windows, Linux, macOS, Raspberry Pi, etc. * Support for major platforms: Windows, Linux, macOS, Raspberry Pi, etc.
* Can watch for better quality of the movies you have and do an automatic upgrade. *eg. from DVD to Blu-Ray* * Can watch for better quality of the movies you have and do an automatic upgrade. *eg. from DVD to Blu-Ray*
@ -51,37 +54,32 @@ For more up to date versions (but also sometimes broken), daily builds can be fo
* Full integration with Kodi, Plex (notification, library update, metadata) * Full integration with Kodi, Plex (notification, library update, metadata)
* And a beautiful UI * And a beautiful UI
## Configuring Development Environment: ## Configuring Development Environment
### Requirements ### Requirements
* Visual Studio 2015 [Free Community Edition](https://www.visualstudio.com/en-us/products/visual-studio-community-vs.aspx) or Mono * [Visual Studio Community](https://www.visualstudio.com/vs/community/) or [MonoDevelop](http://www.monodevelop.com)
* [Git](https://git-scm.com/downloads) * [Git](https://git-scm.com/downloads)
* [NodeJS](https://nodejs.org/download/) * [Node.js](https://nodejs.org/en/download/)
### Setup ### Setup
* Make sure all the required software mentioned above are installed. * Make sure all the required software mentioned above are installed
* Clone the repository into your development machine. [*info*](https://help.github.com/articles/working-with-repositories) * Clone the repository into your development machine ([*info*](https://help.github.com/desktop/guides/contributing/working-with-your-remote-repository-on-github-or-github-enterprise))
* Grab the submodules `git submodule init && git submodule update` * Grab the submodules `git submodule init && git submodule update`
* Install the required Node Packages `npm install` * Install the required Node Packages `npm install`
* Start gulp to monitor your dev environment for any changes that need post processing using `npm start` command. * Start gulp to monitor your dev environment for any changes that need post processing using `npm start` command.
*Please note gulp must be running at all times while you are working with Radarr client source files.* *Please note: gulp must be running at all times while you are working with Radarr client source files.*
### Development ### Development
* Open `NzbDrone.sln` in Visual Studio or run the build.sh script, if Mono is installed. * Open `NzbDrone.sln` in Visual Studio or run the build.sh script, if Mono is installed
* Make sure `NzbDrone.Console` is set as the startup project * Make sure `NzbDrone.Console` is set as the startup project
### License ## Sponsors
* [GNU GPL v3](http://www.gnu.org/licenses/gpl.html)
* Copyright 2010-2016
### Sponsors
* [JetBrains](http://www.jetbrains.com/) for providing us with free licenses to their great tools [JetBrains](http://www.jetbrains.com) for providing us with free licenses to their great tools:
* [ReSharper](http://www.jetbrains.com/resharper/) * [ReSharper](http://www.jetbrains.com/resharper)
* [WebStorm](http://www.jetbrains.com/webstorm/) * [WebStorm](http://www.jetbrains.com/webstorm)
* [TeamCity](http://www.jetbrains.com/teamcity/) * [TeamCity](http://www.jetbrains.com/teamcity)

@ -124,7 +124,7 @@ namespace NzbDrone.Core.Indexers.Newznab
{ {
var pageableRequests = new IndexerPageableRequestChain(); var pageableRequests = new IndexerPageableRequestChain();
if (SupportsMovieSearch) if (false)
{ {
pageableRequests.Add(GetPagedRequests(MaxPages, Settings.Categories, "movie", pageableRequests.Add(GetPagedRequests(MaxPages, Settings.Categories, "movie",
string.Format("&imdbid={0}", searchCriteria.Movie.ImdbId.Substring(2)))); //strip off the "tt" - VERY HACKY string.Format("&imdbid={0}", searchCriteria.Movie.ImdbId.Substring(2)))); //strip off the "tt" - VERY HACKY
@ -133,7 +133,7 @@ namespace NzbDrone.Core.Indexers.Newznab
{ {
//Let's try anyways with q parameter, worst case nothing found. //Let's try anyways with q parameter, worst case nothing found.
pageableRequests.Add(GetPagedRequests(MaxPages, Settings.Categories, "search", pageableRequests.Add(GetPagedRequests(MaxPages, Settings.Categories, "search",
string.Format("&q={0}", searchCriteria.Movie.Title))); string.Format("&q={0}", Parser.Parser.NormalizeTitle(searchCriteria.Movie.Title))));
} }
return pageableRequests; return pageableRequests;

@ -58,7 +58,7 @@ namespace NzbDrone.Core.Organizer
public static readonly Regex SeriesTitleRegex = new Regex(@"(?<token>\{(?:Series)(?<separator>[- ._])(Clean)?Title\})", public static readonly Regex SeriesTitleRegex = new Regex(@"(?<token>\{(?:Series)(?<separator>[- ._])(Clean)?Title\})",
RegexOptions.Compiled | RegexOptions.IgnoreCase); RegexOptions.Compiled | RegexOptions.IgnoreCase);
public static readonly Regex MovieTitleRegex = new Regex(@"(?<token>\{(?:Movie)(?<separator>[- ._])(Clean)?Title\})", public static readonly Regex MovieTitleRegex = new Regex(@"(?<token>\{((?:(Movie|Original))(?<separator>[- ._])(Clean)?Title)\})",
RegexOptions.Compiled | RegexOptions.IgnoreCase); RegexOptions.Compiled | RegexOptions.IgnoreCase);
private static readonly Regex FileNameCleanupRegex = new Regex(@"([- ._])(\1)+", RegexOptions.Compiled); private static readonly Regex FileNameCleanupRegex = new Regex(@"([- ._])(\1)+", RegexOptions.Compiled);
@ -163,6 +163,7 @@ namespace NzbDrone.Core.Organizer
AddReleaseDateTokens(tokenHandlers, movie.Year); //In case we want to separate the year AddReleaseDateTokens(tokenHandlers, movie.Year); //In case we want to separate the year
AddQualityTokens(tokenHandlers, movie, movieFile); AddQualityTokens(tokenHandlers, movie, movieFile);
AddMediaInfoTokens(tokenHandlers, movieFile); AddMediaInfoTokens(tokenHandlers, movieFile);
AddMovieFileTokens(tokenHandlers, movieFile);
var fileName = ReplaceTokens(pattern, tokenHandlers, namingConfig).Trim(); var fileName = ReplaceTokens(pattern, tokenHandlers, namingConfig).Trim();
fileName = FileNameCleanupRegex.Replace(fileName, match => match.Captures[0].Value[0].ToString()); fileName = FileNameCleanupRegex.Replace(fileName, match => match.Captures[0].Value[0].ToString());
@ -503,6 +504,13 @@ namespace NzbDrone.Core.Organizer
tokenHandlers["{Release Group}"] = m => episodeFile.ReleaseGroup ?? m.DefaultValue("Sonarr"); tokenHandlers["{Release Group}"] = m => episodeFile.ReleaseGroup ?? m.DefaultValue("Sonarr");
} }
private void AddMovieFileTokens(Dictionary<string, Func<TokenMatch, string>> tokenHandlers, MovieFile episodeFile)
{
tokenHandlers["{Original Title}"] = m => GetOriginalTitle(episodeFile);
tokenHandlers["{Original Filename}"] = m => GetOriginalFileName(episodeFile);
tokenHandlers["{Release Group}"] = m => episodeFile.ReleaseGroup ?? m.DefaultValue("Sonarr");
}
private void AddQualityTokens(Dictionary<string, Func<TokenMatch, string>> tokenHandlers, Series series, EpisodeFile episodeFile) private void AddQualityTokens(Dictionary<string, Func<TokenMatch, string>> tokenHandlers, Series series, EpisodeFile episodeFile)
{ {
var qualityTitle = _qualityDefinitionService.Get(episodeFile.Quality.Quality).Title; var qualityTitle = _qualityDefinitionService.Get(episodeFile.Quality.Quality).Title;

Binary file not shown.

Binary file not shown.
Loading…
Cancel
Save