You are not logged in.

#26 2012-09-25 23:10:07

*nixer
Member
Registered: 2011-11-11
Posts: 56

Re: [Solved] Mplayer - Is this possible without a GUI?

kokoko3k wrote:

@*nixer: i just checked and it works here...

I could have sworn I tried every method from the file manager, and console... But after running your script from the cli, I got messages similar to this.

Playing /tmp/./filename1.flv.
File not found: '/tmp/./filename1.flv'
Failed to open /tmp/./filename1.flv.


Playing /tmp/./filename2.mp3.
File not found: '/tmp/./filename2.mp3'
Failed to open /tmp/./filename2.mp3.

Etc.

After changing the line pls=/tmp/$RANDOM.pls to pls=$RANDOM.pls, it worked exactly as described from the console. For some reason though, it wouldn't run when launched from the file manager. After setting a custom Thunar action to call the bash file from xterm (xterm -e script_name), I noticed this message at the beginning of the terminal output.

find: `/run/media/root/Data1/Music': No such file or directory
find: `Tracks': No such file or directory

That was it. The script wouldn't work with path names that have spaces. I restored the above changed line, renamed the directories containing the media files to remove any spaces, and voila... it works great from both cli & fm.

Thanks a million. smile

EDIT;
I'm sure everyone is tired of this already, but simply add quotation marks around this command in the script.

$(dirname "$1")

TO

"$(dirname "$1")"

This solves the issues with directory names containing spaces.

Last edited by *nixer (2012-09-25 23:48:10)

Offline

#27 2012-09-26 10:28:29

kokoko3k
Member
Registered: 2008-11-14
Posts: 1,438

Re: [Solved] Mplayer - Is this possible without a GUI?

Sorry, my fault smile

Offline

#28 2012-09-26 13:49:18

x33a
Forum Moderator
Registered: 2009-08-15
Posts: 3,242
Website

Re: [Solved] Mplayer - Is this possible without a GUI?

I am late to the party, but maybe you can also try nvlc? It's an ncurses frontend to vlc.

Last edited by x33a (2012-09-26 13:49:32)

Offline

Board footer

Powered by FluxBB