-
-
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
allow set configable features for install/uninstall a plugin #239
Comments
Thanks for the report! Since you also opened #240 recently, I assume you're talking about custom plugins like your xregexp-plugin-hanzi-cjk. You're right in that XRegExp doesn't have any mechanism to manage third-party plugins like this, but you should be able to do it in the plugin itself, by keeping the instance in a cache somewhere (it looks like you're already doing this here?). I think you can take a similar approach for disabling plugins: Have the plugin export an "uninstall" function that takes XRegExp and removes it from the cache. Then, in your Hope this helps! |
That's a clever workaround, @josephfrazier. Extending on that, multiple custom tokens can check whether the same feature (e.g. Ruby regex syntax) is installed or not, so they can be installed/uninstalled together. I haven't had much signal on whether custom syntax tokens are useful to people, hence the very minimal controls around them. It would not be difficult to create a A couple of related things I've considered in the past that would improve the management of custom syntax tokens and flags:
|
I like this idea! It feels cleaner than continuing to keep a shared XRegExp instance even despite having EDIT: I also realized that for this part to work:
we'll probably need to add |
current XRegExp can't check a plugin already install or not
and only can addToken, but can't remove token
hope can have a configable for check plugin is installed and disable or uninstall
The text was updated successfully, but these errors were encountered: