Created
March 3, 2023 19:10
-
-
Save catichenor/abdc1f3a221440811b599c26d8fe8220 to your computer and use it in GitHub Desktop.
Wait for a download to complete and send it on its way
This file contains hidden or 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 | |
DLFILE=/path/to/file.zip | |
while [ ! -f $DLFILE ]; | |
do | |
echo "`date --rfc-3339=seconds`: Not here yet" | |
sleep 60 | |
done | |
echo "`date --rfc-3339=seconds`: It's here! Moving..." | |
mv $DLFILE '/path/to/destination/' # Move from download location to final destination | |
echo "`date --rfc-3339=seconds`: Done." |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment