#!/bin/bash [ -z $1 ] && echo "usage: $0 " && exit 1 BASE=`basename $1 .ram` DIR=`dirname $1` RM=$DIR/$BASE.rm exec mplayer -dumpstream -dumpfile $RM -playlist $1