uncomment src deletion

This commit is contained in:
LinuxSquare 2024-04-20 20:04:24 +02:00
parent 90bc34b49d
commit d64d93caca

View file

@ -196,23 +196,23 @@ function build_pkgs() {
for pkg in ${PKGARRAY[@]}; do
local continue=false
# if [[ -d "$BUILD_DIR/$pkg" ]]; then
# message_warning "Directory exists in ${BUILD_DIR}: $pkg"
# while [[ ! "$removepkgdirAns" =~ [Yy] ]]; do
# read -p "$(message_question 'Do you want to remove it? (Y/N): ')" removepkgdirAns
# if [[ "$removepkgdirAns" =~ [Yy] ]]; then
# message_blue_single_arrow "Removing $pkg"
# rm -rf "${BUILD_DIR}/$pkg"
# break
# fi
if [[ -d "$BUILD_DIR/$pkg" ]]; then
message_warning "Directory exists in ${BUILD_DIR}: $pkg"
while [[ ! "$removepkgdirAns" =~ [Yy] ]]; do
read -p "$(message_question 'Do you want to remove it? (Y/N): ')" removepkgdirAns
if [[ "$removepkgdirAns" =~ [Yy] ]]; then
message_blue_single_arrow "Removing $pkg"
rm -rf "${BUILD_DIR}/$pkg"
break
fi
# if [[ "$removepkgdirAns" =~ [Nn] ]]; then
# message_warning "Not removing. Skipping $pkg..."
# continue=true
# break
# fi
# done
# fi
if [[ "$removepkgdirAns" =~ [Nn] ]]; then
message_warning "Not removing. Skipping $pkg..."
continue=true
break
fi
done
fi
if [[ "$continue" == false ]]; then
if [[ ! -d "$BUILD_DIR/$pkg" ]]; then
container_run "git clone $APKBUILD_GIT_REPO_BASE/${pkg}.git /build/$pkg"