I built a "Hello World" app using PhoneGap Desktop, but now when I try to build an APK on build.phonegap.com, it just hangs. The build has been pending for 2 days now. Is there an alternative way to build the APK?
Go to Console/Terminal
cd Project Path
cordova build android
(or)
cordova build ios
Go to project path ->platforms -> ios/android in finder(mac)/file explorer(windows)
It converts android/iOS project and open project in android studio/Xcode and build .apk/.ipa file.
It's a bit clunky, but deleting your app from PhoneGap Build and re-adding adding the app should solve the problem. This solution was found on the Adobe Forums.
Related
How easy is PhoneGap to build and deploy Android applications? The application I'm thinking of is not a beginner level app. How is the level of debugging and error handling and the support it gives?
Thanks in advance.
Deploying an app with Phonegap is quite easy. You can install Phonegap by using,
npm install -g phonegap#latest
and then create an app by,
phonegap create myApp
Refer the docs, PhoneGap Getting Started
When you create the app you will notice there is a directory called "WWW". All you have to do is copy a build of your existing web app to this directory.
All your assets and code in this directory will be used to build apps for the platforms you specify.
You can use Cordova to add the Android platform, which will be used to get an Android build out of your project.
Use,
cordova platform add android
Notice the directory "platforms". Inside it you will find another directory called "android" and this will be your Android project.
To build an Android app simply use,
phonegap build android
When you run the above command Phonegap will build an Android project using your code in WWW directory and place it in the platforms/android directory.
You can then use Android Studio to open the android directory which is an Android project now.
It's as simple as that and quite easy once you get the hang of it.
Then you can do all the regular debugging inside Android Studio using Logcat.
I am new to Flutter developement.
I kept reading, understanding & following Flutter Documentation and has created my first flutter app in Android Studio IDE. It is working fine in android emulators.
Now I want to test application in iOS simulator but I don't know how to generate build for iOS.
Is it possible to generate .ipa through Android Studio IDE? If yes then how can I do that? Also I can not build .apk, what are the steps for that?
Thanks in Advance...
You can use
flutter build apk --release
flutter install
To build for iOS you need a Mac, because it depends on XCode to compile parts of the application.
You should first install X-Code and Android Studio (with Flutter settings and SDK enabled) on macOs, then copy your source code there and open with Android Studio.
After that run flutter clean, flutter packages get and flutter build ios commands in order.
If you have used some libraries that are not supported in iOS they must be omitted or replaced in the project (it can be determined by seeing the library's official page on pub.dev).
Then connect the iPhone to mac and if everything is OK it should be visible in device list section, finally press the Run button to finalize required dependencies by downloading from the internet.
I am new to Phonegap and have succesfully created my first app and compiled first on-line then set up phonegap, android SDK etc locally so I can build and run the app in the emulator using 'phonegap run android' at the command prompt (windows).
For an IDE I installed Eclipse and imported the project. I can now run the project from within Eclipse.
However I am really struggling with the Eclipse build. It's taken days already to solve all the problems and get to this stage but I've reached the point where I can't make progress although it would seem so simple.
The build project option is disabled. It turns on if I add something under 'Builders' under 'Configure Build Path...' but I have no idea what I should be doing here.
I can go back to the CMD prompt and build, refresh in Eclipse and run the modified version but this can't be the right way to do it?
I just need to tell Eclipse to 'phonegap build'. But how?
When you create a project using PhoneGap it creates a Gradle based build which can be opened in Android Studio or IntelliJ IDEA. I recommend using Android Studio for PhoneGap projects.
I try to compile my Cordova Hybrid App from visual studio to apk file
After I deploy the project to Android / iOS the project bin folder still empty.
I try to upload the "www" folder to build.phonegap.com but I get error.
What is the best and correct way to compile the project (HTML, CSS, and JS) to APK for Android and IOS?
Thanks,
Tom
Update:
I try to build from the visual studio
this is my Project folder
When I try to build project from the visual studio on "Device" mode I get this error
1- If you have used Ripple simulator as the target, nothing will be generated in the bin folder. You need to switch the build configuration to "device" in order for the binaries to be generated
2 - The www folder that is generated by the Visual Studio template has nothing special and you shouldn't have issues with PhoneGap Build. If you have errors they are coming from your JS code itself
3 - To build the binaries for Android using the Multi-Device Hybrid extension for Visual Studio, you should be good by simply switching the build configuration to "device" instead of Ripple simulator. For iOS you need to use the Remote Build and Simulation Agent for iOS (which require have a Mac as the iOS tools are NOT available for Windows and you cannot generate the iOS binary directly on your Windows machine. Otherwise, you can consider using PhoneGap Build service
From the image the error looks to be similar to the one I was getting about my device not being recognized/found.
This answer explains how to get the APK directly just by setting the solution to Release, and only Building the project rather trying to do a full deploy to a device. It pretty much is the same answer as mentioned in point 3 above, just tested on a PhoneGap App solution.
I know how to create .apk application with eclipse, but right now I have written it with netbeans and I don't know how to do it.
https://blogs.oracle.com/geertjan/entry/procedure_for_android_development_on
here is said to click right mouse button on my project and choose "Export Signed Android Package" but I don't have such option.
Try phonegap cloud build service, it is very good option, you have to remember to generate your app's config.xml before building online. You can build apk,ipa,oct, etc as you wish.I think you have to install some plugins for build using netbeans.Check for plugin as shown:
Tools-->plugins-->Available plugins
Nativly this is not possible with netbeans. However you can build your project simply my command-line:
phonegap run android
However this depends on your platform and your phonegap version, read on: http://docs.phonegap.com/en/3.2.0/guide_cli_index.md.html#The%20Command-Line%20Interface