Commit graph

16 commits

Author SHA1 Message Date
Bruno Victal f74df2ab87
home: services: xdg-base-directories: Deprecate XDG_LOG_HOME.
XDG_LOG_HOME is non-standard and log files should go to XDG_STATE_HOME
according to the XDG Base Directory Specification.

Fixes <https://issues.guix.gnu.org/61809>.

* gnu/home/services/desktop.scm (home-dbus-shepherd-services): Log to XDG_STATE_HOME.
* gnu/home/services/desktop.scm (home-unclutter-shepherd-services): Log to
XDG_STATE_HOME.
* gnu/home/services/mcron.scm (home-mcron-shepherd-services): Ditto.
* gnu/home/services/pm.scm (home-batsignal-shepherd-services): Ditto.
* gnu/home/services/shepherd.scm (launch-shepherd-gexp): Ditto.
* gnu/home/services/xdg.scm
(home-xdg-base-directories-configuration)[log-home]: Deprecate and unset default value.
(home-xdg-base-directories-environment-variables-service)
(ensure-xdg-base-dirs-on-activation): Handle field deprecation.
(home-xdg-base-directories-service-type): Update description.

Co-authored-by: Andrew Tropin <andrew@trop.in>
Signed-off-by: Andrew Tropin <andrew@trop.in>
2023-06-15 13:19:29 +04:00
Bruno Victal 5c893787be
home: xdg-base-directories: Set correct value for XDG_STATE_HOME.
XDG Base Directory Specification 0.8 officially introduces the
XDG_STATE_HOME environment variable.

Fixes <https://issues.guix.gnu.org/issue/61809>.

* gnu/home/services/xdg.scm
(home-xdg-base-directories-configuration)[state-home]: Set default value
according to spec.  Update field documentation.
(home-xdg-base-directories-service-type): Update service description.

Signed-off-by: Andrew Tropin <andrew@trop.in>
2023-04-07 09:07:32 +04:00
Andrew Tropin dd4eee5581
home: xdg: Add with-imported-modules to xdg activation script.
Without it activation doesn't work when called in clean environment.

* gnu/home/services/xdg.scm (ensure-xdg-base-dirs-on-activation): Add
with-imported-modules to xdg activation script.
2022-12-23 11:43:27 +04:00
Andrew Tropin 77ef82ce93
home: xdg: Make it possible to extend user-directories service.
* gnu/home/services/xdg.scm (home-xdg-user-directories-service-type): Make it
possible to override user-directories configuration by extending.
2022-12-19 15:11:40 +04:00
Ludovic Courtès 4c8eea027a
home: services: Use 'match-record' instead of 'match'.
* gnu/home/services/mcron.scm (home-mcron-shepherd-services): Use
'match-record' instead of 'match'.
* gnu/home/services/shells.scm (home-bash-extensions): Likewise.
* gnu/home/services/xdg.scm (serialize-xdg-desktop-entry): Likewise.
2022-12-02 00:02:13 +01:00
Andrew Tropin 7dddf0cc54
home: xdg: Export xdg-base/user-directories getters.
* gnu/home/services/xdg.scm: Export xdg-base/user-directories getters.
2022-12-01 18:56:23 +04:00
Andrew Tropin b57c656f72
home: xdg: Skip mkdir XDG_RUNTIME_DIR in activation script.
* gnu/home/services/xdg.scm (ensure-xdg-base-dirs-on-activation): Skip mkdir
XDG_RUNTIME_DIR in activation script.

Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2022-08-05 15:28:02 +02:00
Andrew Tropin a80edc0d82
home: xdg: Use a single @ instead of @@.
* gnu/home/services/xdg.scm (ensure-xdg-base-dirs-on-activation,
home-xdg-user-directories-files-service): Use single @ intsead of @@.

Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2022-08-05 15:28:02 +02:00
Andrew Tropin 20645d8467
home: Add home-xdg-data-files-service-type.
* gnu/home/services.scm (home-xdg-data-files-service-type): New variable.
* gnu/home/services/symlink-manager.scm (update-symlinks-script): Add a proper
handling for XDG_DATA_HOME value.
* gnu/home/services/xdg.scm (home-xdg-mime-applications-service-type): Use
home-xdg-data-files service.

Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2022-04-08 20:13:48 +02:00
Andrew Tropin 5832d9fb60
home: symlink-manager: Remove appending of leading dot.
* gnu/home/services.scm (xdg-configuration-files-directory): Add leading dot.
* gnu/home/services.scm (xdg-configuration-files-service-type): Change name.
* gnu/home/services/shells.scm (add-shell-profile-file,
zsh-get-configuration-files, add-zsh-dot-configuration,
add-zsh-xdg-configuration, add-bash-configuration): Add leading dots.
* gnu/home/services/symlink-manager.scm (update-symlinks-script): Remove
leading dot.

Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2022-04-08 20:13:45 +02:00
Andrew Tropin 3c149de461
home: Migrate fountutils and xdg modules to xdg-configuration-files.
* gnu/home/services/fontutils.scm (home-fontconfig-service-type): Migrate to
xdg-configuration-files.
* gnu/home/services/xdg.scm (home-xdg-user-directories-service-type,
home-xdg-mime-applications-service-type): Migrate to xdg-configuration-files.

Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2022-03-20 19:02:41 +01:00
Andrew Tropin 60c45fd9fd
home: xdg: Fix xdg-desktop-entry config field serialization.
[[PGP Signed Part:No public key for 2208D20958C1DEB0 created at 2022-03-01T06:09:14+0100 using RSA]]

* gnu/home/services/xdg.scm (serialize-xdg-desktop-entry): Use append instead
of identity to allow multiple alist values.

Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2022-03-01 12:33:07 +01:00
Vagrant Cascadian 57bf76d832
gnu: home: services: Fix typo.
* gnu/home/services/xdg.scm (home-xdg-base-directories-service-type): Fix
  spelling of "convenient".
2021-11-14 17:37:54 -08:00
Oleg Pykhalov fee0bced7f
home: services: configuration: Support file-like objects.
* gnu/home/services/configuration.scm (interpose): Operate only with file-like
objects.
(string-or-gexp?): Delete procedure.
(serialize-string-or-gexp): Rename to 'serialize-file-like'.
(text-config?): Call 'file-like' intead of 'string-or-gexp?'.
* guix/scripts/home/import.scm:
(generate-bash-module+configuration): Don't call slurp-file-gexp.
* gnu/home/services/configuration.scm: Move content ...
* gnu/services/configuration.scm: here.
* gnu/home/services/shells.scm: Delete (gnu home services configuration).
* gnu/home/services/xdg.scm: Same.
* gnu/local.mk: Same.
* tests/guix-home.sh:
Test home-bash-service-type and extension with home-bash-extension.
2021-10-09 19:24:19 +03:00
Oleg Pykhalov 0e8d2df0f1
Move (gnu home-services) to (gnu home services).
* gnu/home-services.scm (%guix-home-root-directory): Replace
gnu/home-services.scm with "gnu/home/services.scm".
Rename to gnu/home/services.scm.
* gnu/local.mk
(GNU_SYSTEM_MODULES): Rename gnu/home-services.scm to gnu/home/services.scm.
* doc/he-config-bare-bones.scm:
Replace (gnu home-services) with (gnu home services).
* gnu/home.scm: Same.
* gnu/home/services/fontutils.scm: Same.
* gnu/home/services/mcron.scm: Same.
* gnu/home/services/shells.scm: Same.
* gnu/home/services/shepherd.scm: Same.
* gnu/home/services/symlink-manager.scm: Same.
* gnu/home/services/xdg.scm: Same.
* guix/scripts/home.scm: Same.
* guix/self.scm: Same.
2021-10-09 19:24:18 +03:00
Oleg Pykhalov ba8ddb3480
gnu: Move (gnu home-services) to (gnu home services).
* gnu/home-services/configuration.scm: Move the content ...
* gnu/home/services/configuration.scm: ... here.
* doc/guix.texi:
Replace (gnu home-services mcron) with (gnu home services mcron).
Replace (gnu home-services) with (gnu home services).
* gnu/home.scm:
Replace (gnu home-services fontutils) with (gnu services fontutils).
Replace (gnu home-services shells) with (gnu home services shells).
Replace (gnu home-services symlink-manager) with
(gnu home services symlink-manager).
Replace (gnu home-services xdg) with (gnu home services xdg).
* gnu/home-services/fontutils.scm: Rename to gnu/services/fontutils.scm.
* gnu/home-services/mcron.scm: Move to gnu/home/services/mcron.scm.
Replace (gnu home-services shepherd) with (gnu home services shepherd).
* gnu/home-services.scm (%service-type-path):
Search home services in "gnu/services".
* gnu/home-services/shells.scm: Replace (gnu home-services configuration) with
(gnu home services configuration).
Rename to gnu/home/services/shells.scm.
Replace (gnu home-services utils) with (gnu home services utils).
* gnu/home-services/shepherd.scm: Move to gnu/home/services/shepherd.scm.
* gnu/home-services/symlink-manager.scm:
Rename to gnu/home/services/symlink-manager.scm.
* gnu/home-services/utils.scm: Rename to gnu/home/services/utils.scm.
* gnu/home-services/xdg.scm: Rename to gnu/home/services/xdg.scm.
* guix/scripts/home/import.scm:
Replace (gnu home-services bash) with (gnu home services bash).
* gnu/home-services.scm: Update documentation string.
* doc/he-config-bare-bones.scm:
Apply new (gnu home-services ...) modules location.
* gnu/local.mk (GNU_SYSTEM_MODULES): Same.
2021-10-08 15:36:18 +03:00
Renamed from gnu/home-services/xdg.scm (Browse further)