Language Selection

English French German Italian Portuguese Spanish

Timed downloads

Filed under
Software
Ubuntu
HowTos

For quite some time I've been looking for a tool to download a list of files (stored in a text file) at a certain time and, if possible, shutdown after completion. Unfortunately there is no know Linux-application that can perform these tasks. Although I recently found one that comes very close. It's called Receiver and you can find it here: http://www.halogenware.com/software/retriever.html. At first sight it suited all my needs, but it failed in downloading files hosted by RapidShare.

Then I got the idea to combine the use of Wget, a terminal download manager, with that of a scheduler. Is used this one: http://www.alarm-clock.pl. Alarm Clock is quite handy because it let's you to perform shell scripts that get initiated at a chosen time. Below you will find a guide how I set it up.

1.Install Alarm Clock (it's in the Ubuntu-repository). Wget is installed by default.

2.If you also own a RapidShare-account, you need to download a cookie to work with Wget by opening a terminal window en type the following. (You need to fill in, of course, your username and password. The cookie will be saved in your home directory under ~/.cookies. If you don't own an account you can skip this step.)

wget \
--save-cookies ~/.cookies/rapidshare \
--post-data "login=USERNAME&password=PASSWORD" \
-O - \
https://ssl.rapidshare.com/cgi-bin/premiumzone.cgi \
> /dev/null

3.You need to change the permissions of the shutdown command, otherwise you will have to provide you password. You can do this by typing this into a terminal.

sudo chmod u+s /sbin/shutdown

4.Open Alarm Clock and choose Birthday & Templates under the Edit menu and choose to enter a new template. I named it Downloads.

5.Fill in the necessary standard settings (they quite speak for themselves so I won't elaborate on this).

6.Then, under the Notifications tab you mark Run command and click on the Preferences button next to it.

7.In the next dialog: choose to run a shell script and type the following in the box below.

cd ~/Downloads
wget --input-file=down.txt --load-cookies=~/.cookies/rapidshare
shutdown -P now

You need to know that in this example I use the file down.txt to store the links I wish to download and ~/Downloads to story everything in. If you prefer other settings, just change the arguments accordingly. Quite obviously you don't have to mention the cookie argument if you don't have one.

That's it. Now only fill a text files with download links and create a new alarm using the template!

By Steven Van Landeghem

More in Tux Machines

Leftovers: Software

  • Ekiga 5 – Progress Report
    Ekiga 5 has progressed a lot lately. OpenHUB is reportin a High Activity for the project. The main reason behind this is that I am again dedicating much of my spare time to the project. Unfortunately, we are again facing a lack of contributions. Most probably (among others) because the project has been silent during several years.
  • Calibre Gets a New Tool to Better Edit eBooks
    The Calibre eBook reader, editor, and library management software has been upgraded to version 2.17 and is now available for download. The developer has only implemented a couple of new features, but it's really worth the update if you are using this application to edit eBooks.
  • More Windows Apps and Games Now Work with Wine 1.7.35, EA's Origin Included
    Wine 1.7.35 has been released and the developers have made a number of improvements for some of the core components and they've added support for more apps and games.

today's howtos

Leftovers: Gaming

  • Dying Light Action Survival Game Coming to Steam January 27
    Dying Light, a modern first-person survival horror game set in a world hit by plague, is now available for pre-purchase on Steam and will be available for download on January 27.
  • Dying Light FPS Has Been Confirmed for Linux, Zombies Galore
    Techland is preparing to launch Dying Light, a new FPS with amazing graphics and hordes of zombies. The developer has revealed that it will also have a Linux version, right from the start.
  • Dying Light Is Now Confirmed For Linux, Bring It On Techland
    Dying Light is now confirmed for Linux thanks to the announcement from the developers on the Steam store itself. The Linux icons show up on the store pages, and the game even has a steam coming soon banner on the home-page. Time to get seriously excited.
  • Star Traders: 4X Empires Strategy Game Now On Linux
  • 5 reasons Valve's Steam Machine dream is still very alive
    Steam Machines? More like has-been machines, am I right? Actually, no: while many people are giving Valve's PC-console-hybrids the cold shoulder, this gamer reckons they'll be worth the wait. I realise that I'm part of a shrinking group still backing Valve's SteamOS-powered Linux boxes, and it's not difficult to see why the hype around them has all but evaporated. Several controller-related delays, U-turns by seemingly committed hardware partners and a lack of news from the top has made many think that Valve is blowing hot air.

Android Leftovers