From 349d62b5cc4ea7f02c5433cf41f0f74ce20e80bd Mon Sep 17 00:00:00 2001 From: andy Date: Wed, 2 Mar 2022 19:12:16 +0000 Subject: [PATCH] correcting cron schedule to once a day --- Selector.CLI/Options.cs | 2 +- Selector.CLI/Properties/launchSettings.json | 12 ++++++++++-- .../Extensions/ScrobbleRepositoryExtensions.cs | 13 +++++++++++++ 3 files changed, 24 insertions(+), 3 deletions(-) create mode 100644 Selector.Model/Extensions/ScrobbleRepositoryExtensions.cs diff --git a/Selector.CLI/Options.cs b/Selector.CLI/Options.cs index 9d2b969..eb9bb85 100644 --- a/Selector.CLI/Options.cs +++ b/Selector.CLI/Options.cs @@ -124,7 +124,7 @@ namespace Selector.CLI public const string Key = "Scrobble"; public bool Enabled { get; set; } = true; - public string FullScrobbleCron { get; set; } = "0 2 * * * ?"; + public string FullScrobbleCron { get; set; } = "0 0 2 * * *"; public TimeSpan InterJobDelay { get; set; } = TimeSpan.FromMinutes(5); public TimeSpan InterRequestDelay { get; set; } = TimeSpan.FromMilliseconds(100); public DateTime? From { get; set; } = DateTime.UtcNow.AddDays(-14); diff --git a/Selector.CLI/Properties/launchSettings.json b/Selector.CLI/Properties/launchSettings.json index 3751a5a..fc2ac50 100644 --- a/Selector.CLI/Properties/launchSettings.json +++ b/Selector.CLI/Properties/launchSettings.json @@ -9,7 +9,7 @@ }, "Selector.CLI.Scrobble": { "commandName": "Project", - "commandLineArgs": "scrobble save -u sarsoo --from \"2022/01/01\" -nr -na", + "commandLineArgs": "scrobble save -u sarsoo --from \"2022/01/01\"", "environmentVariables": { "DOTNET_ENVIRONMENT": "Development" }, @@ -17,7 +17,7 @@ }, "Selector.CLI.Scrobble.All": { "commandName": "Project", - "commandLineArgs": "scrobble save -u sarsoo --from \"2017/01/01\" -p 200 -d 75 -na -nr", + "commandLineArgs": "scrobble save -u sarsoo --from \"2017/01/01\" -p 200 -d 120", "environmentVariables": { "DOTNET_ENVIRONMENT": "Development" }, @@ -30,6 +30,14 @@ "DOTNET_ENVIRONMENT": "Development" }, "nativeDebugging": true + }, + "Selector.CLI.Scrobble.Map": { + "commandName": "Project", + "commandLineArgs": "scrobble map --artist -l 50 --album --track", + "environmentVariables": { + "DOTNET_ENVIRONMENT": "Development" + }, + "nativeDebugging": true } } } \ No newline at end of file diff --git a/Selector.Model/Extensions/ScrobbleRepositoryExtensions.cs b/Selector.Model/Extensions/ScrobbleRepositoryExtensions.cs new file mode 100644 index 0000000..a02c9f7 --- /dev/null +++ b/Selector.Model/Extensions/ScrobbleRepositoryExtensions.cs @@ -0,0 +1,13 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace Selector.Model.Extensions +{ + public static class ScrobbleRepositoryExtensions + { + + } +}