SparkPlug

一月 26, 2008

MPD听网络电台

Filed under: howto,misc — sparkplugcn @ 5:40 am

ShoutCast是我常 听的电台 ,用MPD的话需要稍微的改动一下.

  1. 安装MPC
    emerge -av mpc
  2. 寻找两个执行文件
    gentoo是放在/usr/share/doc/mpc-*里,名字分别为pls-handler.shm3u-handler.sh,如果没有找到这两个文件也可以自己写
    pls-handler.sh

    #!/usr/bin/env sh
    mpc clear
    grep ‘^File[0-9]*’ $1 | sed -e ‘s/^File[0-9]*=//’ | mpc add
    mpc play

    m3u-handler.sh script

    #!/usr/bin/env sh
    mpc clear
    cat $1 | mpc add
    mpc play

  3. 把这两个文件cp到自己的家目录里,然后修改为可执行文件

    chmod u+x m3u-handler.sh
    chmod u+x pls-handler.sh

  4. 修改Fireofx支持
    找开Firefox,在菜单里依次打开”edit-preferences-downloads”,在”file types”里如果已经存在pls和m3u的选项,删除它们.
    然后去ShoutCast或者想去的电台主页,点击想听的电台地址,FX会弹出对话框,选择”open with” 和 “other”,然后连接到上面两个可执行文件,就可以了.

这样就不用再听国内的大力丸的广告了:)Good Luck.

Powered by ScribeFire.

留言 »

还没有评论。

RSS方式的评论。 TrackBack URI

回應文章

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

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / 變更 )

Twitter picture

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

Facebook photo

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

Connecting to %s

Theme: Rubric. Blog at WordPress.com.

Follow

Get every new post delivered to your Inbox.