Author Topic: [PLUGIN] last.fm playcount / tagcorrection / loved-status fetcher  (Read 13067 times)

laite

  • Jr. Member
  • **
  • Posts: 96
    • View Profile
    • Gmusicbrowser-plugins by laite
Hi. About four months ago I made a little script (http://forum.gmusicbrowser.org/index.php?topic=335.0) for fetching playcounts from last.fm. It was downright ugly, so I finally got myself up to create a proper plugin for this.

Screenshot:

** README & DOWNLOAD **

You can check README and download plugin from https://github.com/laite/gmusicbrowser-plugins/tree/master/lastfm_pcget

Installation happens as usual: copy lastfm_pcget.pm to ~/.config/gmusicbrowser/plugins (OR for all users: /usr/share/gmusicbrowser/plugins), restart gmusicbrowser and lastfm_pcGet should appear in preferences->plugins.
« Last Edit: May 29, 2012, 09:14:44 by laite »

laite

  • Jr. Member
  • **
  • Posts: 96
    • View Profile
    • Gmusicbrowser-plugins by laite
Re: [PLUGIN] last.fm playcount fetcher
« Reply #1 on: July 22, 2011, 17:56:43 »
Hi everybody!

I added an option to get tagcorrections from last.fm, please check README from github to understand how it works.

All bugs, misbehavings and suggestions are welcome, so please tell if you have some.

yaouennec

  • Newbie
  • *
  • Posts: 7
    • View Profile
Re: [PLUGIN] last.fm playcount / tagcorrection fetcher
« Reply #2 on: January 31, 2012, 17:28:21 »
Hi
I'm interesested in your plugin, but i don't manage to see it in the plugin list.
I've downloaded, copied it, restart gmb but i don't see it in the list.

laite

  • Jr. Member
  • **
  • Posts: 96
    • View Profile
    • Gmusicbrowser-plugins by laite
Re: [PLUGIN] last.fm playcount / tagcorrection fetcher
« Reply #3 on: January 31, 2012, 18:06:08 »
Hi
I'm interesested in your plugin, but i don't manage to see it in the plugin list.
I've downloaded, copied it, restart gmb but i don't see it in the list.

Hi. Where exactly did you copy plugin (aka file 'lastfm_pcget.pm')? What version of gmusicbrowser are you using? Besides these points, I really can't think of anything but perhaps a corrupted download?

Hm, I think I'll change the opening post a bit, since a better place to copy the file would be in ~/.config/gmusicbrowser/plugins/ so there's no need to sudo it. Should work from either place, though.

yaouennec

  • Newbie
  • *
  • Posts: 7
    • View Profile
Re: [PLUGIN] last.fm playcount / tagcorrection fetcher
« Reply #4 on: January 31, 2012, 18:27:18 »
I use the git version. v 1.1.7.1
And i copy it in ~/.gmusicbrowser/plugin/

laite

  • Jr. Member
  • **
  • Posts: 96
    • View Profile
    • Gmusicbrowser-plugins by laite
Re: [PLUGIN] last.fm playcount / tagcorrection fetcher
« Reply #5 on: January 31, 2012, 21:36:31 »
And i copy it in ~/.gmusicbrowser/plugin/

Ok, the folder where you should put plugin must be _exactly_ like: ~/.config/gmusicbrowser/plugins/

If you have used gmusicbrowser, you should have ~/.config/gmusicbrowser folder already present, not necessarily 'plugins'-folder in there, but just create it if it's not already.

yaouennec

  • Newbie
  • *
  • Posts: 7
    • View Profile
Re: [PLUGIN] last.fm playcount / tagcorrection fetcher
« Reply #6 on: January 31, 2012, 22:00:39 »
i just update the git and i'm now in 1.1.8

I put a copy (lastfm_pcget.pm)  where you say, and i let another one in ~/.gmusicbrowser/plugins/, but it still the same.

laite

  • Jr. Member
  • **
  • Posts: 96
    • View Profile
    • Gmusicbrowser-plugins by laite
Re: [PLUGIN] last.fm playcount / tagcorrection fetcher
« Reply #7 on: February 01, 2012, 00:22:01 »
i just update the git and i'm now in 1.1.8

I put a copy (lastfm_pcget.pm)  where you say, and i let another one in ~/.gmusicbrowser/plugins/, but it still the same.

Hm. I'm afraid I really don't know what's the problem. I'm using plugin currently with gmb 1.1.8 and having no problems  with it :-\

Did you try already copying it to folder where all other plugins are ( /usr/share/gmusicbrowser/plugins , there should be about a dozen .pm-files already)?

Perhaps you could try some other plugin and see if it works, like https://raw.github.com/laite/gmusicbrowser-plugins/master/albumrandom/albumrandom.pm (save that as albumrandom.pm and try including it in gmb same way as lastfm_pcget.pm).

yaouennec

  • Newbie
  • *
  • Posts: 7
    • View Profile
Re : [PLUGIN] last.fm playcount / tagcorrection fetcher
« Reply #8 on: February 01, 2012, 03:20:51 »
I've just install it, like you say, and i can see albumrandom in the list !

No plugin found in /home/yves/.config/gmusicbrowser/plugins/lastfm_pcget.pm, maybe it uses an old format

begin of the plugin downloaded :
Quote


<!DOCTYPE html>
<html>
  <head>
    <meta charset='utf-8'>
and the end :
   
Quote
  </body>
</html>

1380 lines
« Last Edit: February 01, 2012, 17:58:03 by yaouennec »

Quentin Sculo

  • Administrator
  • Hero Member
  • *****
  • Posts: 1082
    • View Profile
Re: [PLUGIN] last.fm playcount / tagcorrection fetcher
« Reply #9 on: February 01, 2012, 17:39:40 »
Your file inlcudes extra html, it shouldn't. Use this link instead :
https://raw.github.com/laite/gmusicbrowser-plugins/master/lastfm_pcget/lastfm_pcget.pm

yaouennec

  • Newbie
  • *
  • Posts: 7
    • View Profile
Re : [PLUGIN] last.fm playcount / tagcorrection fetcher
« Reply #10 on: February 01, 2012, 18:15:39 »
thanks a lot
it's ok now

roaje

  • Newbie
  • *
  • Posts: 2
    • View Profile
Re: [PLUGIN] last.fm playcount / tagcorrection fetcher
« Reply #11 on: May 26, 2012, 00:59:56 »
Hey i don't know if this is the proper thread to ask this, but a really nice feature would be to have a love button somewhere on the interface - im not sure if its an easy task to add it somewhere on the main window or maybe just have a keyboard shortcut, it just sucks having to login to the last.fm site :P

And thanks for a really excellent jukebox and for making this plug-in!  :D

laite

  • Jr. Member
  • **
  • Posts: 96
    • View Profile
    • Gmusicbrowser-plugins by laite
Re: [PLUGIN] last.fm playcount / tagcorrection fetcher
« Reply #12 on: May 26, 2012, 12:03:06 »
Hey i don't know if this is the proper thread to ask this, but a really nice feature would be to have a love button somewhere on the interface - im not sure if its an easy task to add it somewhere on the main window or maybe just have a keyboard shortcut, it just sucks having to login to the last.fm site :P

Hi, adding love-button should be pretty easy, I'll talk to Quentin about it in the IRC and see what we come up with. This was discussed before a long time ago, but I've already forgotten why it didn't get implemented then  :D

mgrubert

  • Sr. Member
  • ****
  • Posts: 369
    • View Profile
Re : [PLUGIN] last.fm playcount / tagcorrection fetcher
« Reply #13 on: May 26, 2012, 13:09:42 »
Yes : it would be nice.


laite

  • Jr. Member
  • **
  • Posts: 96
    • View Profile
    • Gmusicbrowser-plugins by laite
Re: [PLUGIN] last.fm playcount / tagcorrection fetcher
« Reply #14 on: May 28, 2012, 14:59:43 »
Hey i don't know if this is the proper thread to ask this, but a really nice feature would be to have a love button somewhere on the interface

Well, ain't this your lucky day!  :D

There now is a button for loving (and unloving!) tracks, see images below. Due to last.fm user must 'give permission' in last.fm page before he/she can love/unlove tracks from gmb.

Button will appear to your layout if you have 'Extrabuttons' item on it, otherwise you have to add item called 'lastfmLoveButton' manually. Pics are also in git, to install copy them to /usr/share/gmusicbrowser/pix/THEMEYOUAREUSING/ (I suppose they should also work from .config/gmusicbrowser/pix/, but for some reason they didn't for me (any ideas, quentin?). You can obviously replace them whit whatever you like if you're not happy with them :)

On the first click of the love button configuration is asked, do what the helpful dialogs tell you and everything should be fine. Left-clicking button loves, right-clicking unloves track.

To install new features, just grab plugin from the link in opening post and replace old version with it.

If anything goes wrong, please tell me and I'll look into it. You can find me here or at IRC: laite @ #gmusicbrowser (freenode)

Oh, and one more thing: I included an option to 'sync' last.fm loved status' to a local label, you can enable this in preferences. Similar to playcount, it is checked only from currently playing song and label is added or removed accordingly.

-
thanks,
laite
« Last Edit: May 28, 2012, 15:06:04 by laite »