ionic-team / ionic-team/ionic-cli
Target 'device-id' not found, unable to run project
- Ngôn ngữ chính
- TypeScript
- Star
- 2k
- Fork
- 682
- Chỉ số merge pull request
- Không có pull request nào được merge trong 30 ngày
Mô tả
**Description:**
I have created an ionic application, I want to test it on android phone v5.1.1,
when I run 'adb devices' shows me
```
$ adb devices
List of devices attached
420069009bdc7200 device
```
but when
I run the command 'ionic cordova run android --target=420069009bdc7200',
it gives me following error
```
BUILD SUCCESSFUL in 4s
....
........
(node:5184) UnhandledPromiseRejectionWarning: Target '420069009bdc7200' not found, unable to run project
.........
.....
```
**Steps to Reproduce:**
ionic cordova run android --target=device-id
**Output:**
UnhandledPromiseRejectionWarning: Target '420069009bdc7200' not found, unable to run project
**My `ionic info`:**
```
cli packages: (C:\Users\developer.web\Desktop\app\nawrooz\nawrooz-v1\node_modules)
@ionic/cli-plugin-proxy : 1.5.8
@ionic/cli-utils : 1.19.2
ionic (Ionic CLI) : 3.20.0
global packages:
cordova (Cordova CLI) : 8.0.0
local packages:
@ionic/app-scripts : 3.1.9
Cordova Platforms : android 7.0.0 browser 5.0.3
Ionic Framework : ionic-angular 3.9.2
System:
Android SDK Tools : 26.1.1
Node : v8.11.2
npm : 5.6.0
OS : Windows 10
Environment Variables:
ANDROID_HOME : C:\Users\developer.web\AppData\Local\Android\Sdk
HTTP_PROXY : not set
http_proxy : not set
HTTPS_PROXY : not set
https_proxy : not set
IONIC_HTTP_PROXY : not set
PROXY : not set
proxy : not set
Misc:
backend : pro
```
**My `cordova info`:**
```
Node version: v8.11.2
Cordova version: 8.0.0
Config.xml file:
MyApp
An awesome Ionic/Cordova app.
Ionic Framework Team
Plugins:
cordova-plugin-advanced-http,cordova-plugin-device,cordova-plugin-file,cordova-plugin-googleplus,cordova-plugin-ionic-keyboard,cordova-plugin-ionic-webview,cordova-plugin-secure-storage,cordova-plugin-splashscreen,cordova-plugin-statusbar,cordova-plugin-whitelist,cordova-plugin-x-socialsharing,cordova-sms-plugin,es6-promise-plugin,mx.ferreyra.callnumber
Android platform:
**************************************************************************
The "android" command is deprecated.
For manual SDK, AVD, and project management, please use Android Studio.
For command-line tools, use tools\bin\sdkmanager.bat
and tools\bin\avdmanager.bat
**************************************************************************
Invoking "C:\Users\developer.web\AppData\Local\Android\Sdk\tools\bin\avdmanager" list target
Available Android targets:==============] 100% Fetch remote repository...
----------
id: 1 or "android-22"
Name: Android API 22
Type: Platform
API level: 22
Revision: 2
----------
id: 2 or "android-26"
Name: Android API 26
Type: Platform
API level: 26
Revision: 2
----------
id: 3 or "android-28"
Name: Android API 28
Type: Platform
API level: 28
Revision: 4
```
**Other Information:**
I searched a lot but I couldn't find a solution.
please help someone
Hướng dẫn đóng góp
Đánh giá
Issue này chưa được đánh giá.