From 1bb108e3268a06c0f3d9627715af4d0300cce905 Mon Sep 17 00:00:00 2001 From: Jeremi Piotrowski Date: Wed, 6 Mar 2024 13:07:35 +0000 Subject: [PATCH] build_image: Allow building sysexts for an existing image by skipping the check for an existing image directory if we're not building an image. This makes './build_image sysext' work. Signed-off-by: Jeremi Piotrowski --- build_image | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build_image b/build_image index 16f5d70622..1e8f2cd024 100755 --- a/build_image +++ b/build_image @@ -126,7 +126,7 @@ if [[ ${skip_test_build_root} -ne 1 ]]; then fi # Handle existing directory. -if [[ -e "${BUILD_DIR}" ]]; then +if [[ -e "${BUILD_DIR}" ]] && [[ "${PROD_IMAGE}" = 1 ]]; then if [[ ${FLAGS_replace} -eq ${FLAGS_TRUE} ]]; then sudo rm -rf "${BUILD_DIR}" else