24 lines
359 B
Bash
Executable File
24 lines
359 B
Bash
Executable File
#!/bin/sh
|
|
|
|
# check for the disks
|
|
if [ "$(lsusb | grep -c 152d:1561)" -ne 1 ]; then
|
|
printf "is the disk drive connected?\n"
|
|
exit 1
|
|
fi
|
|
|
|
if [ "$(lsblk | grep -Ec '^sdb|^sdc')" -ne 2 ]; then
|
|
printf "are the disk drives available\n"
|
|
exit 1
|
|
fi
|
|
|
|
mount_raid_array
|
|
|
|
cd ~/mount/annex
|
|
git annex sync
|
|
git annex get .
|
|
cd /tmp
|
|
|
|
mount_raid_array umount
|
|
|
|
printf "done\n"
|