activation – Is there a canonical way for a plugin to install a mu-plugin or drop-in?
I have a couple of plugins that need to install drop-in modules or mu-plugin modules when they’re activated, and remove them when they’re deactivated.
This requires copying — or maybe symlinking — a php file from someplace in my plugin’s directory to either
wp-content/mu-plugins/ on activation.
On deactivation it requires removing that php file.
This can get gnarly on installations with weird file permissions, or when the site owner wants to use composer to configure plugins.
Is there a canonical, worked-out, official way to do this?