In an effort to prove just how simple it is to rip a dvd using free alternatives, as well as needing an excuse to demonstrate the simplicity of using the terminal, I’ve decided that installing the HandBrake command line tool was an excellent starting point.  The first thing we need to do is to download the commandline tool from the HandBrake website. Open up the package by double clicking it.  (Now, there is a graphical interface version for those of you wanting to avoid the terminal, and a quick screencast from our archive about using it here).

Let’s move on with the command line goodness.

  1. Now we open the terminal using spotlight.
  2. Enter the following command to change the location and directory we are in ‘cd /Volumes/HandBrake‘.
  3. Now if we type ‘ls‘ we should see a listing of files and folders available in our current location.
  4. The Handbrake team has pre-compiled the application for us, so we just have to move the file to our terminal applications folder.
  5. This is pretty simple, but can get a little complicated.  Essentially your terminal applications folder is whatever is in your $Path location.  If you’re not sure what that means you might want to read this post.  Basically you’ll be able to access that application from any folder or location in the terminal instead of having to navigate to the folder where the application is residing.
  6. Now we will copy the file to our path location.  Type ‘sudo cp HandBrakeCLI /usr/bin‘.  **Note: there is a space between the I in HandBrakeCLI and the first /.** You should be prompted to input your password, and then the file will be copied to the aformentioned location of ‘/usr/bin’.
  7. We are almost there.  Don’t give up now.  Movie bliss is just around the corner…for free.
  8. So, since we’re going to be copying dvd’s to our machines, we’re going to want to go to the movie folder, so we can store our movies in the appopriate folder.  Type ‘cd ~/Movies‘.  We’re now in the movies folder. Let’s rip a dvd.
  9. We should probably note that there is a list of presets available for ripping your movies into various formats, such as iPods, Apple TV, Normal, PS3, PSP…and a whole slew of other options.  To see these options type ‘HandBrakeCLI –preset-list’ and you will get a listing of your available options.  For instance ‘+ Animation :’ is one option, and ‘+ Quicktime :’ is another. For simplicity’s sake we’re just going to use the Normal preset here.
  10. So, one line of code that is really simple to explain will rip dvd: sudo HandBrakeCLI -i /Volumes/EMPIRE_RECORDS -o EMPIRE_RECORDS.mp4 –preset=”Normal”

I’m going to break it down chunk by chunk here so that you can get a complete grasp of what’s going on.

sudo

The ‘sudo’ means you want to run an application as an administrator.  So, we’re essentially telling the computer run the application with the privileges it needs to do so.  In this case, it’s running the HandBrakeCLI application.  If you’re getting a weird error when you type in sudo, it probably means that you haven’t set the password yet.  You can do this by typing ‘sudo passwd root‘ into the terminal.  You will be prompted for passwords.  Once you get that out of the way, the rest of the tutorial should fall into place for you.

HandBrakeCLI

HandBrakeCLI is the name of the application we’ve installed at the beginning of this post, and it is the application we will be using to rip the dvds we want both now and in the future.

-i

The ‘-i’ in this line means that we will be telling the computer where the input is, which, in this case, is the location of the dvd.

/Volumes/EMPIRE_RECORDS

The ‘/Volumes/EMPIRE_RECORDS’ is the location of the dvd. Every dvd from now until god knows when will be in the /Volumes/ location. It will then be followed up with the name of the dvd. If you really want to cheat here, just look on your desktop at the name of the dvd.  It is case sensitive, so pay attention to this detail or the whole process won’t work.  That also goes for anything in the terminal.

-o EMPIRE_RECORDS.mp4

That’s the letter ‘o’ and not the number zero.  I’m sure you’ve been able to deduce that this stands for output.  We’re telling the machine where the application will be placing the file when it’s done making a copy of it.  If you’ve followed the tutorial step by step until this point, you’ll know that we’re in the “Movies” folder already.  So in this string we’re saying… put EMPIRE_RECORDS.mp4 into our current folder.

–preset=”Normal”

We’ve already talked about this, but let’s have a nice little reminder.  HandBrakeCLI comes with a series of presets for copying your films. We’ve decided on “Normal,” but you can change it any time by using the steps listed above.

More Info

Just in case you really, really, really want to geek out you can get more options by visiting the wiki here.