diff options
Diffstat (limited to 'playlist-get')
-rwxr-xr-x | playlist-get | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/playlist-get b/playlist-get index 8990933..7a688d9 100755 --- a/playlist-get +++ b/playlist-get @@ -25,11 +25,17 @@ elif [ ! -f "$PLAYLISTS/$PLAYLIST.m3u" ]; then exit 1 fi +if [ "$BASENAME" == "playlist-drop" ]; then + command="drop" +else + command="get" +fi + echo "Getting files from $PLAYLISTS/$PLAYLIST.m3u..." cat $PLAYLISTS/$PLAYLIST.m3u | while read file; do dir="$(dirname "$file")" base="$(basename "$file")" - ( cd "$MEDIA/$dir" && git annex get "$base" ) + ( cd "$MEDIA/$dir" && git annex $command "$base" ) done |