I have recently been studying the basedir spec pretty carefully in support of 
work on basedir-related software.  I consider myself to be pretty current, 
though I confess I did not review the XDG_STATE_HOME patch request when it came 
through in August.  Having now given it a look, my knee-jerk reaction is "don't 
make more work for me!", but my more considered reaction is to ask what exactly 
"state-related data" is, and how it differs from all four base directory 
categories that already exist.

The patch speaks to this to some extent: "[It] fits right between config and 
cache. It contains convenience data that should be preserved between sessions 
of a program like logs, history, last opened view etc.." I suppose that 
preservation between program sessions is intended to imply preservation between 
login sessions, too, so that $XDG_RUNTIME_DIR is not appropriate, but this does 
not explain why $XDG_DATA_HOME is unsuited for such files.

Overall, my bias is toward avoiding proliferating base directories for more and 
more nuanced categories of files.  The whole point of basedir is to centralize 
files in a small number of locations instead of each program having its own, 
independent directory(-ies), and creating new base directory categories works 
against that.

If the concept of state-related data as a category warranting its own base 
directory were accepted then I would have a few things to say about the 
specific wording suggested, but let's not put the cart before the horse.


Regards,

John Bollinger


-----Original Message-----
From: xdg [mailto:xdg-boun...@lists.freedesktop.org] On Behalf Of piegames
Sent: Saturday, November 02, 2019 10:52 AM
To: xdg@lists.freedesktop.org
Subject: Re: [PATCH] Add XDG_STATE_HOME

Caution: External Sender


Any opinions on this? I need some feedback to get it merged.

The patch as merge request on Gitlab: <
https://nam03.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgitlab.freedesktop.org%2Fxdg%2Fxdg-specs%2Fmerge_requests%2F4&amp;data=01%7C01%7CJohn.Bollinger%40stjude.org%7C3a620a51ef1c4bd8fda108d75fadca0d%7C22340fa892264871b677d3b3e377af72%7C0&amp;sdata=eD7772VsBSkCYGDVSDy0gR4GZVb7zRboMZZI4mFiwxM%3D&amp;reserved=0>

On Tue, 2019-08-20 at 00:48 +0200, piegames wrote:
> A few years ago, there was a discussion about an `XDG_STATE_HOME`
> folder. I also found a patch that adds `XDG_BIN_HOME` deep in the
> mailing list's archive (which, by the way, is still not merged
> @maintainer).
>
> I've made a patch similar to the one adding the `bin` directory based
> on the discussion mentioned above.
>
> Regard,
> piegames
>
>
> ---
>  basedir/basedir-spec.xml | 18 ++++++++++++++++++
>  1 file changed, 18 insertions(+)
>
> diff --git a/basedir/basedir-spec.xml b/basedir/basedir-spec.xml index
> 8e6fff6..951c493 100644
> --- a/basedir/basedir-spec.xml
> +++ b/basedir/basedir-spec.xml
> @@ -66,6 +66,13 @@
>              environment variable
> <literal>$XDG_CONFIG_HOME</literal>.
>            </para>
>          </listitem>
> +        <listitem>
> +          <para>
> +            There is a single base directory relative to which user-
> specific
> +            state data should be written. This directory is defined
> by
> the
> +            environment variable <literal>$XDG_STATE_HOME</literal>.
> +          </para>
> +        </listitem>
>          <listitem>
>            <para>
>              There is a set of preference ordered base directories
> relative to @@ -121,6 +128,17 @@
>        <literal>$XDG_CONFIG_HOME</literal> is either not set or empty,
> a default equal to
>        <literal>$HOME</literal>/.config should be used.
>      </para>
> +    <para>
> +      <literal>$XDG_STATE_HOME</literal> defines the base directory
> relative to
> +      which user-specific state files should be stored. If
> +      <literal>$XDG_STATE_HOME</literal> is either not set or empty,
> a
> default equal to
> +      <literal>$HOME</literal>/.local/state should be used.
> +    </para>
> +    <para>
> +      The <literal>$XDG_STATE_HOME</literal> fits right between
> config
> and cache. It contains
> +      convenience data that should be preserved between sessions of
> a
> program like logs, history,
> +      last opened view etc.
> +    </para>
>      <para>
>        <literal>$XDG_DATA_DIRS</literal> defines the preference-
> ordered set of
>        base directories to search for data files in addition to the

_______________________________________________
xdg mailing list
xdg@lists.freedesktop.org
https://nam03.safelinks.protection.outlook.com/?url=https%3A%2F%2Flists.freedesktop.org%2Fmailman%2Flistinfo%2Fxdg&amp;data=01%7C01%7CJohn.Bollinger%40stjude.org%7C3a620a51ef1c4bd8fda108d75fadca0d%7C22340fa892264871b677d3b3e377af72%7C0&amp;sdata=1HPgO1p73vbrjxYyL%2FMG7bSFBRjcTukj2ziaSCphuVY%3D&amp;reserved=0

________________________________

Email Disclaimer: www.stjude.org/emaildisclaimer
Consultation Disclaimer: www.stjude.org/consultationdisclaimer
_______________________________________________
xdg mailing list
xdg@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/xdg

Reply via email to