From 668777e9d55226c00841b19de22342b5cd524ec4 Mon Sep 17 00:00:00 2001 From: Sukru Senli Date: Mon, 29 Aug 2016 11:17:41 +0200 Subject: [PATCH] iop: return directly if no package is given as argument to compile --- iop/scripts/compile.sh | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/iop/scripts/compile.sh b/iop/scripts/compile.sh index f71795a2c..31571e6db 100644 --- a/iop/scripts/compile.sh +++ b/iop/scripts/compile.sh @@ -1,6 +1,11 @@ #!/bin/sh function compile { + if [ -z "$1" ]; then + echo "Please give a valid package as first argument." + return 1 + fi + local cpath pck local lpath=$(find package/ -type l -name $1) local dpath=$(find package/ -type d -name $1) @@ -19,4 +24,4 @@ function compile { fi } -register_command "compile" "Compile a specific package: ./iop compile [0-99]; i.e ./iop netifd 99" +register_command "compile" "Compile a specific package: ./iop compile [0-99]; i.e ./iop compile netifd 99"