diff options
Diffstat (limited to 'playlist-get')
-rwxr-xr-x | playlist-get | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/playlist-get b/playlist-get index 170f6be..6c4dd51 100755 --- a/playlist-get +++ b/playlist-get @@ -21,6 +21,12 @@ if [ -z "$PLAYLIST" ]; then ls $PLAYLISTS fi + echo "Examples:" + echo "" + echo "$BASENAME ambient adb" + echo "$BASENAME groove /media/usb" + echo "$BASENAME funk remote-repository" + exit 1 elif [ ! -f "$PLAYLISTS/$PLAYLIST.m3u" ]; then echo "No such playlist $PLAYLISTS/$PLAYLIST.m3u" @@ -40,6 +46,10 @@ elif [ "$BASENAME" == "playlist-copy" ]; then # Force absolute path DEST="`cd $DEST && pwd`" + elif [ "$DEST" == "adb" ]; then + APP="adb" + action="adb" + DEST="/storage/emulated/0/Music" else DEST="--to $DEST" action="copy" @@ -59,6 +69,9 @@ cat $PLAYLISTS/$PLAYLIST.m3u | while read file; do $APP $action "$file" "$DEST$prefix" elif [ "$action" == "get" ]; then $APP $action "$file" + elif [ "$action" == "adb" ]; then + prefix="/$(dirname "$file")" + $APP push "$file" "$DEST$prefix" else $APP $action "$file" $DEST fi |