#18257 closed enhancement (fixed)

XDG_STATE_HOME environment variable should be initialized

Reported by: davidkaroly Owned by: nobody
Priority: normal Milestone: R1/beta5
Component: System/POSIX Version: R1/beta4
Keywords: Cc:
Blocked By: Blocking:
Platform: All

Description

The SetupEnvironment script already initializes most of the XDG variables like XDG_CONFIG_HOME, XDG_DATA_HOME.

XDG_STATE_HOME has been introduced in basedir-spec 0.8 so we should take care of this one as well.

see: https://specifications.freedesktop.org/basedir-spec/0.8/ar01s03.html

Change History (5)

comment:1 by waddlesplash, 23 months ago

Component: - GeneralSystem/POSIX

comment:2 by pulkomandy, 21 months ago

Type: bugenhancement

comment:3 by bipolar, 15 months ago

Besides Audacity (as noted by David)...

Newer gnuplot also wants to use $XDG_STATE_HOME (and for now defaults to $HOME/.local/state/ once patched to support $XDG_* on Haiku).

Specs says it is for things like: logs, history, recently used files, or other app state, that is not important enough to be on $XDG_DATA_HOME (and not actually "config" data, so no $XDG_CONFIG_HOME either).

Noticing that our Python (>=3.10) REPL's uses ~/config/var/python/ for its history file...

Maybe we should:

export XDG_STATE_HOME="`finddir B_USER_VAR_DIRECTORY`"

or

export XDG_STATE_HOME="`finddir B_USER_VAR_DIRECTORY/state`"

on SetupEnvironment?

Version 1, edited 15 months ago by bipolar (previous) (next) (diff)

comment:5 by waddlesplash, 10 months ago

Milestone: UnscheduledR1/beta5
Resolution: fixed
Status: newclosed

Fix merged in hrev57631.

Note: See TracTickets for help on using tickets.