I think that @ionic/app-scripts 3.0.0 are really broken.
I’m posting here to see if I’m the only one is having this problem.
I start a fresh new “blank” app
ionic start app-scripts-tests blank
When I run
ionic cordova build android --prod --verbose
I get the following:
[DEBUG] CLI flags: { interactive: true, confirm: false }
[DEBUG] { cwd: '/Users/killerchip/dev/temp/app-script-tests', local: false, binPath:
'/usr/local/lib/node_modules/ionic/bin/ionic', libPath: '/usr/local/lib/node_modules/ionic/dist/index.js' }
[INFO] Running app-scripts build: --prod --platform android --target cordova
[12:46:38] build prod started ...
[12:46:38] clean started ...
[12:46:38] clean finished in 2 ms
[12:46:38] copy started ...
[12:46:38] deeplinks started ...
[12:46:38] deeplinks finished in 30 ms
[12:46:38] ngc started ...
[12:46:44] ngc finished in 5.99 s
[12:46:44] preprocess started ...
[12:46:44] copy finished in 6.11 s
[12:46:44] preprocess finished in 78 ms
[12:46:44] webpack started ...
[12:47:05] webpack finished in 21.04 s
[12:47:05] uglifyjs started ...
[12:47:05] sass started ...
[12:47:07] sass finished in 1.48 s
[12:47:07] cleancss started ...
[12:47:16] cleancss finished in 9.20 s
[12:47:18] uglifyjs finished in 12.61 s
[12:47:18] postprocess started ...
And then it is giving me the… “prompt” again
Building without the –prod parameter works fine.
The same goes with my production app. And I had this problem since @ionic/app-scripts v2.1.4.
Right now in production app I’m using Ionic 3.6.1 with @ionic/app-scripts v2.0.1 which works.
If I upgrade my Ionic framework to 3.7.1 but keep the @ionic/app-scripts v2.0.1, then building does not work at all and gives an error about deeplinks (I guess that is expected).
So I’m stuck with v3.6.1 of Ionic if I want to build production versions.
My current ionic info
for the app-scripts-tests app is:
cli packages: (/usr/local/lib/node_modules)
@ionic/cli-utils : 1.13.0
ionic (Ionic CLI) : 3.13.0
global packages:
cordova (Cordova CLI) : 7.1.0
local packages:
@ionic/app-scripts : 3.0.0
Cordova Platforms : android 6.3.0
Ionic Framework : ionic-angular 3.7.1
System:
Android SDK Tools : 26.0.1
ios-deploy : 1.9.2
ios-sim : 5.0.13
Node : v6.10.2
npm : 3.10.10
OS : macOS Sierra
Xcode : Xcode 9.0 Build version 9A235
Misc:
backend : legacy
Is anyone else experiencing this inability to build production packages?
To my understanding this is a big thing, but I don’t see any uproar, so I was wondering if it is something specific to my environment.
Thank you in advance.