XDG desktop settings for M OS distros / Настройки рабочего окружения дистрибутивов М ОС
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
mos-xdg/scripts/test.sh

22 lines
1.2 KiB

3 years ago
#!/bin/sh
set -x
set -e
trap 'if [ $? != 0 ]; then echo "ERROR!!!"; fi' EXIT
MOS_XDG_TESTING=1
MOS_XDG_CONFIG_DIR=/etc/xdg/mos
MOS_XDG_DATA_DIR=/usr/share/mos
3 years ago
export PATH="$PWD:$PATH"
. ./mos-xdg-env
3 years ago
# $XDG_CONFIG_DIRS
[ "$(_mk_xdg_dirs /etc/xdg /etc/xdg /etc/kf5/xdg "$MOS_XDG_CONFIG_DIR")" = $MOS_XDG_CONFIG_DIR:/etc/xdg ]
[ "$(_mk_xdg_dirs /etc/foo /etc/xdg /etc/kf5/xdg "$MOS_XDG_CONFIG_DIR")" = /etc/foo:$MOS_XDG_CONFIG_DIR:/etc/xdg ]
[ "$(_mk_xdg_dirs /etc/foo:/etc/xdg /etc/xdg /etc/kf5/xdg "$MOS_XDG_CONFIG_DIR")" = /etc/foo:$MOS_XDG_CONFIG_DIR:/etc/xdg ]
[ "$(_mk_xdg_dirs /etc/foo:$MOS_XDG_CONFIG_DIR:/etc/kf5/xdg:/etc/xdg /etc/xdg /etc/kf5/xdg "$MOS_XDG_CONFIG_DIR")" = /etc/foo:$MOS_XDG_CONFIG_DIR:/etc/kf5/xdg:/etc/xdg ]
[ "$(_mk_xdg_dirs /home/user/.config/kdedefaults:/etc/kf5/xdg:/etc/xdg /etc/xdg /etc/kf5/xdg "$MOS_XDG_CONFIG_DIR")" = /home/user/.config/kdedefaults:$MOS_XDG_CONFIG_DIR:/etc/kf5/xdg:/etc/xdg ]
3 years ago
# https://bugzilla.altlinux.org/show_bug.cgi?id=41566
[ "$(_mk_xdg_dirs "" /etc/xdg /etc/kf5/xdg "$MOS_XDG_CONFIG_DIR")" = $MOS_XDG_CONFIG_DIR:/etc/kf5/xdg:/etc/xdg ]
3 years ago
# $XDG_DATA_DIRS
[ "$(_mk_xdg_dirs /usr/share /usr/share /usr/share/kf5 "$MOS_XDG_DATA_DIR")" = $MOS_XDG_DATA_DIR:/usr/share ]