-echo "List of images used on the source repository:"
-grep -Er '(_system_image:|IMAGE_NAME)' \
---exclude-dir="global-jjb" --exclude-dir="common-packer" \
-| grep ZZCI | awk -F: -e '{print $3}' \
-| grep '\S' | tr -d \'\" | sort -n | uniq \
-| tee "$WORKSPACE/archives/used_image_list.txt"
+echo "INFO: List of images in use on the source repository:"
+grep -Er '(_system_image:|IMAGE_NAME)' \
+ --exclude-dir="global-jjb" --exclude-dir="common-packer" \
+ | grep -oP 'ZZCI\s+.*\d+-\d+\.\d+' | sort -n | uniq \
+ | tee "$WORKSPACE/archives/used_image_list.txt"