Re: groff 1.24.0.rc2 on other platforms

Bruno Haible via GNU roff typesetting system discussion <[email protected]>
Newsgroups gmane.comp.printing.groff.general
Organization GNU
Message-ID <3971727.t8Li8AQZDH@nimes>
Hi Deri,

Programs should not create arbitrary directories in $HOME. That was
commonplace 20 or 30 years ago, but is frowned upon nowadays.

The location of such a directory depends on its lifetime and contents:

* If its lifetime is shorter than the process duration, that is, if
  it is no longer relevant once the process terminated, it should be
  under $TMPDIR, not under $HOME. If TMPDIR is not set, use /tmp
  instead of $TMPDIR.

* Otherwise:

  - If it contains configuration that the user should be able to
    modify (either via a text editor or via an appropriate program),
    it should be $HOME/.config/<program>/ (or $XDG_CONFIG_HOME/<program>/
    if that environment variable is set [1]).

  - If it contains data that may be deleted and is persisted only to
    provide a speedup, it should be $HOME/.cache/<program>/
    (or $XDG_CACHE_HOME/<program>/ if that environment variable is set [1]).

  - If it contains other data, that is neither configuration nor
    deletable (for example, log files, user spell-check customizations,
    and many more), it should be $HOME/.local/share/<program>/
    (or $XDG_DATA_HOME/<program>/ if thet environment variable is set [1]).

The purpose of this specification [1] is that users
  - have an easy way of erasing all caches,
  - can have all their user data on an USB stick, needing to set only 3 or 4
    environment variables.

That's the de-facto standard nowadays.

Bruno

[1] https://specifications.freedesktop.org/basedir/latest/
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.