Skip to content

Commit

Permalink
Export tar.xz
Browse files Browse the repository at this point in the history
  • Loading branch information
luigifcruz committed May 28, 2021
1 parent 0623e9f commit ed55b41
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions export-image/04-finalise/01-run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,7 @@ mkdir -p "${DEPLOY_DIR}"

rm -f "${DEPLOY_DIR}/${ZIP_FILENAME}${IMG_SUFFIX}.zip"
rm -f "${DEPLOY_DIR}/${IMG_FILENAME}${IMG_SUFFIX}.img"
rm -f "${DEPLOY_DIR}/${ZIP_FILENAME}${IMG_SUFFIX}.img.xz"

mv "$INFO_FILE" "$DEPLOY_DIR/"

Expand All @@ -97,9 +98,9 @@ fi

if [ "${DEPLOY_ZIP}" == "1" ]; then
pushd "${STAGE_WORK_DIR}" > /dev/null
zip "${DEPLOY_DIR}/${ZIP_FILENAME}${IMG_SUFFIX}.zip" \
"$(basename "${IMG_FILE}")"
xz -c "$(basename "${IMG_FILE}")" > "${DEPLOY_DIR}/${ZIP_FILENAME}${IMG_SUFFIX}.img.xz"
popd > /dev/null
rm -f "${DEPLOY_DIR}/${IMG_FILENAME}${IMG_SUFFIX}.img"
else
mv "$IMG_FILE" "$DEPLOY_DIR/"
fi

0 comments on commit ed55b41

Please sign in to comment.