Ionic 2 Build成功但没有生成APK

时间:2016-12-03 05:44:26

标签: build apk ionic2

我正在使用Ionic 2.我可以使用离子服务。当我尝试使用build命令或Android或iOS的run命令时,命令会成功,但不会生成apk或ipa。 platorm文件夹下没有构建文件夹。

E.g。

ionic build android

输出以下内容:

> ionic-app-scripts build

[00:35:55]  ionic-app-scripts 0.0.45 
[00:35:55]  build prod started ... 
[00:35:55]  clean started ... 
[00:35:55]  clean finished in 5 ms 
[00:35:55]  copy started ... 
[00:35:55]  ngc started ...  
[00:35:55]  copy finished in 93 ms 
[00:36:07]  ngc finished in 12.19 s 
[00:36:07]  webpack started ... 
[00:36:14]  webpack finished in 7.00 s 
[00:36:14]  uglifyjs started ... 
[00:36:14]  sass started ... 
[00:36:15]  sass finished in 922 ms 
[00:36:15]  cleancss started ... 
[00:36:16]  cleancss finished in 924 ms 
[00:36:22]  uglifyjs finished in 8.68 s 
[00:36:22]  build prod finished in 27.88 s 

1 个答案:

答案 0 :(得分:0)

试试这个。我假设你已经安装了android sdk。

ionic platform add android
ionic build android

它将生成apk,但这将花费很多时间。