diff --git a/filesystem/05-home-dir.post b/filesystem/05-home-dir.post index 553cebda..9aa39761 100644 --- a/filesystem/05-home-dir.post +++ b/filesystem/05-home-dir.post @@ -227,14 +227,16 @@ maybe_create_home () echo echo "They will never be overwritten nor automatically updated." echo + local cur_pwd="$PWD" cd /etc/skel || echo "WARNING: Failed attempt to cd into /etc/skel!" local f= /usr/bin/find . -type f | while read f; do - local fDest=${f#.} + local fDest="${f#.}" if [ ! -e "${HOME}${fDest}" -a ! -L "${HOME}${fDest}" ]; then - /usr/bin/install -D -p -v "${f}" "${HOME}/${fDest}" + /usr/bin/install -D -p -v "${f}" "${HOME}${fDest}" fi done + cd "${cur_pwd}" else echo "${HOME} could not be created." { [ -d "${TEMP}" ] && HOME="${TEMP}"; } ||