Advertisement
Guest User

Enhanced Axel Script

a guest
Jul 29th, 2012
199
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Bash 0.92 KB | None | 0 0
  1. #!/bin/bash
  2. # Jumps to the user's desktop folder.
  3. cd $HOME/Desktop
  4. # Create a /home/user/Downloads folder if the user doesn't have one.
  5. if [ ! -e $HOME/Downloads/ ]
  6. then
  7.     mkdir $HOME/Downloads
  8. fi
  9. # Create a log file for the stuff downloaded with Enhanced Axel if it doesn't already exist.
  10. if [ ! -e $HOME/Downloads/Axel\ Download\ Log ]
  11. then
  12.     echo "AXEL DOWNLOAD LOG" > $HOME/Downloads/Axel\ Download\ Log
  13.     echo "Below is a list of URLS for files that Axel has attempted to download." >> $HOME/Downloads/Axel\ Download\ Log
  14. fi
  15. # Add a new line to the log,
  16. echo "" >> $HOME/Downloads/Axel\ Download\ Log
  17. # then add the current date and time at which the file is being downloaded to the log,
  18. date >> $HOME/Downloads/Axel\ Download\ Log
  19. # then add the download URL of that file under the date and time.
  20. echo "$@" >> $HOME/Downloads/Axel\ Download\ Log
  21. # Start Axel and download the file.
  22. xterm -geometry 80x15 -T $@ -e axel -a $@
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement