Commit 3d5ae40f659adc5d800552e73e05264f06cbb13c

Anton Maminov 2015-03-18T14:26:14

update examples

diff --git a/examples/Gemfile b/examples/Gemfile
index fc20a81..56026b6 100644
--- a/examples/Gemfile
+++ b/examples/Gemfile
@@ -1,3 +1,3 @@
-source :rubygems
+source 'https://rubygems.org'
 
 gem 'mpd_client', :path => '../'
diff --git a/examples/range.rb b/examples/range.rb
index 50deebe..3041a08 100644
--- a/examples/range.rb
+++ b/examples/range.rb
@@ -14,6 +14,7 @@ client.connect('localhost', 6600)
 client.delete([10,])
 
 # move the first three songs after the fifth number in the playlist
-client.move([0, 3], 69)
+client.move([0, 3], 5)
 
-pp client.playlistinfo([69, 71])
+# print songs form 5 to 10
+client.playlistinfo([5, 10]).each{ |s| puts "#{s['artist']} - #{s['title']}"}
diff --git a/examples/stickers.rb b/examples/stickers.rb
index b56d58f..8f39a1f 100644
--- a/examples/stickers.rb
+++ b/examples/stickers.rb
@@ -14,7 +14,7 @@ MPDClient.log = Logger.new($stderr)
 client = MPDClient.new
 
 # Connecting to the server
-client.connect('/var/run/mpd/socket')
+client.connect('/run/mpd/socket')
 
 puts "MPD version: #{client.mpd_version}"
 puts "mpd_client version: #{MPDClient::VERSION}"