Honor the XDG_DATA_HOME env var and use the approved default as per specification.
This commit is contained in:
@@ -679,8 +679,14 @@ void LinuxFileSystem::GetSpecialFolderPath(const SpecialFolder type, String& res
|
||||
result = TEXT("/usr/share");
|
||||
break;
|
||||
case SpecialFolder::LocalAppData:
|
||||
result = home;
|
||||
{
|
||||
String dataHome;
|
||||
if (!Platform::GetEnvironmentVariable(TEXT("XDG_DATA_HOME"), dataHome))
|
||||
result = dataHome;
|
||||
else
|
||||
result = home / TEXT(".local/share");
|
||||
break;
|
||||
}
|
||||
case SpecialFolder::ProgramData:
|
||||
result = String::Empty;
|
||||
break;
|
||||
|
||||
Reference in New Issue
Block a user