Develop Built-in Plugins
Built-in plugins ships together with OneDev, and requires OneDev source code to develop.
First follow this guide to set up OneDev development environment
Add a new Maven module using Maven archetype below:
Here:
- Plugin name should follow the name convention
server-plugin-xxx
- Package should follow the name convention
io.onedev.server.plugin.xxx
- group id should always be
io.onedev
- artifact id should follow the name convention
server-plugin-xxx
- Plugin name should follow the name convention
Open terminal and run
mvn install
in the new plugin module directory to install the plugin into local Maven repository$ cd ~/Projects/onedev/server/server-plugin/server-plugin-myplugin
$ mvn installEdit
pom.xml
of moduleserver-product
to add dependency to the new plugin:Click
Reload All Projects
andGenerate Sources and Update Folder for All Projects
from maven tool window:Your plugin should be taking effect now, you may add functionalities to it and run the configuration to see it in action