HackerOne users: Testing against this community violates our program's Terms of Service and will result in your bounty being denied.

Any plugin conversion tool available/necessary for Vanilla 2.5?

2»

Comments

  • @R_J said:
    ... and when we are already talking about naming conventions (something I really love), may I ask another question?

    From looking at newer plugins I got the impression that the convention now seems to be "/plugins/newfunctionality/NewFunctionalityPlugin.php". Is that correct?

    That's a good question.

    As far as I can tell, everyone on the team but Todd & Ryan does /plugins/newfunctionality/class.newfunctionality.plugin.php. Todd does what you did above, and Ryan does /plugins/newfunctionality/newfunctionalityplugin.php basically combining the two. I hadn't even noticed the divergence. I'll have a word with them.

  • R_JR_J Admin

    @Linc said:

    @R_J said:
    ... and when we are already talking about naming conventions (something I really love), may I ask another question?

    From looking at newer plugins I got the impression that the convention now seems to be "/plugins/newfunctionality/NewFunctionalityPlugin.php". Is that correct?

    That's a good question.

    As far as I can tell, everyone on the team but Todd & Ryan does /plugins/newfunctionality/class.newfunctionality.plugin.php. Todd does what you did above, and Ryan does /plugins/newfunctionality/newfunctionalityplugin.php basically combining the two. I hadn't even noticed the divergence. I'll have a word with them.

    Did you have found the time to raise this question?

    Since Vanillas coding standard is moving towards PSR standards, I think it is logical to adopt the PSR-4 standard: "The terminating class name corresponds to a file name ending in .php." which wouldbe the same standard as it is already used in /library/Garden & /library/Vanilla resulting in SomeFeaturePlugin.php. I would prefer that.

  • LincLinc Admin
    edited March 2018

    @R_J said:
    Did you have found the time to raise this question?

    I slid it into a conversation not 10 minutes ago. The verdict is full PSR-4 (SomeNamePlugin.php) from now on. We're not retroactively updating old files at this time, primarily because I think it will cause widespread issues with open source updates not deleting the renamed files and therefore isn't worth it yet.

  • Todd has also requested that folder + key be formatted in dashed-case.

    We'll update the coding standards soon.

Sign In or Register to comment.