-
Notifications
You must be signed in to change notification settings - Fork 278
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Globally installed extensions #115
Comments
That's a great idea! I would call it a plugin, I agree, to separate it from an extension. Let's discuss more! |
Some further suggestions (and actually some repetitions from the first post): If possible, writing a plugin does not change at all, just an exported function being passed Default options: Vorpal would call Configuration: While things should just run out of the box, more control for interested users would not hurt. A global vorpal config file could be used to provide custom options to specific plugins, or to turn them on/off. Conflict resolution: If the npm-package name is used as an identifier, no naming conflicts can arise between multiple global plugins. But a global plugin could be installed which an application depends on and
Plugin discovery: Every globally installed module with a special npm keyword (e.g. Plugin availability: A user running an app does not necessarily know it is powered by Vorpal. How does he kow he can enhance it with sweet plugins? With plugins, it is in the interest of the app developer to tell the users that Vorpal is used. So we should help the developer to do so. Provide an informative website, maybe a readme badge etc. Powerful: Not just restricted to adding commands, but full modifications on the Plugin-Bundles: A plugin could simply depend on some plugins locally and Apps-As-Plugins: Could an application also export its own functionality as a plugin? Again a pattern that would be cool for cash, the plugin part would add all the linux-commands to any vorpal-application. Then again, just installing it as a cli tool should not directly cause modifications in other installed vorpal programs. So this probably is not a good idea. But instead, a program wishing to export its own functionality as a plugin, could do the implementation in a plugin, and then simply depend on and use said plugin. |
I'm really liking this, and agree with each of your points!!!! Damn. I need more time. |
Another fancy feature-idea with really low priority:
What if users could do a global install of an extension, and all vorpal programs would automagically be able to use the commands provided by the gobally installed extensions? I suppose this is doable (or else vorpal-use wouldn't exist, right)? This would not have to be limited to commands, the extensions could just be loaded as usual. This way, global extensions which monkey-patch vorpal would be possible as well.
However, some extensions don't provide out-of-the-box usable commands, e.g. Vorpal-Tour. These should not be automatically included. Maybe differentiate between extensions and plugins?
This would allow really cool stuff. As a user, I could just install vorpal-less and have it in all my vorpal-based applications. I did not look at the architecture of Cash yet, but if the single commands are implemted as extensions, all of these could become globally available as well.
The text was updated successfully, but these errors were encountered: