From 91b15fcc7301275064d390604d364aa422a642af Mon Sep 17 00:00:00 2001 From: Alexandre Pujol Date: Thu, 1 Apr 2021 16:22:09 +0100 Subject: [PATCH] Add extended XDG directories definition. --- profiles/tunables/xdg-user-dirs.d/complete | 49 ++++++++++++++++++++++ 1 file changed, 49 insertions(+) create mode 100644 profiles/tunables/xdg-user-dirs.d/complete diff --git a/profiles/tunables/xdg-user-dirs.d/complete b/profiles/tunables/xdg-user-dirs.d/complete new file mode 100644 index 00000000..1f798d80 --- /dev/null +++ b/profiles/tunables/xdg-user-dirs.d/complete @@ -0,0 +1,49 @@ +# apparmor.d - Full set of apparmor profiles +# Extended XDG directories definition +# Copyright (C) 2021 Alexandre Pujol +# SPDX-License-Identifier: GPL-2.0-only + +# To allow extended personalisation by the user without breaking everything. +# All apparmor profiles should always use the variables defined here. + +# XDG_*_DIR variables are relative pathnames from the user home directory. +# user_*_dirs variables are absolute path. + +# The default values +# @{XDG_DESKTOP_DIR}="Desktop" +# @{XDG_DOWNLOAD_DIR}="Downloads" +# @{XDG_TEMPLATES_DIR}="Templates" +# @{XDG_PUBLICSHARE_DIR}="Public" +# @{XDG_DOCUMENTS_DIR}="Documents" +# @{XDG_MUSIC_DIR}="Music" +# @{XDG_PICTURES_DIR}="Pictures" +# @{XDG_VIDEOS_DIR}="Videos" +# @{user_share_dirs}=@{HOME}/.local/share + +# Extra user personal directories +@{XDG_PROJECTS_DIR}="Projects" +@{XDG_BOOKS_DIR}="Books" +@{XDG_WALLPAPERS_DIR}="Pictures/Wallpapers" +@{XDG_VM_DIR}=".vm" + +# User personal keyrings +@{XDG_SSH_DIR}=".ssh" +@{XDG_GPG_DIR}=".gnupg" + +# Definition of local user configuration directories +@{XDG_CACHE_HOME}=".cache" +@{XDG_CONFIG_HOME}=".config" +@{XDG_DATA_HOME}=".local/share" +@{XDG_BIN_HOME}=".local/bin" +@{XDG_LIB_HOME}=".local/lib" + +# Full path of the user configuration directories +@{user_cache_dirs}=@{HOME}/@{XDG_CACHE_HOME} +@{user_config_dirs}=@{HOME}/@{XDG_CONFIG_HOME} +@{user_bin_dirs}=@{HOME}/@{XDG_BIN_HOME} +@{user_lib_dirs}=@{HOME}/@{XDG_LIB_HOME} + +# User build directories and output +@{user_build_dirs}="/tmp/build" +@{user_pkg_dirs}="/tmp/pkg/" +@{user_tmp_dirs}="/run/user/1000" "/tmp"