]> git.netwichtig.de Git - user/henk/code/ruby/rbot.git/commitdiff
last.fm plugin: first argument of taste comparison now optional
authorRaine Virta <rane@kapsi.fi>
Thu, 12 Feb 2009 23:54:16 +0000 (01:54 +0200)
committerGiuseppe Bilotta <giuseppe.bilotta@gmail.com>
Sat, 14 Feb 2009 21:24:17 +0000 (22:24 +0100)
data/rbot/plugins/lastfm.rb

index c112c16775888cd2cd02ed3e66854e5717c0f64a..9b508f012597cc2bd40d2741713ed9a2c7d4131d 100644 (file)
@@ -86,7 +86,7 @@ class LastFmPlugin < Plugin
     when :who
       _("lastfm who [<nick>] => show who <nick> is at last.fm. if <nick> is empty, show who you are at lastfm.")
     when :compare
-      _("lastfm compare <nick1> <nick2> => show musical taste compatibility between nick1 and nick2.")
+      _("lastfm compare [<nick1>] <nick2> => show musical taste compatibility between nick1 (or user if omitted) and nick2")
     else
       _("lastfm [<user>] => show your or <user>'s now playing track at lastfm. np [<user>] => same as 'lastfm'. other topics: events, artist, album, track, now, set, who, compare")
     end
@@ -406,7 +406,8 @@ plugin.map 'lastfm set username :who', :action => :set_user, :thread => true
 plugin.map 'lastfm set verb *present, *past', :action => :set_verb, :thread => true
 plugin.map 'lastfm who :who', :action => :get_user, :thread => true
 plugin.map 'lastfm who', :action => :get_user, :thread => true
-plugin.map 'lastfm compare :user1 :user2', :action => :tasteometer, :thread => true
+plugin.map 'lastfm compare to :user2', :action => :tasteometer, :thread => true
+plugin.map 'lastfm compare [:user1] [to] :user2', :action => :tasteometer, :thread => true
 plugin.map 'np', :action => :now_playing, :thread => true
 plugin.map "lastfm [user] :action [:user]", :thread => true,
   :requirements => { :action =>