[TIMOB-19549] iOS: JS files in Resources get minified if minification is not "skipped"
| GitHub Issue | n/a | 
|---|---|
| Type | Bug | 
| Priority | Critical | 
| Status | Closed | 
| Resolution | Fixed | 
| Resolution Date | 2015-09-20T09:57:56.000+0000 | 
| Affected Version/s | Release 5.0.0 | 
| Fix Version/s | Release 5.0.1 | 
| Components | iOS, Tooling | 
| Labels | n/a | 
| Reporter | Chris Barber | 
| Assignee | Chris Barber | 
| Created | 2015-09-18T20:39:08.000+0000 | 
| Updated | 2015-09-22T20:41:21.000+0000 | 
Description
	JS files in the Resources dir are getting minified. This is due to a bug introduced in Ti SDK 5.0.0.
To reproduce, do:
ti clean
ti build -p ios -T device --build-only --skip-js-minify
At this point, since we did't minify the JS files, the build/iphone/assets dir will contain symlinks to the original files in the Resources dir. titanium_prep happily encrypts them and all is good.
ti build -p ios -T device --build-only
Now the iOS build will minify and then encrypt. Except this time, when we write the minified JS code to the assets dir, the destination exists and it's a symlink! When it writes to the symlinked JS file, it modifies the original in the Resources dir.
Master PR: https://github.com/appcelerator/titanium_mobile/pull/7206 5_0_X PR: https://github.com/appcelerator/titanium_mobile/pull/7207
APPROVED. PRs merged.
To all, into order to install the update, do: [appc] ti sdk install --default --branch 5_0_X 5.0.0.v20150920030708
Verified fixed, using: MacOS 10.11 (15A279b) Studio 4.3.0.201509151348 Ti SDK 5.0.1.v20150922062312 Appc NPM 4.2.0 Appc CLI 5.0.2-19 Ti CLI 5.0.4 Alloy 1.7.10 Arrow 1.2.62 Xcode 7.0 (7A218) Node v0.10.37 Java 1.7.0_45 preproduction Original JS files are not minified on builds.