-
Notifications
You must be signed in to change notification settings - Fork 79
Using InvMenu in a plugin
Download the DEVirion plugin and place the InvMenu .phar
file in your virions/
folder.
pmmp_folder
|-- plugins
| `-- devirion.phar
|-- virions
| `-- InvMenu.phar
In production environments, it is not necessary or recommended to install the DEVirion plugin or the InvMenu as a virion. These tools are intended for use during development and testing. When deploying your plugin for production, follow these steps:
- Convert your plugin to a PHAR file
- Download the InvMenu PHAR file
- Inject the virion into your plugin PHAR by running
bin/php7/bin/php path/to/InvMenu.phar path/to/yourplugin.phar
- Install your injected plugin PHAR file on your production server (by moving it to your server's
plugins/
directory)
If you have published your plugin on Poggit, you can skip the process of creating a production-ready version of your plugin and installing it in a production environment. Poggit will handle these tasks for you by injecting virions into your plugin and generating a deployable PHAR file. However, you will need to ensure that you have defined the virion in your .poggit.yml
file so Poggit can properly build and package your plugin for deployment:
--- # Poggit-CI Manifest. Open the CI at https://poggit.pmmp.io/ci/Muqsit/PlayerVaults
branches:
- master
projects:
PlayerVaults:
path: ""
+ libs:
+ - src: muqsit/InvMenu/InvMenu
+ branch: "4.0"
+ version: ^4.4.1 # refer to InvMenu's virion.yml to find the latest version
...
Once the PHAR file has been generated by Poggit, you can directly install it on your production server.
Download the DEVirion plugin and place the InvMenu source folder in your virions/
folder.
pmmp_folder
|-- plugins
| `-- devirion.phar
|-- virions
| |-- InvMenu-master
| |-- src
| `-- virion.yml