summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xhelpers/lh_clean7
1 files changed, 7 insertions, 0 deletions
diff --git a/helpers/lh_clean b/helpers/lh_clean
index 3fa8fc5..166c867 100755
--- a/helpers/lh_clean
+++ b/helpers/lh_clean
@@ -42,6 +42,13 @@ else
ARGUMENTS="${@}"
fi
+# Avoid cases were users accidentally nuke their config/binary
+if [ ! -d config ] || [ "$(basename ${PWD})" = "config" ]
+then
+ Echo_error "${PWD} is not a good Debian Live working directory to clean."
+ exit 1
+fi
+
for ARGUMENT in ${ARGUMENTS}
do
case "${ARGUMENT}" in