diff options
| author | JP Dillingham <jp@dillingham.me> | 2023-11-04 16:42:58 -0500 |
|---|---|---|
| committer | JP Dillingham <jp@dillingham.me> | 2023-11-04 16:42:58 -0500 |
| commit | c5fc9484b21f9f1028b6ac515813d3101c20a1ef (patch) | |
| tree | 2d2ff5be2c4c6ef2531e7a071ba69363efcec815 /src | |
| parent | 540f1d24aa9625651c45d00cf5458392872ada1f (diff) | |
| download | slskd-c5fc9484b21f9f1028b6ac515813d3101c20a1ef.tar.gz | |
add LogDirectory prop
Diffstat (limited to 'src')
| -rw-r--r-- | src/slskd/Program.cs | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/slskd/Program.cs b/src/slskd/Program.cs index 7a832ddb..eef3a2dd 100644 --- a/src/slskd/Program.cs +++ b/src/slskd/Program.cs @@ -198,6 +198,11 @@ namespace slskd public static string DefaultIncompleteDirectory { get; private set; } /// <summary> + /// Gets the path where application logs are saved. + /// </summary> + public static string LogDirectory { get; private set; } = null; + + /// <summary> /// Gets a buffer containing the last few log events. /// </summary> public static ConcurrentFixedSizeQueue<LogRecord> LogBuffer { get; } = new ConcurrentFixedSizeQueue<LogRecord>(size: 100); @@ -315,6 +320,7 @@ namespace slskd // derive the application directory value and defaults that are dependent upon it AppDirectory ??= DefaultAppDirectory; DataDirectory = Path.Combine(AppDirectory, "data"); + LogDirectory = Path.Combine(AppDirectory, "logs"); DefaultConfigurationFile = Path.Combine(AppDirectory, $"{AppName}.yml"); DefaultDownloadsDirectory = Path.Combine(AppDirectory, "downloads"); |
