Author Topic: MusicBee Patch Update (Virtual Tag Notification)  (Read 5632 times)

Mayibongwe

  • Sr. Member
  • ****
  • Posts: 1733
  • Heal The World
Hi Guys,

This is for the bunch that likes to keep up to date with Steven's updates.
I know there's already a feature intended for this in the preferences screen > general > application > check for updates on startup ...
But I've never seen the fruits of its labour - not sure when or where that notification is supposed to reflect (never seen one in the past 3 years of my MB use).

Download Link

 


Installation

-   Download the "mb_MusicBeePatchUpdate_v1.1" zip file and select it from MusicBee -> Edit -> Preferences -> Plugins -> Add Plugin.
-   In the same preferences screen, go to the Tags (1) tab > Define New Tags ... set up a virtual tag as follows: $IsNewVersionAvailable()
-   Then display that virtual tag in the Track Information panel (this is optional, you can display it wherever you like).
-   Note that the virtual tag will only return a value when a new patch is available. When you are on the latest version, nothing will display.
-   Also note that this is for notification purposes only. The plugin won't download the update for you.


How to Get a Direct Download Link

-   Create a virtual tag as follows:   $GetNewVersion()   which will be a clickable link if displayed on the track info panel.
-   To make it clickable,  go to Preferences  > Tags (2) > configure fields ... > change your virtual tag data type from "string" to "url"


How to Modify the Message Returned

-    $IsNull($IsNewVersionAvailable(),"Already on the latest version",$IsNewVersionAvailable())
     To display something else when there isn't a newer version.

-    $RxReplace($IsNewVersionAvailable(),"^.*$","New Version Out Now")
     To override the message when an update is available
Last Edit: November 03, 2024, 04:39:45 PM by Mayibongwe
Strength and Honour (2025)

hiccup

  • Hero Member
  • *****
  • Posts: 9106
Ooh, this is very clever Mayibongwe.

Thanks for creating and sharing.
This probably deserves a sticky in Tips & Tricks and in the FAQ.

Two comments:
I don't think the described step to extract the file after downloading is necessary?
I pointed 'add plugin' at the .zip and it worked fine.

About the '... days old' indication:
That looks a bit off.
I ran the plugin on a quite recent 3.6.9059 P install, and the virtual tag says "New patch available!  (337 days old)", while the used version is from (I think) a couple of weeks ago, and the latest patch update is from today?
 

Mayibongwe

  • Sr. Member
  • ****
  • Posts: 1733
  • Heal The World
I don't think the described step to extract the file after downloading is necessary?
I pointed 'add plugin' at the .zip and it worked fine.
Quite right. That's a copy & paste on the readme I've been reusing over and over since the first plugin I worked on.
Otherwise, yes, selecting the .zip directly is sufficient - I'll tidy up that read me.

About the '... days old' indication: That looks a bit off.
I ran the plugin on a quite recent 3.6.9059 P install, and the virtual tag says "New patch available!  (337 days old)", while the used version is from (I think) a couple of weeks ago, and the latest patch update is from today?
Perhaps the creation date of the MusicBee.exe I'm making the comparison with is a bit flawed.
I initially worked with the modification date which I thought threw things off on my side.

Can you confirm the creation and modification date of your .exe?
Strength and Honour (2025)

hiccup

  • Hero Member
  • *****
  • Posts: 9106
And two more things:

1.
I am not sure about this, but I seem to recall that it is now possible to create such a virtual tag that contains a clickable link?
If that is indeed the case, there could be link to the "index of patches" page?
Or to some post or FAQ that explains how to exactly update MusicBee?

2.
It should probably have some warning that this is useless for 'Store' versions?

Mayibongwe

  • Sr. Member
  • ****
  • Posts: 1733
  • Heal The World
Both good points. Let me see how to work 1.
Strength and Honour (2025)

hiccup

  • Hero Member
  • *****
  • Posts: 9106
Perhaps the creation date of the MusicBee.exe I'm making the comparison with is a bit flawed.
I initially worked with the modification date which I thought threw things off on my side.
Can you confirm the creation and modification date of your .exe?
Ah yes, that must be it:



PS
Off-topic, but I notice my screenshots like this one now come out slightly enlarged and a bit fuzzy/unsharp.
I don't think I have changed anything.
Could someone confirm it is looking like that for them too?
If it does not and it looks pixel-perfect sharp for you, perhaps it is something my browser suddenly does?
Last Edit: November 03, 2024, 02:06:11 PM by hiccup

Mayibongwe

  • Sr. Member
  • ****
  • Posts: 1733
  • Heal The World
Ah yes, that must be it:
And the modification date, that's much more recent?

____
can't comment much on the screenshot size myself.
I recently changed laptops and have a much larger screen size than before (it will be a while before I stop seeing everything large-sized like the moon).
Strength and Honour (2025)

hiccup

  • Hero Member
  • *****
  • Posts: 9106
And the modification date, that's much more recent?
Yeah, if I am not mistaken that will be the date when Steven created that updated version of MusicBee.exe.

One point of warning: I believe that I have tweaked the way my Windows install handles these date created/modified by means of a registry edit.
So someone should probably confirm they are seeing the same that I am seeing here.

hiccup

  • Hero Member
  • *****
  • Posts: 9106
I also notice that on the Plugins page, there is currently no ''Support forum' button that directs to the forum topic.

hiccup

  • Hero Member
  • *****
  • Posts: 9106
can't comment much on the screenshot size myself.
I recently changed laptops and have a much larger screen size than before (it will be a while before I stop seeing everything large-sized like the moon).
If you have your dpi set to 100% you should be able to see it.

For me this one is fuzzy and slightly enlarged:



And clicking this one links to the pixel-perfect original:



So if the two look identical for you, I suspect there must be something going on caused by some Firefox update.
Last Edit: November 03, 2024, 03:16:09 PM by hiccup

Mayibongwe

  • Sr. Member
  • ****
  • Posts: 1733
  • Heal The World
A new version has been uploaded (v.1.1)

#1   if you're using the store version, the virtual tag should return a value like "MusicBee store version not supported".
        there is no direct way to determine the type of MB edition (the .exe does not specify the letter on the file attributes, and the API does not share this as far as I can see).
  
        so instead, I've queried the MusicBee ErrorLog for a version type (which phred can back me up as the sure way to determine a user's install type).
        the day we get a user without a populated error log, Steven's quest will be complete!

#2   there is now an additional function call to get a direct link to the patch site $GetNewVersion()
        although this will have to be a separate virtual tag if you plan to make the tag clickable in the track info panel.
        see instructions on how to do this on the start post.

#3   the date comparison is now made against the last modified date on the MusicBee.exe
Strength and Honour (2025)

Mayibongwe

  • Sr. Member
  • ****
  • Posts: 1733
  • Heal The World
I also notice that on the Plugins page, there is currently no ''Support forum' button that directs to the forum topic.
This is now fixed and points to this thread - thanks.

...but I seem to recall that it is now possible to create such a virtual tag that contains a clickable link?
You've got a good memory: https://getmusicbee.com/forum/index.php?topic=36011.0
I also needed to remind myself how one does that (I'll post some instructions on the start post just now)
Strength and Honour (2025)

Mayibongwe

  • Sr. Member
  • ****
  • Posts: 1733
  • Heal The World
So if the two look identical for you, I suspect there must be something going on caused by some Firefox update.
Yep, on a 100% DPI setting here.
And those two are identical on my G.Chrome. I've opened each of them on a new tab (to ensure I'm viewing the full size) and there's no difference at all.
Strength and Honour (2025)

hiccup

  • Hero Member
  • *****
  • Posts: 9106
Yep, on a 100% DPI setting here.
And those two are identical on my G.Chrome. I've opened each of them on a new tab (to ensure I'm viewing the full size) and there's no difference at all.
Thanks for confirming.
I removed and re-installed Firefox, and that didn't solve it.
Then I changed Windows dpi settings a couple of times and did some restarts, and finally I am back to pixel-perfect.
So the culprit was Windows, not Firefox.
My apologies for adding this off-topic stuff to your thread.

hiccup

  • Hero Member
  • *****
  • Posts: 9106
#3   the date comparison is now made against the last modified date on the MusicBee.exe
Yep, I now get '14' days, which seems correct.
So that indicates how old the version is that the user is currently running.
But it doesn't say when the latest patch update was released.
That might be relevant information too?
Or perhaps it could show both dates, so that it shows how far the user is behind?

something along the lines of:
'date of your current version: …'
'date of the latest patch update: …'
Last Edit: November 03, 2024, 07:22:20 PM by hiccup