After setting his Mac to automatically import downloaded music to iTunes, my friend asked me whether a similar method could be used for adding movies to iTunes. He wanted to customize his system so that after he clicks the download link, he doesn’t have to do anything and the movies will automatically find their way to his iPod, ready to accompany him on his long trips.
I told him that the basic setup is the same, but we would need to find a way to automatically convert the movies before adding them to iTunes as not all movie formats are supported by iDevices.
A few experiments later, I found two ways to achieve the goal: the easy way and the geeky way. I’m still struggling with the scripts and command lines within the geeky way, but the easy way is easy enough for anybody to do. If you want to try, here are the steps to do it.
Setting Up The Download Location
The first step is setting up all related applications – like browsers, torrent clients and download managers – to save downloaded movies to a specific folder. Let’s name the folder “To Be Converted” or something similar. Later on, we will set up the automation to convert every movie file inside this folder to iPod-friendly format and send them to iTunes.
As discussed in the previous article, setting a specific download location for specific type of files could be done easily in Transmission by setting up a group.
However, please make sure to set Transmission to keep incomplete downloads in a separate location so that the system will only convert complete movies.
For applications with no download filter feature, we can use “Folder Action” (or other housekeeping apps) to monitor download folders and move every movie file to the “To Be Converted” folder.
To do that, open Automator and choose “Folder Action“.
Set Folder Action to monitor the “Downloads” folder (or any other location where you usually save your downloads). Then drag and drop “Filter Finder Items” action from the library and set it to filter every movie file. Add another action to move the filtered items.
Finally, save the Folder Action by going to the “File – Save” menu.
Setting Up Automatic Movie Conversion
After making sure that all future downloaded movies will go to one folder, it’s time to set up the automatic movie conversion.
We are going to use Automator one more time. Create another Folder Action and set it to monitor the “To Be Converted” folder.
Drag and drop the “Export Movies” action from the library.
Choose “iPod” for the file format and “Automatically Add to iTunes” as the destination folder. If you want to keep your hard drive from bloating, it’s also possible to delete the original movie file after the conversion process is done.
Save the Folder Action and the automation system is done.
Looking At Another Possibility
I’ve tested the whole setup and everything worked fine. However, there are several things that you should be aware of.
First, the system relies on QuickTime for the conversion, so it will only work for a few specific video formats. From my experiments, the system will not convert WMV and FLV, but has no problem with AVI, MOV, and MP4.
Second, even though the conversion time depends on the length of the movie and the power of the machine, it’s slower compared to Handbrake.
So why not use Handbrake instead? It supports more video formats and does everything faster. The answer is simply because you can’t automate the conversion process using Handbrake, at least not with the GUI version. But there’s hope. Automation is possible using HandbrakeCLI. This is the command line version of Handbrake and – as the name suggests – everything is executed using the command line.
I’m currently trying to make sense of all the commands and to apply them. I’ll definitely be back with a more powerful setup. Meanwhile, I think this easy version of automation will do just fine for normal usage.
As always, thoughts and opinions are welcomed via the comments below.