-
Notifications
You must be signed in to change notification settings - Fork 1.5k
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
Specifying a directory of .java files as source-file src no longer works #564
Comments
Thanks @ippeiukai for reporting. I cannot promise when I or anyone else will get a chance to fix this. PR would be welcome for review. |
I'm not really a fan of this and don't really think we should support this. It was always intended to to operate on files (hence the Of course, now it's basically impossible to drop support for this without breaking an unknown number of plugins 😞 |
I am also not in love with this feature, for reasons I gave in the description of apache/cordova#47. But yes the idea of breaking an unknown number of plugins without proper investigation and advance warning is pretty bad. Assuming that this undocumented feature was broken in cordova-android 7.0.0, and we did not hear much until recently, I would now expect the number of plugins broken by this issue to be pretty minimal. I would favor deprecating this feature in the upcoming major release, with a warning message, and removing it at some point in the future. This should be part of the discussion in apache/cordova#47. |
I’m not fun of the whole source-file element situation to be honest. The documentation on the target-dir attribute reads as follows:
(https://cordova.apache.org/docs/en/8.x/plugin_ref/spec.html#source-file) Note that cordova-android has diverged from the above documented behaviour in 7.x by replacing parts of specified path for backward compatibility. In fact, the undocumented feature described in this issue is broken (or more like left behind) in that process. As @brodybits says discussion should be continued on apache/cordova#47. |
Closing as obsolete / out-dated. I don't think this was ever acted on and several people expressed an opposition of even supporting directories, so I think it's probably best to keep the current implementation as-is in modern cordova-android. |
From apache/cordova#47
And originally #547 (comment)
Specifying a directory with many .java files as source-file src works with cordova-android@6, but not with cordova-android@7. (Source files would be put into incorrect subdirectory on cordova-android@latest.)
This has affected at least one plugin, as shown in following PR:
vaenow/cordova-plugin-app-update#119
This behaviour is undocumented, but has been already know on the web.
As discussed in apache/cordova#47 (comment), we are keeping this behaviour.
The text was updated successfully, but these errors were encountered: