From fc87596c925735a13abf578fe724b2b8dac0032e Mon Sep 17 00:00:00 2001 From: =?utf8?q?Jos=C3=A9=20Bollo?= Date: Fri, 23 Jan 2015 18:34:09 +0100 Subject: [PATCH] Improved mode computation MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit This will avoid false errors during image creation. Change-Id: I299899a2c17887ad2fb5b741976f80433306189e Signed-off-by: José Bollo --- src/vconf-buxton-tool.sh | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/src/vconf-buxton-tool.sh b/src/vconf-buxton-tool.sh index 7e3611d..5a738d4 100755 --- a/src/vconf-buxton-tool.sh +++ b/src/vconf-buxton-tool.sh @@ -47,9 +47,23 @@ badargs() { } # -# calls to buxton +# detects buxton mode # buxmode= +if buxtonctl -s check >/dev/null 2>&1 +then + buxmode=-s +elif buxtonctl -d check >/dev/null 2>&1 +then + buxmode=-d +else + error "unable to detect buxton mode" + exit +fi + +# +# calls to buxton +# buxton() { buxtonctl $buxmode -- "$@" } -- 2.7.4