From bf640caa27e5eb9fb0a0670b643704232d382511 Mon Sep 17 00:00:00 2001 From: Alex Demidoff Date: Wed, 3 Apr 2024 00:02:13 +0000 Subject: [PATCH] PMM-12899 fix the regexp --- build/local/build.sh | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/build/local/build.sh b/build/local/build.sh index ca1ac4a9dd..999691aade 100755 --- a/build/local/build.sh +++ b/build/local/build.sh @@ -186,12 +186,15 @@ init() { if [ -d tmp ]; then echo "Removing stale files and directories..." if [ -d "tmp/pmm-server" ]; then - tmp_files=$(find tmp/pmm-server | grep -v "RPMS") + tmp_files=$(find tmp/pmm-server | grep -v "RPMS" | grep -Ev "^tmp/pmm-server$") tmp_files=($tmp_files) for f in "${tmp_files[@]}"; do rm -rf "$f" done fi + if [ -d "tmp/source/pmm" ]; then + rm -rf tmp/source/pmm + fi fi if [ -f "$LOG_FILE" ]; then echo "Removing the log file..."