fabianmichael / kirby-markdown-field

Super-sophisticated markdown editor for Kirby 3, community built.
Other
160 stars 14 forks source link

3.8 compatibility #158

Closed afbora closed 1 year ago

afbora commented 1 year ago
fabianmichael commented 1 year ago

@afbora

The installed version of the Markdown field plugin is not compatible with Kirby 3.8.0-rc.2

I’ve updated the main branch yesterday and activated the plugin. I could not find any issues with 3.8.0-rc.1. As the version contraint has been removed, is there still al problem or am I getting this wrong in some way?

Plugin name doesn't match with getkirby.com (community/markdown-field vs fabianmichael/markdown-field)

This is because the ownership of the plugin has changed a few times. When Kirby 3.0 was released, @sylvainjule and me developed most of it together, based inspired by the work of @medienbaecker and @JonasDoebertin. Because of that, the composer name k-community/markdown-field. I could update the name and also register that on Packagist if it causes any trouble with the update check otherweise. Does that make sense or am I missing something?

afbora commented 1 year ago

I’ve updated the main branch yesterday and activated the plugin. I could not find any issues with 3.8.0-rc.1. As the version contraint has been removed, is there still al problem or am I getting this wrong in some way?

Because I tested 2.0.2 not main branch. Now I've tested the main branch and seems works great 👍

This is because the ownership of the plugin has changed a few times. When Kirby 3.0 was released, @sylvainjule and me developed most of it together, based inspired by the work of @medienbaecker and @JonasDoebertin. Because of that, the composer name k-community/markdown-field. I could update the name and also register that on Packagist if it causes any trouble with the update check otherweise. Does that make sense or am I missing something?

I think, needed @lukasbestle thoughts here.

fabianmichael commented 1 year ago

Because I tested 2.0.2 not main branch. Now I've tested the main branch and seems works great 👍

If I no one complains over the next days, I would risk to release a 2.0.3 update. Unfortunately, I did not use TypeScript and automated testing back then … but let’s hope for the best. ;-) There are a few other things that I have already though about, i.e. using UUIDs for links while displaying a human-readable preview in the editor. But that should not hold back a compatiblity update.

lukasbestle commented 1 year ago

It's not necessary to change the Composer package name (although you can do that if you want). What's important to the update check is the plugin name that you provide to Kirby::plugin() in your index.php.

fabianmichael commented 1 year ago

@lukasbestle So it’s probably less error-prone to update the name in the index.php, because otherwise everyone who uses the plugin would have to update their dependencies, right?

lukasbestle commented 1 year ago

The name change in index.php and composer.json is completely independent from each other. Composer only cares about composer.json and the update check only cares about index.php.

I guess in the long run it makes sense to keep both consistent. Changing the Composer package name however is indeed more tricky as it is not possible to change it in Packagist without creating a new package with the new name and marking the old package as abandoned.

fabianmichael commented 1 year ago

@lukasbestle @afbora I’ve updated the plugin name in index.php to match composer.json for the sake of simplicity. Thanks for your explanations. :-)

afbora commented 1 year ago

@fabianmichael Maybe we didn't fully explain. Plugin name should be same with getkirby.com uri. Currently like following:

Also we need to change the name fabianmichael in getkirby.com to k-community. Do you want me to do?

afbora commented 1 year ago

Important things:

fabianmichael commented 1 year ago

Ah okay, I’ll change it all to fabianmichael/markdown-field then. But just realized the awful consequences because all setting prefixes have to be updated for all installations. But there’s not much that I can do about it, so ¯\_(ツ)_/¯

afbora commented 1 year ago

Yes, there are two options.

  1. Using fabianmichael instead of k-community in this repo.
  2. Keep using it as k-community in this repo, but use k-community instead of fabianmichael on getkirby.com
fabianmichael commented 1 year ago

Since I got another plugin that is not yet listed on getkirby.com (https://github.com/fabianmichael/kirby-meta) that also uses the fabianmichael namespace, I’ll take a second look and will update both to a unified namespace, probably fabianmichael or fm.

fabianmichael commented 1 year ago

@afbora @lukasbestle Okay, namespace and plugin name are updated to fabianmichael/markdown-field. Closing this now. :-)