Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I press ALT+F2 key on my keyboard, and get the launcher HUD up. From there I enter a command as I would in a shell, specifically vlc ~/Music/* -Z. If done from a shell, vlc starts and begins to play music.

However, when done from the launcher, VLC replies:

File reading failed:

VLC could not open the file "/home/[username]/Music/*". (No such file or directory) user Your input can't be opened:

VLC is unable to open the MRL 'file:///home/[username]/Music/%2A'. Check the log for details.

I can't quite figure out what the difference is.

share|improve this question
    
Try vlc --reset –  Mitch Jun 16 '12 at 9:12
    
In my version, 2.0.1, --reset is not a valid option. –  user50849 Jun 16 '12 at 10:27
    
sh -c "vlc ~/Music/* -Z" should work, but there is a bug, so quoting doesn't work. –  elmicha Jun 16 '12 at 11:04
add comment

1 Answer

up vote 0 down vote accepted

Someone else pointed it out, but then removed their answer, so I'll add it again.

The reason this particular command fails is that the launcher doesn't use a shell, which means that VLC is literally trying to load a file named *, as opposed to globbing the star into a file list.

A workaround is to call a shell instead, as elmicha pointed out in a comment. sh -c "vlc ~/Music/* -Z" would do this. This however fails due to a bug, again see elmichas comment.

In this particular case, since VLC will recursively traverse directories, the same result can be achieved with vlc ~/Music, which works fine without a shell, and is much simpler.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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