I'm trying to play an .mp4 video file in vlc through Terminal in Mac OS X 10.6.4. When I enter the command, VLC starts but doesn't do anything, and the file starts playing in QuickTime Player, the default video player.

I want the file to open in vlc not QuickTime Player, but I don't want to have to configure vlc as the default video player. Which extra switches does this command need to play video files?

Here's the Terminal command I'm using:

open /Users/sandy/Documents/vlc/VlC.app/Contents/MacOS/VLC /Users/sandy/videoFiles/myVideo.mp4

You don't have the correct argument sequence. As per the manpage:

open [-e] [-t] [-f] [-W] [-R] [-n] [-g] [-h] [-b bundle_identifier] [-a application] file ... [--args arg1 ...]

In your command, you're telling open to open VLC, then to open your video, but not to open the video with VLC.

Instead, use:

open -a /Users/sandy/Documents/vlc/VlC.app /Users/sandy/videoFiles/myVideo.mp4

Note that you don't need to descend into the package contents with open.

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.