mirror of
https://github.com/jellyfin/jellyfin.git
synced 2025-12-27 03:04:49 +03:00
Rewrite rules for determining app paths and use XDG_CONFIG_HOME for configDir (#781)
Re-write rules for determining dataDir, configDir and logDir. Generally, arguments from command line take precedence, then JELLYFIN env vars, before using XDG names. Co-Authored-By: ploughpuff <33969763+ploughpuff@users.noreply.github.com>
This commit is contained in:
@@ -15,21 +15,17 @@ namespace Emby.Server.Implementations
|
||||
/// </summary>
|
||||
public ServerApplicationPaths(
|
||||
string programDataPath,
|
||||
string appFolderPath,
|
||||
string applicationResourcesPath,
|
||||
string logDirectoryPath = null,
|
||||
string configurationDirectoryPath = null,
|
||||
string cacheDirectoryPath = null)
|
||||
string logDirectoryPath,
|
||||
string configurationDirectoryPath,
|
||||
string cacheDirectoryPath)
|
||||
: base(programDataPath,
|
||||
appFolderPath,
|
||||
logDirectoryPath,
|
||||
configurationDirectoryPath,
|
||||
cacheDirectoryPath)
|
||||
{
|
||||
ApplicationResourcesPath = applicationResourcesPath;
|
||||
}
|
||||
|
||||
public string ApplicationResourcesPath { get; private set; }
|
||||
public string ApplicationResourcesPath { get; } = AppContext.BaseDirectory;
|
||||
|
||||
/// <summary>
|
||||
/// Gets the path to the base root media directory
|
||||
@@ -148,7 +144,6 @@ namespace Emby.Server.Implementations
|
||||
set => _internalMetadataPath = value;
|
||||
}
|
||||
|
||||
private const string _virtualInternalMetadataPath = "%MetadataPath%";
|
||||
public string VirtualInternalMetadataPath => _virtualInternalMetadataPath;
|
||||
public string VirtualInternalMetadataPath { get; } = "%MetadataPath%";
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user