From 8bc6f485a8a4936f0047c6911c50cac34177cbee Mon Sep 17 00:00:00 2001 From: Stefano Stabellini Date: Tue, 7 Apr 2015 15:46:24 +0000 Subject: [PATCH] Print helpful message when user tries to install but no build is present Signed-off-by: Stefano Stabellini --- CODING_STYLE | 2 +- raise.sh | 6 ++++++ 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/CODING_STYLE b/CODING_STYLE index 8e192f8..ff843a7 100644 --- a/CODING_STYLE +++ b/CODING_STYLE @@ -37,7 +37,7 @@ Prepend _ to the function name if it is a local function. Tests ----- -Use [[ for tests. Do not use test or [. +[[ is preferred for tests. Subshell diff --git a/raise.sh b/raise.sh index b783645..987490a 100755 --- a/raise.sh +++ b/raise.sh @@ -50,6 +50,12 @@ _build() { } _install() { + # need single braces for filename matching expansion + if [ ! -f xen-sytem*rpm ] && [ ! -f xen-system*deb ] + then + echo You need to raise.sh build first. + exit 1 + fi install_package xen-system } -- 2.39.5