|
|
@@ -40,16 +40,18 @@ fi
|
|
|
"${SYNC_BIN}" TV 5
|
|
|
"${SYNC_BIN}" YouTube 50
|
|
|
|
|
|
-# If iPhoto is available, copy to Bitcasa
|
|
|
-MOUNTED=0
|
|
|
-if [ ! -d /Volumes/iPhoto ]; then
|
|
|
- MOUNTED=1
|
|
|
- hdiutil attach -readonly /mnt/media/Pictures/iPhoto.sparsebundle >/dev/null 2>&1
|
|
|
-fi
|
|
|
-if [ -d /Volumes/iPhoto ]; then
|
|
|
- BASE_LOCAL="/Volumes/iPhoto" "${SYNC_BIN}" Shared.photolibrary 1000
|
|
|
- if [ $MOUNTED -gt 0 ]; then
|
|
|
- hdiutil detach /Volumes/iPhoto >/dev/null 2>&1
|
|
|
+# If iPhoto is available back it up too
|
|
|
+if compgen -c hdiutil > /dev/null 2>&1; then
|
|
|
+ MOUNTED=0
|
|
|
+ if [ ! -d /Volumes/iPhoto ]; then
|
|
|
+ MOUNTED=1
|
|
|
+ hdiutil attach -readonly /mnt/media/Pictures/iPhoto.sparsebundle >/dev/null 2>&1
|
|
|
+ fi
|
|
|
+ if [ -d /Volumes/iPhoto ]; then
|
|
|
+ BASE_LOCAL="/Volumes/iPhoto" "${SYNC_BIN}" Shared.photolibrary 1000
|
|
|
+ if [ $MOUNTED -gt 0 ]; then
|
|
|
+ hdiutil detach /Volumes/iPhoto >/dev/null 2>&1
|
|
|
+ fi
|
|
|
fi
|
|
|
fi
|
|
|
|