Commit 8852f50
committed
Respect XDG_CONFIG_HOME on Linux
The application's configuration is stored using `ApplicationProperties`
which doesn't consider the *XDG Base Directory Specification*. There is
`File::userApplicationDataDirectory` but it also doesn't respect it
according to an upstream [bug report].
Supporting the full specification is more effort but just supporting
`XDG_CONFIG_HOME` already addresses the common issue of the home
directory being spammed with configuration files. So just read that
environment variable or use its default to set the `folderName`, with an
appended application name since the specification suggests to also use
a subfolder.
This is a breaking change for Linux users but since none are known at
the time it seems acceptable to just switch instead of supporting some
form of migration. It's also mentioned in the change log.
[bug report]: juce-framework/JUCE#11841 parent 3fa5383 commit 8852f50
2 files changed
+14
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
7 | 7 | | |
8 | 8 | | |
9 | 9 | | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
10 | 14 | | |
11 | 15 | | |
12 | 16 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
31 | 31 | | |
32 | 32 | | |
33 | 33 | | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
34 | 44 | | |
35 | 45 | | |
36 | 46 | | |
| |||
0 commit comments