tconbeer / harlequin

The SQL IDE for Your Terminal.
https://harlequin.sh
MIT License
3.55k stars 77 forks source link

Improve config file discovery #471

Closed tconbeer closed 6 months ago

tconbeer commented 6 months ago

See #466

We should default to the XDG Standard on unix systems; platformdirs has an implementation as user_config_dir (or user_config_path). This defaults to the same ~/.config, but can be overridden by $XDG_CONFIG_DIR var. Default in that dir should be harlequin.toml (no dot). Should find .harlequin.toml or harlequin.toml in the cwd.

This should be communicated as a potentially-breaking change.

Docs will have to be updated:

https://github.com/tconbeer/harlequin-web/blob/48eab9d990f39912e67a2d301aa6b101d4bbc02e/src/docs/config-file.md?plain=1#L14