Quote:
Originally Posted by PatrickBaer
mplayer does indeed a good job so far. But there's something else:
I want to record a webradio show every night from 11pm to midnight.
I can only think of mplayer ... &; sleep 3600; kill -TERM %1
Somebody have more elegant approach?
|
Fill in the APP_PARA variable and use this script with cron:
Code:
#! /bin/sh
APP_NAME=mplayer
APP_PARA=
APP_CMD="$APP_NAME $APP_PARA"
APP_PID="pgrep $APP_NAME \| head -1"
AT_PARA=midnight
AT_CMD="at $AT_PARA"
$APP_CMD &
echo "kill $($APP_PID)" | $AT_CMD