[TIMOB-19968] Changing use-app-thinning does not force rebuild
GitHub Issue | n/a |
---|---|
Type | Bug |
Priority | Critical |
Status | Closed |
Resolution | Fixed |
Resolution Date | 2015-12-09T05:51:41.000+0000 |
Affected Version/s | Release 5.1.0 |
Fix Version/s | Release 5.2.0 |
Components | iOS |
Labels | appthinning |
Reporter | Fokke Zandbergen |
Assignee | Chris Barber |
Created | 2015-11-13T10:05:20.000+0000 |
Updated | 2016-02-18T23:54:41.000+0000 |
Description
Switching the
use-app-thinning
setting in tiapp.xml
does not force a rebuild. If you enable it, image assets catalogs *will* be added, but the images not removed. If you disable it, the images *will* be added, but the image asset catalogs not be removed.
Code:
https://github.com/appcelerator/titanium_mobile/blob/6e66f239d1ffeebd1448658b69e3a189b81b2828/iphone/cli/commands/_build.js#L2345-L2359
[~cbarber] Why not just force a rebuild if
tiapp.xml
has been changed, since in 90% of the cases this is required anyway. Saves us checking a lot of stuff.[~fokkezb] Good find, but I snuck the fix into https://github.com/appcelerator/titanium_mobile/pull/7412/files#diff-f430483233aa01af5b10df8390f9635dR2392 which is still waiting to be merged. :) As far as always rebuilding whenever the
tiapp.xml
is changed, I think don't think that's a good idea. There are a number of things in thetiapp.xml
that do not trigger a rebuild. What if they modify the Android section? Furthermore, things like description, publisher, and URL should be put in a plain text file (that could be encrypted) instead of themain.m
, thus eliminating the need to runxcodebuild
.Haha, sneaky! My thought about it is this... as a developer I need fast, incremental builds when I'm writing JavaScript/Alloy code. Expanding my app, fixing bugs etc. When I make changes to
tiapp.xml
- and probablyplatform
as well - I'm in a different mode in which I prefer accuracy over speed. So if we can simplify the build process and by doing so make it more reliable (now, but also as we add stuff and maybe forget to update these checks) then I'd go for that.Still not convinced. Platform engineers will need to be more careful in the future.
Please remember to resolve this ticket as soon as TIMOB-19694 is resolved.
Resolving ticket. Follow the description to test.
Verified fixed, using: MacOS 10.11.3 (15D21) Studio 4.5.0.201602170821 Ti SDK 5.2.0.v20160216202526 Appc NPM 4.2.3-2 Appc CLI 5.2.0-269 Alloy 1.7.33 Xcode 7.2 (7C68) Toggling the
<use-app-thinning>
setting in the tiapp.xml now forces a rebuild. Tested with a default app and performing multiple builds with the setting toggled after every other build.