mirror of
https://github.com/flynx/ImageGrid.git
synced 2025-12-25 20:41:57 +00:00
Compare commits
No commits in common. "23509bacc159ae04a2f682ccf2410ebd6058ff5e" and "21e7bae20598cdc5d9dc7c1126cdb708c9e2552c" have entirely different histories.
23509bacc1
...
21e7bae205
@ -66,10 +66,6 @@ while true ; do
|
|||||||
echo " default: $BASE"
|
echo " default: $BASE"
|
||||||
echo " --rsync use rsync (default)"
|
echo " --rsync use rsync (default)"
|
||||||
echo " --cp use cp"
|
echo " --cp use cp"
|
||||||
if ! [ -z $VERIFY ] ; then
|
|
||||||
echo " --verify toggle copy verification"
|
|
||||||
echo " default: `[[ $SKIP_VERIFY ]] && echo "off" || echo "on"`"
|
|
||||||
fi
|
|
||||||
if ! [ -z $COMPRESSOR ] ; then
|
if ! [ -z $COMPRESSOR ] ; then
|
||||||
echo " --compress toggle archive compression"
|
echo " --compress toggle archive compression"
|
||||||
echo " default: `[[ $COMPRESS ]] && echo "on" || echo "off"`"
|
echo " default: `[[ $COMPRESS ]] && echo "on" || echo "off"`"
|
||||||
@ -112,11 +108,6 @@ while true ; do
|
|||||||
shift
|
shift
|
||||||
break
|
break
|
||||||
;;
|
;;
|
||||||
-verify|--verify)
|
|
||||||
SKIP_VERIFY=`[[ $SKIP_VERIFY ]] && echo "" || echo 1`
|
|
||||||
shift
|
|
||||||
break
|
|
||||||
;;
|
|
||||||
-compress|--compress)
|
-compress|--compress)
|
||||||
COMPRESS=`[[ $COMPRESS ]] && echo "" || echo 1`
|
COMPRESS=`[[ $COMPRESS ]] && echo "" || echo 1`
|
||||||
shift
|
shift
|
||||||
@ -151,31 +142,21 @@ while true ; do
|
|||||||
echo "0) Build after this flash card: `[[ $LAST ]] && echo "yes" || echo "no"`"
|
echo "0) Build after this flash card: `[[ $LAST ]] && echo "yes" || echo "no"`"
|
||||||
fi
|
fi
|
||||||
echo "1) Directoy description is: \"$TITLE\""
|
echo "1) Directoy description is: \"$TITLE\""
|
||||||
|
if [[ ! $DRIVE ]] ; then
|
||||||
|
echo "a-z|name) Type a drive letter, mount name in $BASE or path and start"
|
||||||
|
echo " (paths must start with \"/\", \"./\" or \"[A-Z]:\")"
|
||||||
|
else
|
||||||
echo "a-z|name) Type a drive letter, mount name in $BASE or path and start"
|
echo "a-z|name) Type a drive letter, mount name in $BASE or path and start"
|
||||||
echo " (paths must start with \"/\", \"./\" or \"[A-Z]:\")"
|
echo " (paths must start with \"/\", \"./\" or \"[A-Z]:\")"
|
||||||
if [[ $DRIVE ]] ; then
|
|
||||||
echo "Enter) Copy drive ${DRIVE}"
|
echo "Enter) Copy drive ${DRIVE}"
|
||||||
fi
|
fi
|
||||||
echo "2) Build"
|
echo "2) Build"
|
||||||
|
|
||||||
# dynamic options...
|
|
||||||
i=3
|
|
||||||
OPTION_VERIFICATION=
|
|
||||||
if ! [ -z $VERIFY ] ; then
|
|
||||||
echo "$i) Verification is `[[ $SKIP_VERIFY ]] && echo "off" || echo "on"`"
|
|
||||||
OPTION_VERIFICATION=$i
|
|
||||||
i=$(( i + 1 ))
|
|
||||||
fi
|
|
||||||
|
|
||||||
OPTION_COMPRESSION=
|
|
||||||
if ! [ -z $COMPRESSOR ] ; then
|
if ! [ -z $COMPRESSOR ] ; then
|
||||||
echo "$i) Compresion is `[[ $COMPRESS ]] && echo "on" || echo "off"`"
|
echo "3) Compresion is `[[ $COMPRESS ]] && echo "on" || echo "off"`"
|
||||||
OPTION_COMPRESSION=$i
|
echo "4) Quit"
|
||||||
i=$(( i + 1 ))
|
else
|
||||||
|
echo "3) Quit"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
echo "$i) Quit"
|
|
||||||
OPTION_QUIT=$i
|
|
||||||
read -ep ": " RES
|
read -ep ": " RES
|
||||||
|
|
||||||
# NOTE: we can't use letters here as they will shadow
|
# NOTE: we can't use letters here as they will shadow
|
||||||
@ -208,17 +189,15 @@ while true ; do
|
|||||||
LAST=1
|
LAST=1
|
||||||
break
|
break
|
||||||
;;
|
;;
|
||||||
|
3)
|
||||||
# dynamic option handlers...
|
if ! [ -z $COMPRESSOR ] ; then
|
||||||
"$OPTION_VERIFICATION")
|
|
||||||
SKIP_VERIFY=`[[ ! $SKIP_VERIFY ]] && echo 1 || echo ""`
|
|
||||||
continue
|
|
||||||
;;
|
|
||||||
"$OPTION_COMPRESSION")
|
|
||||||
COMPRESS=`[[ ! $COMPRESS ]] && echo 1 || echo ""`
|
COMPRESS=`[[ ! $COMPRESS ]] && echo 1 || echo ""`
|
||||||
|
else
|
||||||
|
exit
|
||||||
|
fi
|
||||||
continue
|
continue
|
||||||
;;
|
;;
|
||||||
"$OPTION_QUIT")
|
4)
|
||||||
exit
|
exit
|
||||||
;;
|
;;
|
||||||
|
|
||||||
@ -292,7 +271,7 @@ while true ; do
|
|||||||
|
|
||||||
# verify copy...
|
# verify copy...
|
||||||
# XXX make this more generic...
|
# XXX make this more generic...
|
||||||
if ! [ $SKIP_VERIFY ] && ! [ -z $VERIFY ] ; then
|
if ! [ -z $VERIFY ] ; then
|
||||||
echo "Verifying copied files..."
|
echo "Verifying copied files..."
|
||||||
$VERIFY $VERIFYFLAGS ${BASE}${DRIVE}/* "$DIR" \
|
$VERIFY $VERIFYFLAGS ${BASE}${DRIVE}/* "$DIR" \
|
||||||
> >(tee "${DIR}"/verification-err.log)
|
> >(tee "${DIR}"/verification-err.log)
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user