Sha256: a20156e00fa24ee12fc094f974123f41fc0e11767a2fa7f72cb28265af74bc50
Contents?: true
Size: 479 Bytes
Versions: 2
Compression:
Stored size: 479 Bytes
Contents
require 'bundler' Bundler.setup :default require 'pp' require 'logger' require 'mpd_client' MPDClient.log = Logger.new($stderr) client = MPDClient.new client.connect('localhost', 6600) # delete all songs from the current playlist, except for the firts ten client.delete([10,]) # move the first three songs after the fifth number in the playlist client.move([0, 3], 5) # print songs form 5 to 10 client.playlistinfo([5, 10]).each{ |s| puts "#{s['artist']} - #{s['title']}"}
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
mpd_client-0.0.6 | examples/range.rb |
mpd_client-0.0.5 | examples/range.rb |