Use shell arrays. They are extremely useful if you want to form strings using escape sequences and let them be literally printed. In addition, security.
roption=(
-a
--recursive
--progress
--exclude='class'
--delete
--exclude='exclude'
--exclude='.svn'
--exclude='.metadata'
--exclude='*.class'
)
rsync "${roption[@]}" /media/CORSAIR/workspace ~/
You can even add to them:
if [ "$VERBOSE" -ne 0 ]; then
roption+=(--verbose)
fi
source
share