-
Notifications
You must be signed in to change notification settings - Fork 9
Writing Plugins
Will be introduced in some next release
This will be probably reworked very soon.
class Rango::Plugin::MyPlugin include Rango::Settings end
Rango.after_boot(:register_pupu) do Pupu.root = Project.root Pupu.media_prefix = Project.settings.media_prefix Pupu.media_root = Project.settings.media_root Rango::Controller.send(:include, Pupu::PupuHelpersMixin) Rango.logger.info("Pupu plugin registered") end
I will think about it, so far it’s not supported.
There is no direct support for task registration as it is in Merb or Rails. The reason is simple: user may be interested in your plugin, but he may not be interested in your tasks. So if you want to provide tasks, simply add them to your project and tell user to puts @load “your-plugin/tasks” to his Thorfile.
If you have a lot of tasks, it may be useful to divide them into more taskfiles, so user may load just what he really want to.
There is no support for mountable applications in Rango. The reason is it’s more about router than about the framework. If your router supports including routes from mountable applications, you will be able to write mountable applications in Rango.