Patch by Matt Madia: Use "set -o errexit" to error out when a command failed.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@35151 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
@@ -1,4 +1,5 @@
|
|||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
|
set -o errexit
|
||||||
|
|
||||||
# The first argument is the shell script that initializes the variables:
|
# The first argument is the shell script that initializes the variables:
|
||||||
# sourceDir
|
# sourceDir
|
||||||
@@ -122,19 +123,19 @@ if [ $isImage ]; then
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
if [ $isVMwareImage ]; then
|
if [ $isVMwareImage ]; then
|
||||||
$vmdkimage -h 64k $imageFlags "$imagePath" || exit 1
|
$vmdkimage -h 64k $imageFlags "$imagePath"
|
||||||
else
|
else
|
||||||
$createImage $imageFlags "$imagePath" || exit 1
|
$createImage $imageFlags "$imagePath"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
$bfsShell --initialize $imageOffsetFlags "$imagePath" \
|
$bfsShell --initialize $imageOffsetFlags "$imagePath" \
|
||||||
"$imageLabel" "block_size 2048" || exit 1
|
"$imageLabel" "block_size 2048"
|
||||||
$makebootable $imageOffsetFlags "$imagePath"
|
$makebootable $imageOffsetFlags "$imagePath"
|
||||||
fi
|
fi
|
||||||
$bfsShell -n $imageOffsetFlags "$imagePath" > /dev/null &
|
$bfsShell -n $imageOffsetFlags "$imagePath" > /dev/null &
|
||||||
sleep 1
|
sleep 1
|
||||||
# bail out, if mounting fails
|
# bail out, if mounting fails
|
||||||
$cd . || exit 1
|
$cd .
|
||||||
fi
|
fi
|
||||||
|
|
||||||
echo "Populating image ..."
|
echo "Populating image ..."
|
||||||
|
|||||||
Reference in New Issue
Block a user