Skip to content

Config dir on macOS should not be ~/Library/Preferences #21

@Torrencem

Description

@Torrencem

This is roughly a migration of the issue on the old repository. To summarize:

  1. On MacOS, the library serves ~/Library/Preferences as the config directory. I consider this incorrect:
  2. Apple documentation says:

You should not create files in this directory yourself. Instead, use the NSUserDefaults class or CFPreferences API to get and set preference values for your app.

  1. On the apple documentation linked in the README, it seems pretty clear that config should return ~/Library/Application Support:

Put app-created support files in the Library/Application support/ directory. In general, this directory includes files that the app uses to run but that should remain hidden from the user. This directory can also include data files, configuration files, templates and modified versions of resources loaded from the app bundle.

There was also some discussion of using ~/.config/ like on linux, as several popular CLI apps on Mac use this directory (neovim is mentioned, checking my .config I see neofetch as well). I don't think this is appropriate, since many more use ~/Library/Application Support (checking my mac, Firefox Inkscape llvmenv iTerm2 and Audacity are all examples which use it, usually with some kind of CLI)

So, I'm hoping that this can be resolved by changing the directory to ~Library/Application Support

Metadata

Metadata

Assignees

No one assigned

    Labels

    A-macArea: Affects only macOS targetsC-bugCategory: This is a bug.I-breakingInfo: Breaking changes. May require a new major release.I-needs-decisionInfo: Need to discuss and decide

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions