Created
March 8, 2015 10:05
-
-
Save kickbutts/980a8ebf79d40df94f90 to your computer and use it in GitHub Desktop.
Verzeichnis auf USB Stick kopieren
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Die Skript übernimmt als Paratmeter einen Quellpfad und einen Zielpfad (USB-Stick). Der Inhalt des USB-Sticks wird | |
# gelöscht, die Dateien von der Quelle auf den USB-Stick kopiert und der USB-Stick wird ausgeworfen. | |
rm -R $2 | |
# rsync -r -v -P -n $1 $2 # Testlauf ohne kopieren | |
rsync -r -v -P $1 $2 | |
echo "Alle Dateien kopiert!" | |
diff_output= diff -s $1 $2 | |
echo $diff_output | |
umount $2 | |
echo "Stick ausgeworfen" | |
play -n synth 0.1 sin 1000 vol -12 db 2> /dev/null |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment