我正在嘗試在我的 android 手機上運行一個離子專案。USB 除錯為ON。終端上沒有錯誤。
這是我正在使用的命令 ionic capacitor run android --device TARGET_ID
這是終端上的日志。
Build at: 2022-01-17T08:34:48.302Z - Hash: 5c98884b09c72022 - Time: 10541ms
> capacitor.cmd run android --target 1f693801
[capacitor] √ Copying web assets from www to android\app\src\main\assets\public in 8.69s
[capacitor] √ Creating capacitor.config.json in android\app\src\main\assets in 1.65ms
[capacitor] (node:3840) [DEP0148] DeprecationWarning: Use of deprecated folder mapping "./" in the "exports" field module resolution of the package at D:\Practise\ionic\sgmsls\node_modules\tslib\package.json.
[capacitor] Update this package.json to use a subpath pattern like "./*".
[capacitor] (Use `node --trace-deprecation ...` to show where the warning was created)
[capacitor] √ copy android in 8.77s
[capacitor] √ Updating Android plugins in 19.41ms
[capacitor] [info] Found 4 Capacitor plugins for android:
[capacitor] @capacitor/app@1.0.7
[capacitor] @capacitor/haptics@1.1.3
[capacitor] @capacitor/keyboard@1.2.0
[capacitor] @capacitor/status-bar@1.0.6
[capacitor] √ update android in 223.01ms
[capacitor] √ Running Gradle build in 13.18s
[capacitor] √ Deploying app-debug.apk to 1f693801 in 5.39s
但是我的手機上沒有安裝或打開任何應用程式。
我已經用另一種方式嘗試過了。ionic capacitor run并選擇android。選擇我的設備。
uj5u.com熱心網友回復:
有時具有相同捆綁 ID 的其他應用程式會產生問題,請從設定中檢查您的應用程式串列,看看您是否有任何其他具有相同捆綁 ID 的應用程式。或者只是嘗試重新啟動兩個設備。機器和手機。
也嘗試無線除錯:
如果您的機器和您的移動設備在同一個網路(wifi)上,請使用命令嘗試以下步驟:
adb tcpip 5555adb connect <your-device-ip>:5555您可以從設備的 wifi 選項中獲取設備 IP。ionic cap run android -l --external
轉載請註明出處,本文鏈接:https://www.uj5u.com/shujuku/415344.html
標籤:
上一篇:引數路由和條件不適用于生產模式
