Skip to content

Commit 8d7970c

Browse files
committed
Clean parent dirs of metadata only in per-user
1 parent 295f1d8 commit 8d7970c

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

lucidglyph.sh

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -242,8 +242,14 @@ set -e
242242
printf "Using uninstaller for version ${C_BOLD}$VERSION${C_RESET}\n"
243243
printf -- "- Removing the installation metadata "
244244
rm -rf "$DEST_SHARED_DIR"
245+
EOF
246+
if $per_user_mode; then
247+
cat <<EOF >> "$DEST_SHARED_DIR/$DEST_UNINSTALL_FILE"
245248
rm -d "$(dirname $DEST_SHARED_DIR)" 2>/dev/null || true
246249
rm -d "$(dirname $(dirname $DEST_SHARED_DIR))" 2>/dev/null || true
250+
EOF
251+
fi
252+
cat <<EOF >> "$DEST_SHARED_DIR/$DEST_UNINSTALL_FILE"
247253
printf "${C_GREEN}Done${C_RESET}\n"
248254
EOF
249255

0 commit comments

Comments
 (0)