Skip to content

Commit

Permalink
Rename parameter LABEL to MOUNT_POINT
Browse files Browse the repository at this point in the history
"make_ext4fs -a" accepts the mount point, in fact.

Change-Id: I126f5d3a9628d30bdd27cb0e7f6879e479ae5de2
  • Loading branch information
Ying Wang committed Sep 29, 2010
1 parent 57813ea commit 8bdbbe2
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions ext4_utils/mkuserimg.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
function usage() {
cat<<EOT
Usage:
mkuserimg.sh SRC_DIR OUTPUT_FILE EXT_VARIANT LABEL SIZE
mkuserimg.sh SRC_DIR OUTPUT_FILE EXT_VARIANT MOUNT_POINT SIZE
EOT
}

Expand All @@ -24,25 +24,25 @@ fi

OUTPUT_FILE=$2
EXT_VARIANT=$3
LABEL=$4
MOUNT_POINT=$4
SIZE=$5

case $EXT_VARIANT in
ext4) ;;
*) echo "Only ext4 is supported!"; exit 3 ;;
esac

if [ -z $LABEL ]; then
echo "Label is required"
if [ -z $MOUNT_POINT ]; then
echo "Mount point is required"
exit 2
fi

if [ -z $SIZE ]; then
SIZE=128M
fi

echo "make_ext4fs -l $SIZE -a $LABEL $OUTPUT_FILE $SRC_DIR"
make_ext4fs -s -l $SIZE -a $LABEL $OUTPUT_FILE $SRC_DIR
echo "make_ext4fs -l $SIZE -a $MOUNT_POINT $OUTPUT_FILE $SRC_DIR"
make_ext4fs -s -l $SIZE -a $MOUNT_POINT $OUTPUT_FILE $SRC_DIR
if [ $? -ne 0 ]; then
exit 4
fi

0 comments on commit 8bdbbe2

Please sign in to comment.