respect specified destination dir when cleaning old files

clean_old_theme should not touch anywhere outside of the specified
destination dir. This tweaks this to use the dest variable if it
is defined.
This commit is contained in:
lectrode
2024-06-30 16:35:06 -06:00
parent 49cd09c680
commit 2db7716213

View File

@@ -286,7 +286,7 @@ clean_old_theme() {
for theme in '' '-purple' '-pink' '-red' '-orange' '-yellow' '-green' '-teal' '-grey'; do
for scheme in '' '-nord' '-dracula'; do
for color in '' '-light' '-dark'; do
rm -rf "${DEST_DIR}/${THEME_NAME}${theme}${scheme}${color}"
rm -rf "${dest:-${DEST_DIR}}/${THEME_NAME}${theme}${scheme}${color}"
done
done
done