You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Feb 18, 2025. It is now read-only.
Repository navigation
This repository was archived by the owner on Feb 18, 2025. It is now read-only.
The $XDG_STATE_HOME contains state data that should persist between (application) restarts, but that is not important or portable enough to the user that it should be stored in $XDG_DATA_HOME.
To me, this seems to indicate that non-portable files should be stored here. Of course, changing this would be a breaking change.
XDG_DATA_HOME is often synced between machines by the user. XDG_STATE_HOME is not to be synced, as it's for local application state. When XDG_DATA_HOME is used, the expectation for data_local_dir's contents to not be synced is broken. Additionally, the "state_dir" that's only supported on Linux is a weird outlier (in that storing local state makes sense on Windows and Mac, unlike runtime_dir/executable_dir) and is as such unlikely to be used by devs for cross-platform apps. IMO it makes much more sense to merge state_dir and data_local_dir, since they both share roughly the same purpose (storing machine-specific files).
Activity
soc commentedon Apr 8, 2023
I think this would be rather surprising for users – which issue would such a behavior address?
chayleaf commentedon Apr 21, 2023
XDG_DATA_HOME is often synced between machines by the user. XDG_STATE_HOME is not to be synced, as it's for local application state. When XDG_DATA_HOME is used, the expectation for data_local_dir's contents to not be synced is broken. Additionally, the "state_dir" that's only supported on Linux is a weird outlier (in that storing local state makes sense on Windows and Mac, unlike runtime_dir/executable_dir) and is as such unlikely to be used by devs for cross-platform apps. IMO it makes much more sense to merge state_dir and data_local_dir, since they both share roughly the same purpose (storing machine-specific files).