Issue with Phonegap / Cordova and Android dev - android

I started learning Phonegap and cross-platform mobile dev. I have an issue testing my Android app while only using command line.
Windows 7, Nexus 5 linked to the computer and found in the adb devices.
So, building a new Phonegap project, adding Android to it with no problem.
phonegap build android
works fine. Then :
c:\Android\Project\hello>phonegap install android
[phonegap] detecting Android SDK environment...
[phonegap] using the local environment
[phonegap] trying to install app onto device
[phonegap] no device was found
Device is properly linked with usb debugging checked. What's "amusing" (but not really for me right now) is that if I launch Eclipse, adds the project and run it as an Android project, it uploads and launch on my device instantly. The point is, I don't want to launch Eclipse just for that...
Please help me resolve this.
BTW I also tested the emulator on Eclipse, it's awfully slow ! Isn't there a better way to test this, or the only option is to have my phone linked all the time ?

Related

How do i run my ionic android app on an emulator without installing/running the android studio?

Android studio is too heavy and slows down my pc for development. i am an ionic developer and i only need the android emulator to have a better test environment for my mobile application. I only make use of the android studio because i am trying to set up the virtual emulator following the steps in this video Ionic 3 Tutorial #16 Run app on Android Emulator
I will like to know if there is another way out to test and run my ionic app either on a real or virtual android emulator. I will like to know if i can run the emulator through my vs code or a lighter IDE
If you have set up the emulator already it is enough to execute "ionic cordova run android" in Visual Studio Code.
VSCode than checks for physical devices connected. If not, it will take the emulator.
Or you could use another emulator like Droid4X or BlueStacks.
=> Build the APK (ionic cordova build android) and install it on one of those.
One option might be use ionic serve to run it in the browser then in the console activate Toggle device toolbar is not android emulator but might be useful for mobile debug.

Is it possible to create and maintain Android Virtual Devices WITHOUT installing Android Studio?

The development I'm taking on is written in TypeScript/JavaScript, and all the instructions left behind use TNS (Telerik NativeScript) command lines to build, debug and publish the apps, for both Android and iOS.
Setting up my Windows PC with Visual Studio Code, Node.js, NativeScript, and the Android SDK, I have got to the point where I can build the application using > tns build android but I cannot run it as I have no devices.
Going back to the NativeScript instructions, it does clearly say that an Android Virtual Device is needed, but the link takes me to how to setup an AVD using Android Studio.
Well, I do not want to install another IDE just to be able to manage AVD's. I'm familiar with VS Code, all the original development was done in VS Code on iOS, and all the documentation, including screenshots, are from VS Code.
Supposedly, there is an AVDManager.exe in C:\Android\android-sdk\tools\bin\, but there certainly isn't in my installation of the SDK.
> emulator -list-avds shows nothing.
> tns device android --available-devices also lists no available emulators.
Embarcaderos' RAD Studio includes an Android emulator, but I'm using Delphi 10.2 Tokyo for desktop development, so don't have access to that emulator on this machine.
Is there any other way to create an AVD, so that when I type > tns run android from the working folder of the mobile app, it starts the emulator and runs the app within it?
You can download just the SDK command line tools via the android studio download page -> "Get just the command line tools".
The emulator program and the avdmanager should be everything you need to get an emulator up and running.

VS Code and Chrome Debugger - How to debug Ionic App on Android Device?

How do I debug an Ionic app on an Android device using VS Code and Chrome Debugger?
Chrome Debugger (vscode-chrome-debug) documentation mentions that remote debugging can be done so I'm assuming that this means it can be done on an Android Device.
Can anyone give the steps and launch.json file for this?
Hi this one bothered me too for a period of time.
I use a simple approach to achieve this.
Run the command
cordova run android -debug
And I keep the android studio open along with it.
Now when your application is running on your device or simulator you can select that in Android studio and select the process you want to debug.
in android monitor you can get all the logs for that application.
Note:- It doesn't matter what application is open in Android Studio, as long your ionic app is in debug mode you can get logs there.

Deploying HaxeFlixel game to Android device

I'm making a game for android with HaxeFlixel. I'm using VirtualBox to run Windows 7 on my Mac. After developing and building a game in FlashDevelop, I've navigated to the project folder in the command prompt and run this command:
lime test android
I get:
BUILD SUCCESSFUL:
error: device not found
error: device not found
-waiting for device
I made sure VirtualBox is recognizing my Android device in file explorer and in the devices tab in the context menu. I also ran lime setup and made sure I have all the Android development packages and the same version as my phone.
Any idea why my device isn't found?
Is there another way to deploy my HaxeFlixel project to my Android device?
Install Universal Android ADB Driver will solve the problem.

Hot Code Push doesn't work on device in Meteor

I'm starting with mobile development with Meteor and currently facing this problem: when running meteor run android-device, any changes made aren't reflected on device, as they were supposed to be.
The project I'm running is the default one - no additional packages or plugins installed. My Meteor version is 1.0.3.1 running on Ubuntu 14.0.4 with only the android platform installed. The device I'm using is a lovely Nexus 4.
Although it doesn't work on device, the Hot Code Push works like a charm on both simulator and browser.
Any clues what is going on? I appreciate any help.

Categories

Resources