A new version of the XDG Base Directory Spec was released last month which contains an addition that I'm excited for:
A quick intro for newbies: the XDG Base Directory Spec sets a standard for applications for where to put files, for example in
~/.cache, rather than dumping files unceremoniously across the user's home directory.
However, there has long been a hole for where to put state files, like logs or history files. Previously, the spec had directories for config, data, and cache.
Putting state files in config sucked because a lot of people use VCS on their config and it doesn't make sense to commit ever-changing state files, nor sync them across machines.
Putting them in cache doesn't work since cache should be safe to delete, only requiring time to regenerate them.
Data wasn't quite a good match either, although most applications ended up using the data dir, because the spec always implied that they were the user equivalent to
/usr/share. You would store things like user font files, things that are write once and can be copied to other machines. For comparison, you would usually not sync logs or history files across machines.
See these links for some more context:
Anyway, I'm excited to see the new
XDG_STATE_HOME and I hope the community agrees and starts adding support so we can all have better home dirs!