Mac/Linux/Unix: Record internet radios to listen them later with streamripper

I wanted to record Internet radios to listen to it later on (say at work), with fixed length files, and the name of the radio in the file names. I was not totally convinced by Radio Lover.

Here is my solution based on streamripper, an open-source tool.

You will need to save the following script as “ripstream-fake-trackinfo”:


DELAY=1200 # in seconds

START=`date +%s`

# Force a track change at the beginning
echo "."
sleep 1

while true ; do
        NOW=`date +%s`
        if [[ $COUNT -ne $LASTCOUNT ]] ; then
                DATESTR=`date +%Y-%m-%d-%H-%M-%S`
        echo "ARTIST=$1";
            echo "TITLE=$DATESTR";
            echo "."
        sleep 1

The following script is “ripstream” :



cd ~/Desktop/Downloads/Radio || exit 1

streamripper $1 -D "%S-%d" -E "$TRACKINFO $2"

And here is how to call it :

ripstream URL Name

Keywords : record mp3 stream fixed length internet radio

This entry was posted in Uncategorized. Bookmark the permalink.

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s