From f7e8532b178055257dbbab23f440d27064a14a98 Mon Sep 17 00:00:00 2001 From: Luca Di Maio Date: Sat, 3 Feb 2024 11:11:00 +0100 Subject: [PATCH] init: fix skel permissions, Fix #1144, Fix #1081 Signed-off-by: Luca Di Maio --- distrobox-init | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/distrobox-init b/distrobox-init index 009486327f..282093bc94 100755 --- a/distrobox-init +++ b/distrobox-init @@ -2002,10 +2002,9 @@ if [ -n "${DISTROBOX_HOST_HOME-}" ] && [ -d "/etc/skel" ]; then if [ ! -f "${container_user_home}/${file_path_for_home:+"${file_path_for_home}"/}${base_file_name}" ] && [ ! -L "${container_user_home}/${file_path_for_home:+"${file_path_for_home}"/}${base_file_name}" ]; then cp "${skel_file}" "${container_user_home}/${file_path_for_home:+"${file_path_for_home}"/}${base_file_name}" - chown "${container_user_uid}":"${container_user_gid}" \ - "${container_user_home}/${file_path_for_home:+"${file_path_for_home}"/}${base_file_name}" fi done + chown -R "${container_user_uid}":"${container_user_gid}" "${container_user_home}/${file_path_for_home:+"${file_path_for_home}"/}" fi ###############################################################################