diff options
author | HimbeerserverDE <himbeerserverde@gmail.com> | 2023-12-09 17:59:45 +0100 |
---|---|---|
committer | HimbeerserverDE <himbeerserverde@gmail.com> | 2023-12-09 17:59:45 +0100 |
commit | 15ba78c11f252382a7ca2145587c9273d2e032a2 (patch) | |
tree | cc64d3b42644b7a6eb809c5dc9a19b74ea099a46 /doc/plugins.md | |
parent | dc27b019acba0f6eb5913c8c74baa8362eff9045 (diff) |
prettify documentation
Diffstat (limited to 'doc/plugins.md')
-rw-r--r-- | doc/plugins.md | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/doc/plugins.md b/doc/plugins.md index 5417446..bbaaf55 100644 --- a/doc/plugins.md +++ b/doc/plugins.md @@ -1,10 +1,12 @@ # Plugins + mt-multiserver-proxy loads all plugin files in the `plugins` directory on startup. Any errors will be logged and do not prevent other plugins from being loaded. Plugins **cannot** be (re)loaded at runtime, you need to restart the proxy. ## Installing plugins + The recommended way to install plugins is cd'ing into the `plugins` directory, downloading the source code (e.g. using `git clone`) into it and starting the proxy without setting the `NoAutoPlugins` config option @@ -17,6 +19,7 @@ for end users to deal with versioning. This won't work in development builds. ### Manual installation + To install a plugin manually, clone the repository, cd into it and run: ``` @@ -27,6 +30,7 @@ A .so file will be created. Copy or move this file into the `plugins` directory. Restart the proxy to load the plugin. ### Automatic version management + To make dealing with version issues easier for end users the `mt-build-plugin` tool is provided. It automatically detects the correct proxy version and builds the plugin in the working directory @@ -39,6 +43,7 @@ mt-build-plugin ``` ## Developing plugins + A plugin is simply a main package without a main function. Use the init functions instead. Plugins can import `github.com/HimbeerserverDE/mt-multiserver-proxy` and use the exported @@ -49,6 +54,7 @@ Crucially, symbols may be renamed or deleted and fields may be deleted from type definitions.** ## Common issues + If mt-multiserver-proxy prints an error similar to this: ``` @@ -74,6 +80,7 @@ My build environment can be found in [build_env.md](https://github.com/HimbeerserverDE/mt-multiserver-proxy/blob/main/doc/build_env.md). ## Using plugins with development builds + You can build a development version by following the instructions in [README.md](https://github.com/HimbeerserverDE/mt-multiserver-proxy/blob/main/README.md#development-builds). @@ -86,6 +93,7 @@ and copy everything excluding the `require `. Then append a new line: Now rebuild and install the plugin and it should be loaded. ### Automatic development version management + The `mt-build-plugin` tool as well as the proxy itself are capable of handling development versions, but the former only works if it's located in the same directory as the proxy executable. See |