Skip to content

The settings directory path should be platform-dependant (XDG_CONFIG_HOME) #3513

Closed
@Max-Might

Description

@Max-Might

From EditorSettings::create:

    if (OS::get_singleton()->has_environment("APPDATA")) {
        // Most likely under windows, save here
        config_path=OS::get_singleton()->get_environment("APPDATA");
        config_dir=String(_MKSTR(VERSION_SHORT_NAME)).capitalize();
    } else if (OS::get_singleton()->has_environment("HOME")) {

        config_path=OS::get_singleton()->get_environment("HOME");
        config_dir="."+String(_MKSTR(VERSION_SHORT_NAME)).to_lower();
    }

The settings directory is decided and created here and the OS class has no way to set a custom settings directory.
I am working on the Haiku port and there we do not use ~/.appname for storing settings but ~/config/settings/appname.

So my proposal is to add an OS::get_settings_dir method and use it in EditorSettings::create.

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions