To keep the project organized and easy to maintain, there are a few rules that should be followed when writing scripts. Here’s a checklist to ensure you follow them.
Don’t worry about getting things perfect, though. When you add your script, we’ll review everything and help you fix any issues should they arise.
All scripts must have at least some minimal details in their PluginDef:
return
statement)Of course, the more complete the PluginDef, the better. This info is also used to generate the script’s documentation, and it’s what’s shown to users when the download the script.
Let’s follow a unified syntax for the file name. Use snake case:
✓ articulation_delete_from_rests.lua
✖ articulationDeleteFromRests.lua
✖ articulationdeletefromrests.lua
✖ articulation-delete-from-rests.lua
✖ articulation_Delete_From_Rests.lua
Each word should take things from general to specific. So anything dealing with articulations should start with “articulations”. Anything with page layout should start with “layout”. See the JW Lua docs for Category Tags to find an good starting place.
There are two ways to do this: