xi-editor / xi-mac

The xi-editor mac frontend.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Populate new config file with defaults

jansol opened this issue · comments

Currently when no config file is present and the user hits cmd+, xi-mac appears to do nothing and silently creates an empty config file. Instead, it should create a config file with the current config and open that.

huh, we actually have a special client_example.toml file in core that is supposed to be copied over in this case. If that isn't happening this is a regression.

Speaking of which, we probably should either a) switch the config file name to something ending in .toml or b) move to NSUserDefaults and a config GUI like a proper macOS application.

yea, it would be nice if we had something like json-schema so that we could autocomplete config values / provide validation, at least.

The file ~/Library/Application Support/XiEditor/preferences.xiconfig seems to be created on install or something and it is populated. However, if you remove it and then open the editor preferences, the file is recreated but is indeed empty.

@mb21 this is being addressed in #471. 🙏