How to make apk file using ionic framework with angular

后端 未结 7 1314
天命终不由人
天命终不由人 2021-02-03 12:28

I have created simple apps in local directory, that app name is Ionic-Chat-master

How can i make this to apk file?

i have tried the following command using git b

相关标签:
7条回答
  • 2021-02-03 13:02

    We need to execute below mentioned steps to generate .apk with gradle build system:

    Through out the steps I have assume that I am creating 'MyApp' project

    Step 1 : generate myapp.keystore file using below mentioned command :

    keytool -genkey -v -keystore myapp.keystore -alias myapp -keyalg RSA -keysize 2048 -validity 10000
    

    Step 2 : create ant.properties file with following details :

    storeFile=myapp.keystore
    storePassword=<<your keystore password>>
    keyAlias=myapp
    keyPassword=<<your keystore password>>
    

    Step 3 : create gradle.properties file with the path to set ant.properties file :

    cdvReleaseSigningPropertiesFile= <<path to ant.properties>>
    

    Step 4 : Use last command as mentioned below :

    ionic build android --release
    

    Note : You must have set path for : java, adb, jarsigner, zipalign

    Your generated apk will be in build folder.

    0 讨论(0)
  • 2021-02-03 13:04

    If you want generate .apk using Ionic FrameWork . thats very simple for the sake of this discussion I created the sample app and convert that sample app in to .apk using Ionic Command.

    1.Create a Ionic Sample App,

    $ionic start Ionic-Chat-master
    

    2.Adding a platform to that project

    for ios

    C:\Ionic-Chat-master>ionic platform add ios
    

    and for android

    C:\Ionic-Chat-master>ionic platform add android
    

    3.Previewing on a mobile device(Be Sure your device is Connected)

    for ios

    C:\Ionic-Chat-master>ionic run ios -l –c
    

    for android

    C:\Ionic-Chat-master>ionic run android -l –c
    

    4.Deploy to an android device

    C:\Ionic-Chat-master>ionic build android
    

    These are the Commands which leads to achieve a .apk .

    0 讨论(0)
  • 2021-02-03 13:09

    for ionic 3 add ionic login enter email and pwd then

    ionic package build android
    

    please login and check the apk file.

    0 讨论(0)
  • 2021-02-03 13:10

    First of all you have to install

    1. node.js
    2. apache ANT
    3. Java JDK & JRE
    4. Android SDk & Eclipse

    and then after all installation you have to set this all software path into environmental- variable. and then fire your npm install -g cordova. without this all software installation and there path setup your phoneGap application will not created. and still you have any confusion and any question related software installation and there path setup then again tell me i will help you.

    0 讨论(0)
  • 2021-02-03 13:13

    First create an account at Ionic Io ,

    then in your project directory hit this - >

    ionic io init
    

    then log in there and hit this

    ionic package build android
    

    no need to install anything...

    0 讨论(0)
  • 2021-02-03 13:18
    ionic platform add android
    ionic build --release android
    
    0 讨论(0)
提交回复
热议问题