Skip to content

Commit

Permalink
Bumped library versions
Browse files Browse the repository at this point in the history
Fixed #15 (--meta-remove-property) and #32 (changing timebase)
  • Loading branch information
sandreas committed Nov 4, 2022
1 parent 3ec398c commit ca2e886
Show file tree
Hide file tree
Showing 5 changed files with 17 additions and 25 deletions.
5 changes: 3 additions & 2 deletions tone.Tests/tone.Tests.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -13,12 +13,13 @@
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="16.11.0" />
<PackageReference Include="Moq.AutoMock" Version="3.1.0" />
<PackageReference Include="Sandreas.Files" Version="1.1.1" />
<PackageReference Include="Spectre.Console.Cli" Version="0.45.0" />
<PackageReference Include="xunit" Version="2.4.1" />
<PackageReference Include="xunit.runner.visualstudio" Version="2.4.3">
<PackageReference Include="xunit.runner.visualstudio" Version="2.4.5">
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
<PrivateAssets>all</PrivateAssets>
</PackageReference>
<PackageReference Include="coverlet.collector" Version="3.1.0">
<PackageReference Include="coverlet.collector" Version="3.2.0">
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
<PrivateAssets>all</PrivateAssets>
</PackageReference>
Expand Down
4 changes: 2 additions & 2 deletions tone/Commands/TagCommand.cs
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ public override async Task<int> ExecuteAsync(CommandContext context, TagCommandS
if (showDryRunMessage)
{
_console.WriteLine();
_console.Write(new Markup("[blue]!!! This was a dry-run, no changes where actually saved !!![/]"));
_console.Write(new Markup("[blue]!!! This was a dry-run, no changes where actually saved !!![/]"));
}

return await Task.FromResult((int)returnCode);
Expand Down Expand Up @@ -174,7 +174,7 @@ public override async Task<int> ExecuteAsync(CommandContext context, TagCommandS
_console.Write(diffTable);
continue;
}

var path = Markup.Escape(track.Path ?? "");
var message = !track.Save()
? $"[red]Update failed: {path}[/]"
Expand Down
4 changes: 2 additions & 2 deletions tone/Metadata/Taggers/RemoveTagger.cs
Original file line number Diff line number Diff line change
Expand Up @@ -32,9 +32,9 @@ public async Task<Status<string>> UpdateAsync(IMetadata metadata, IMetadata? ori
{
foreach (var property in _remove)
{
metadata.SetMetadataPropertyValue(property, null);
metadata.RemoveMetadataPropertyValue(property);
}

foreach (var key in _removeAdditional)
{
if(metadata.AdditionalFields.ContainsKey(key))
Expand Down
15 changes: 2 additions & 13 deletions tone/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@
using Sandreas.AudioMetadata;
using Sandreas.Files;
using Spectre.Console;
using Spectre.Console.Cli;
using tone;
using tone.Api.JavaScript;
using tone.Commands;
Expand All @@ -30,6 +29,7 @@
using tone.Serializers;
using tone.Services;
using Serilog;
using Spectre.Console.Cli;
using ILogger = Serilog.ILogger;
using Log = Serilog.Log;

Expand All @@ -44,13 +44,11 @@
services.AddSingleton<ILogger>(_ =>
{
var loggerSettings = settingsProvider.Get<ILoggerSettings>();
// set loglevel to debug, if --debug is present
var configBuilder = new ConfigurationBuilder().AddEnvironmentVariables();
var config = new LoggerConfiguration()
.ReadFrom.Configuration(configBuilder.Build());
// set loglevel to debug, if --debug is present
if (debugMode && loggerSettings != null)
{
loggerSettings.LogLevel = LogLevel.Debug;
Expand Down Expand Up @@ -80,15 +78,12 @@
services.AddSingleton(_ => settingsProvider);
services.AddSingleton<StartupErrorService>();
services.AddSingleton<HttpClient>();
// services.AddTransient<StringWriter>();
services.AddSingleton<FileSystem>();
services.AddSingleton<FileWalker>();
services.AddSingleton<DirectoryLoaderService>();
services.AddSingleton<GrokPatternService>();

services.AddSingleton<ChptFmtNativeMetadataFormat>();
services.AddSingleton<FfmetadataFormat>();

services.AddSingleton<ToneJsonMeta>();
services.AddSingleton(_ => new JsonSerializerSettings
{
Expand All @@ -105,13 +100,9 @@
services.AddSingleton<FfmetadataSerializer>();
services.AddSingleton<SpectreConsoleSerializer>();
services.AddSingleton<ToneJsonSerializer>();

services.AddSingleton<SerializerService>();

services.AddSingleton<SpectreConsoleService>();
services.AddSingleton<ScriptConsole>();


services.AddSingleton(s =>
{
var patternService = s.GetRequiredService<GrokPatternService>();
Expand Down Expand Up @@ -152,8 +143,6 @@
options.CancellationToken(cts.Token);
});
});


services.AddSingleton(sp =>
{
var fs = sp.GetRequiredService<FileSystem>();
Expand Down
14 changes: 8 additions & 6 deletions tone/tone.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -36,32 +36,34 @@


<ItemGroup>
<PackageReference Include="CliWrap" Version="3.4.4" />
<PackageReference Include="CliWrap" Version="3.5.0" />
<PackageReference Include="CSharp.OperationResult" Version="0.1.6" />
<PackageReference Include="grok.net" Version="1.1.0" />
<PackageReference Include="Jint" Version="3.0.0-beta-2038" />
<PackageReference Include="Microsoft.Extensions.Configuration" Version="6.0.0" />
<PackageReference Include="Microsoft.Extensions.Configuration" Version="6.0.1" />
<PackageReference Include="Microsoft.Extensions.Configuration.EnvironmentVariables" Version="6.0.0" />
<PackageReference Include="Microsoft.Extensions.Configuration.Json" Version="6.0.0" />
<PackageReference Include="Microsoft.Extensions.DependencyInjection" Version="6.0.0" />
<PackageReference Include="Microsoft.Extensions.Options.ConfigurationExtensions" Version="6.0.0" />
<PackageReference Include="Newtonsoft.Json" Version="13.0.1" />
<PackageReference Include="Sandreas.AudioMetadata" Version="0.0.8" />
<PackageReference Include="Sandreas.AudioMetadata" Version="0.1.0" />
<PackageReference Include="Sandreas.Files" Version="1.1.1" />
<PackageReference Include="Serilog" Version="2.12.0" />
<PackageReference Include="Serilog.Extensions.Logging" Version="3.1.0" />
<PackageReference Include="Serilog.Settings.Configuration" Version="3.4.0" />
<PackageReference Include="Serilog.Sinks.Console" Version="4.1.0" />
<PackageReference Include="Serilog.Sinks.File" Version="5.0.0" />
<PackageReference Include="Spectre.Console" Version="0.44.0" />
<PackageReference Include="System.IO.Abstractions" Version="17.0.23" />
<PackageReference Include="z440.atl.core" Version="4.11.0" />
<PackageReference Include="Spectre.Console" Version="0.45.0" />
<PackageReference Include="Spectre.Console.Cli" Version="0.45.0" />
<PackageReference Include="System.IO.Abstractions" Version="17.2.3" />
<PackageReference Include="z440.atl.core" Version="4.13.0" />
</ItemGroup>


<ItemGroup>
<Folder Include="Common\Extensions\IEnumerable" />
<Folder Include="var\data\output" />
<Folder Include="var\issues\15" />
</ItemGroup>


Expand Down

0 comments on commit ca2e886

Please sign in to comment.