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
[TIMOB-25059] Use module hooks instead of plugins #254
Conversation
Moves all the platform specific Hyperloop plugins to the module's hooks folder so we don't need to explicitly register a plugin anymore. Also updates the local build script as well as the Jenkins build to handle the new directory structure. This also gets rid of all the manual plugin packaging.
ed2bcd6
to
733d94b
Compare
This shouldn't have been commited in the first place, but the .gitignore wasn't properly updated, duh!
hooks/hyperloop-init.js
Outdated
exports.cliVersion = '>=3.2'; | ||
exports.init = (logger, config, cli, appc) => { | ||
cli.on('cli:check-plugins', () => { | ||
for (const plugin of cli.tiapp.plugins) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe use forEach
here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm trying to use for...of
whenever possible because it allows break
and continue
logic and doesn't overrides the context because no new function is created.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fine then
hooks/hyperloop-init.js
Outdated
cli.on('cli:check-plugins', () => { | ||
for (const plugin of cli.tiapp.plugins) { | ||
if (plugin.id === 'hyperloop') { | ||
logger.error('Legacy Hyperloop plugin detected! Please remove any references to the Hyperloop plugin tag from your tiapp.xml. Since Hyperloop 3.0 you only need to enable it as a module.'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe phrase it Hyperloop "<plugin>" tag
?
JIRA: https://jira.appcelerator.org/browse/TIMOB-25059
Moves all the platform specific Hyperloop plugins to the module's hooks folder so we don't need to explicitly register a plugin anymore. Also updates the local build script as well as the Jenkins build to handle the new directory structure. This also gets rid of all the manual plugin packaging.