diff options
Diffstat (limited to 'bin/pkgimg.sh')
-rwxr-xr-x | bin/pkgimg.sh | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/bin/pkgimg.sh b/bin/pkgimg.sh index fdece5a..50b721d 100755 --- a/bin/pkgimg.sh +++ b/bin/pkgimg.sh @@ -26,6 +26,7 @@ source ${LIBDIR}/pkg.sh source ${LIBDIR}/config.sh export PORTSDIR=${PORTSDIR:-${BASEDIR}/ports} +export KEEP_BUILD=${KEEP_BUILD:-0} function main { local manifest=${1:-} @@ -49,7 +50,11 @@ function main { rsync -a ${PORTTMP}/pkg/ ${installbase}/ # Cleanup - rm -rf ${PORTTMP} + if [ "${KEEP_BUILD}" = 0 ]; then + rm -rf ${PORTTMP} + else + linfo "KEEP_BUILD is set. Skipping cleanup of ${port}." + fi done dump_configs |