make scripts more variable and less dependent on each other

Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
This commit is contained in:
Nico Schottelius 2011-02-07 23:59:21 +01:00
commit 425f2bb71a
4 changed files with 26 additions and 13 deletions

View file

@ -24,14 +24,16 @@
. cdist-config
if [ $# -ne 2 ]; then
__cdist_usage "<outdir> <manifest>"
if [ $# -ne 3 ]; then
__cdist_usage "<target host> <manifest> <outdir>"
fi
set -x
set -aeu
__cdist_output_dir="$1"; shift
export __cdist_target_host="$1"; shift
export __cdist_manifest="$1"; shift
export __cdist_output_dir="$1"; shift
# Ensure binaries exist and are up-to-date
cdist-build-bin