summaryrefslogtreecommitdiff
path: root/adelie-build-cd
diff options
context:
space:
mode:
Diffstat (limited to 'adelie-build-cd')
-rwxr-xr-xadelie-build-cd5
1 files changed, 3 insertions, 2 deletions
diff --git a/adelie-build-cd b/adelie-build-cd
index acd6530..f7d97a0 100755
--- a/adelie-build-cd
+++ b/adelie-build-cd
@@ -74,8 +74,6 @@ usage() {
printf 'Valid phases: clean install initrd iso all\n'
}
-[ -d /etc/apk/cache ] && def_cache=/etc/apk/cache
-
while [ -n "$1" ]; do
case $1 in
-a | --arch)
@@ -119,6 +117,9 @@ while [ -n "$1" ]; do
shift
done
+[ -d /etc/apk/cache ] && def_cache=/etc/apk/cache
+[ -z "${MY_ARCH}" -o "${MY_ARCH}" = "${def_arch}" ] || unset def_cache
+
set -a
readonly ARCH=${MY_ARCH:-$def_arch}
readonly KIND=${MY_KIND:-live}