Create playlist and music directory set in the configuration file (#3448)
git-svn-id: svn://svn.openwrt.org/openwrt/packages@11159 3c298f89-4303-0410-b956-a3cf2f4a3e73
This commit is contained in:
parent
af3d3a83e4
commit
aacb53d343
@ -3,6 +3,15 @@
|
|||||||
START=93
|
START=93
|
||||||
|
|
||||||
start() {
|
start() {
|
||||||
|
#create mpd directories
|
||||||
|
md=`grep music_directory /etc/mpd.conf | cut -d "\"" -f 2 | sed "s/~/\/root/g"`
|
||||||
|
if [ ! -d $md ]; then
|
||||||
|
mkdir -p $md
|
||||||
|
fi
|
||||||
|
pld=`grep playlist_directory /etc/mpd.conf | cut -d "\"" -f 2 | sed "s/~/\/root/g"`
|
||||||
|
if [ ! -d $pld ]; then
|
||||||
|
mkdir -p $pld
|
||||||
|
fi
|
||||||
#create mpd db
|
#create mpd db
|
||||||
/usr/bin/mpd --stdout --create-db
|
/usr/bin/mpd --stdout --create-db
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user