commit b85f2e57197db46bbc5fa6ff223c88905d90bcdf
parent dc86a4c73b82e27091d2363efed1b1884f8cc992
Author: parazyd <parazyd@dyne.org>
Date: Thu, 21 Apr 2016 12:47:30 +0200
error checks, one var less
Diffstat:
2 files changed, 7 insertions(+), 5 deletions(-)
diff --git a/arm/init-arm b/arm/init-arm
@@ -22,11 +22,11 @@
init() {
fn init $*
- distro="$1"
+ os="$1"
armdev="$2"
- req=(distro armdev)
+ req=(os armdev)
ckreq || {
- error "No distro or device specified"
+ error "Missing arguments. Please retry."
return 1
}
@@ -43,7 +43,10 @@ init() {
)
arm_build_device=${arm_map[$armdev]}
+ common="$R/arm/profiles/common-${os}"
+
+ [[ -f $common ]] || { error "No valid distro specified"; return 1 }
+ [[-f $arm_build_device ]] || { error "No valid device specified"; return 1 }
- common="$R/arm/profiles/common-${distro}"
source ${arm_build_device}
}
diff --git a/arm/profiles/common-devuan b/arm/profiles/common-devuan
@@ -23,7 +23,6 @@
# Common functions for builds
# -- settings --
-os=devuan
release=jessie
section=main
version=alpha4