Created
January 19, 2020 06:34
-
-
Save umnagendra/2459743fcd2ec2b5b862e7b2b76ea018 to your computer and use it in GitHub Desktop.
Downloader Script
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 | |
| readonly START_NUM=90000 | |
| readonly END_NUM=90300 | |
| function download() { | |
| curl -v -O --fail http://file-cdn.example-cdn.download/jkkkdsfdsggffsdhfghgfdfghgkfjgh/files/${1}.mp4 | |
| rc=$? | |
| if [ ${rc} != 0 ]; then | |
| curl -v -O --fail http://file-cdn.example-cdn.download/jkkkdsfdsggffsdhfghgfdfghgkfjgh/files/${1}.mp4 | |
| fi | |
| } | |
| for i in {$START_NUM..$END_NUM}; do | |
| download ${i} | |
| done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment