mrrl-logincaps

MRRL version of logincaps
git clone https://ccx.te2000.cz/git/mrrl-logincaps
Log | Files | Refs

commit 18ec179a74c76e8d2776afcb77a33031c957b549
parent b07b0ace57aaa7770a9c3127e3424e65df8194f2
Author: ccx <ccx@te2000.cz>
Date:   Thu, 21 Mar 2024 02:56:07 +0000

Look for s6-rc database in XDG-compliant directory

Diffstat:
Mhome/loginexec | 5+++--
1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/home/loginexec b/home/loginexec @@ -1,8 +1,9 @@ #!/bin/zsh -l set -x mkdir -p /run/user/$UID/ssh-master && chmod 700 /run/user/$UID/ssh-master -if [[ -e $HOME/s6-rc/user/compiled && ! -e /run/user/$UID/s6-rc ]]; then - if ! s6-rc-init -c $HOME/s6-rc/user/compiled -l /run/user/$UID/s6-rc -d /run/user/$UID/service; then +local db_current=${XDG_DATA_HOME:-$HOME/.local/share}/current +if [[ -e ${db_current:P} && ! -e /run/user/$UID/s6-rc ]]; then + if ! s6-rc-init -c ${db_current:P} -l /run/user/$UID/s6-rc -d /run/user/$UID/service; then echo >&2 'Warning: s6-rc failed to start!' fi fi