我最近将离子cli更新到最新版本。现在我无法将我的应用程序部署到设备上。请参阅我的ionic info
命令的输出
cli packages:
@ionic/cli-utils : 1.9.2
ionic (Ionic CLI) : 3.9.2
global packages:
Cordova CLI : 7.0.1
local packages:
@ionic/app-scripts : 1.3.7
Cordova Platforms : android 6.2.3
Ionic Framework : ionic-angular 3.3.0
System:
Node : v6.10.0
npm : 3.10.10
OS : Windows 7
每当我运行ionic cordova run android
命令时,它只显示以下输出,并且不会将app部署到设备上。我尝试运行文档ionic cordova run android --device
中提到的新命令,没有更改相同的输出。我该如何解决这个问题?
cordova platform add android --save
× Running command - failed!
[WARN] Platform already added. Saving platforms to config.xml.
> cordova platform save
√ Running command - done!
[INFO] Running app-scripts build: --platform android --target cordova
[06:44:35] build dev started ...
[06:44:35] clean started ...
[06:44:35] clean finished in 7 ms
[06:44:35] copy started ...
[06:44:35] transpile started ...
[06:44:39] transpile finished in 4.53 s
[06:44:39] preprocess started ...
[06:44:39] deeplinks started ...
[06:44:39] deeplinks finished in 63 ms
[06:44:39] preprocess finished in 63 ms
[06:44:39] webpack started ...
[06:44:40] copy finished in 5.48 s
[06:44:51] webpack finished in 11.90 s
[06:44:51] sass started ...
[06:44:53] sass finished in 1.46 s
[06:44:53] postprocess started ...
[06:44:53] removed unused font files
[06:44:53] postprocess finished in 30 ms
[06:44:53] lint started ...
[06:44:53] build dev finished in 18.38 s
> ionic cordova prepare
[WARN] No Cordova platforms listed in config.xml. Nothing to prepare.
You can save your installed platforms to config.xml with the ionic cordova platform save command.
[06:44:57] lint finished in 4.42 s
答案 0 :(得分:1)
这是因为您需要使用cordova CLI添加平台
Mode=TwoWay, UpdateSourceTrigger=PropertyChanged
PLATFORM_TAG(Android或ios)