I'm trying to create a ScriptRunner Script Plugin, and have more-or-less followed these guidelines (I'm using later Jira and ScriptRunner versions and hope that I've edited the pom file correctly).
I have some scripts in my plugin (they're definitely in the JAR) and I'm hoping that installing the plugin will add a Script Root and make these scripts visible. However, this doesn't seem to be happening, and I'm not seeing the scripts or the script roots in the Source Editor.
I'm wondering whether I need to do something to somehow declare the existence of these scripts, e.g., add something to scriptrunner.yaml, scripts.properties or atlassian-plugin.xml.
I'd be very grateful for any suggestions. I can give more details, but thought I'd keep it simple to start with.
--- UPDATE #1 (2021-11-15) ---
I've looked into this a bit further by going back to the guidelines referenced above and creating two different builds (links are to branches in my fork):
- (just-change-to-bbf) Making minimal changes (just changing names to use org.broadband_forum, although I should have just used com.example)
- (remove-all-scripts) Removing all the scripts (removing all the Groovy classes and scripts)
When I run #just-change-to-bbf, I see the various scripts, e.g., script.groovy:

But I'm almost sure that these are coming from the server directory, not from the plugin. If I uninstall the plugin they're still there:

If I run #remove-all-scripts, as expected I don't see the scripts:

But if I install the #just-change-to-bbf plugin (which should contain the scripts, yes?) I still don't see them:
The #just-change-to-bbf JAR file (unzipped into a temporary directory) looks like this:
hana:temp% unzip ../target/scriptrunner-plugin-just-change-to-bbf-1.0.0-SNAPSHOT.jar
Archive: ../target/scriptrunner-plugin-just-change-to-bbf-1.0.0-SNAPSHOT.jar
creating: META-INF/
inflating: META-INF/MANIFEST.MF
creating: css/
creating: images/
creating: js/
creating: org/
creating: org/broadband_forum/
creating: org/broadband_forum/scriptedfields/
creating: org/broadband_forum/main/
creating: org/broadband_forum/main/webfragments/
creating: org/broadband_forum/main/scriptedfields/
creating: org/broadband_forum/main/behaviours/
creating: org/broadband_forum/main/scripts/
creating: org/broadband_forum/main/listeners/
creating: org/broadband_forum/main/rest/
creating: META-INF/plugin-components/
creating: META-INF/spring/
inflating: css/scriptrunner-plugin-min.css
inflating: css/scriptrunner-plugin.css
inflating: images/pluginIcon.png
inflating: images/pluginLogo.png
inflating: js/scriptrunner-plugin.js
inflating: js/scriptrunner-plugin-min.js
inflating: scriptrunner-plugin.properties
inflating: org/broadband_forum/scriptedfields/CreateScriptFieldUpgradeTask.class
inflating: org/broadband_forum/scriptedfields/AbstractUpgradeTask.groovy
inflating: org/broadband_forum/scriptedfields/AbstractUpgradeTask.class
inflating: org/broadband_forum/scriptedfields/CreateScriptFieldUpgradeTask.groovy
inflating: org/broadband_forum/main/webfragments/webfragments.class
inflating: org/broadband_forum/main/webfragments/webfragments.groovy
inflating: org/broadband_forum/main/scriptedfields/scriptedfield.class
inflating: org/broadband_forum/main/scriptedfields/scriptedfield.groovy
inflating: org/broadband_forum/main/behaviours/behaviour.class
inflating: org/broadband_forum/main/behaviours/behaviour.groovy
inflating: org/broadband_forum/main/scripts/script.groovy
inflating: org/broadband_forum/main/scripts/script.class
inflating: org/broadband_forum/main/listeners/listener.class
inflating: org/broadband_forum/main/listeners/listener.groovy
inflating: org/broadband_forum/main/rest/rest.class
inflating: org/broadband_forum/main/rest/rest.groovy
inflating: org/broadband_forum/main/rest/rest$_run_closure1.class
inflating: scriptrunner.yaml
inflating: META-INF/plugin-components/component
inflating: META-INF/plugin-components/exports
inflating: META-INF/spring/plugin-context.xml
inflating: atlassian-plugin.xml
creating: META-INF/maven/
creating: META-INF/maven/org.broadband_forum.scriptrunner/
creating: META-INF/maven/org.broadband_forum.scriptrunner/scriptrunner-plugin-just-change-to-bbf/
inflating: META-INF/maven/org.broadband_forum.scriptrunner/scriptrunner-plugin-just-change-to-bbf/pom.xml
inflating: META-INF/maven/org.broadband_forum.scriptrunner/scriptrunner-plugin-just-change-to-bbf/pom.properties
Why aren't I seeing the scripts? I would think that the plugin:// script root URL would access the entire plugin tree, but is this wrong? Does it maybe "serve" a sub-hierarchy?
This is an old ScriptRunner version, and the version that I currently use doesn't give this list of script roots. Why is this (I rather like it)?