diff --git a/SilverAudioPlayer.Avalonia/App.axaml.cs b/SilverAudioPlayer.Avalonia/App.axaml.cs index ae87565..3233fe5 100644 --- a/SilverAudioPlayer.Avalonia/App.axaml.cs +++ b/SilverAudioPlayer.Avalonia/App.axaml.cs @@ -67,9 +67,14 @@ public override void OnFrameworkInitializationCompleted() { if (ApplicationLifetime is IClassicDesktopStyleApplicationLifetime desktop) { + var confdir = Path.Combine(AppContext.BaseDirectory, "Configs"); + if (!Directory.Exists(confdir)) + { + Directory.CreateDirectory(confdir); + } var configuration = new ConfigurationBuilder() .SetBasePath(Directory.GetCurrentDirectory()) - .AddJsonFile(Path.Combine(AppContext.BaseDirectory, "Configs", "appsettings.json"), true) + .AddJsonFile(Path.Combine(confdir, "appsettings.json"), true) .Build(); var logger = new LoggerConfiguration() .ReadFrom.Configuration(configuration) diff --git a/SilverAudioPlayer.targets b/SilverAudioPlayer.targets index 102bc02..6edda7a 100644 --- a/SilverAudioPlayer.targets +++ b/SilverAudioPlayer.targets @@ -1,7 +1,7 @@ - 4.3.3 + 4.3.4 True Portable