From cff98f977c207fe86b99927a8810a250fa5fd807 Mon Sep 17 00:00:00 2001 From: Jan Weitzel Date: Fri, 9 Sep 2011 12:24:33 +0200 Subject: ask before cleaning complett BSP ask user to avoid Arggghh after accidentally cleaning the complete BSP Skip asking with "--force" or "--quiet" option. Signed-off-by: Jan Weitzel Signed-off-by: Michael Olbrich --- bin/ptxdist | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/bin/ptxdist b/bin/ptxdist index f60767ae6..8d2dea2f3 100755 --- a/bin/ptxdist +++ b/bin/ptxdist @@ -913,6 +913,14 @@ clean() { return fi + if [ ! -n "${PTX_FORCE}${PTXDIST_QUIET}" ]; then + read -e -p "really clean all? [y/N] " r + case "${r}" in + y|Y) ;; + *) exit 1 ;; + esac + fi + echo echo "${PTXDIST_LOG_PROMPT}removing build directories..." for dir in "${BUILDDIR}" "${CROSS_BUILDDIR}" "${KLIBC_BUILDDIR}" "${HOST_BUILDDIR}"; do -- cgit v1.2.3