Saturday, September 8, 2007

mplayer Skins Problem

On CentOS Linux (and may be others), the easiest way to enable mp3, rm, and other proprietary media support is to install mplayer (you'll need to have the rpmforge repo configured):

# yum install mplayer

I don't like the default skin though. So I installed the mplayer skins package:

# yum install mplayer-skins

After installing the skins package, I opened the mplayer skin browser and bang! No skin except the default one was available!! Research revealed that it's a small, but annoying, bug in the skins package which installs skins in a wrong directory. Check out details of this bug here.

Luckily, the resolution is very simple. All you need to do is execute this:

# cd /usr/share/mplayer/skins/
# ln -s ../Skin/* .

After executing these commands, restart mplayer, launch the skin browser and it should have a fairly long list of available skins listed. That's it!


Saturday, September 1, 2007

Weird Shell Script Errors

Ever ran into weird errors when trying to run a shell script which you believed was 100% correct but the shell won't accept it? I did! Well, it turned out that the bash shell (may be others as well) expects a script file to be saved with UNIX end of line format *not* Windows end of line format.

I am using CentOS 5 with KDE. I use the Kate editor for scripting and programming. Until I started getting insane errors whenever I would try to execute any of my recently developed shell scripts, Kate was configured to save files with Windows end of line format. Now that I changed the end of line format back to UNIX, bash is happy as ever!