You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@cordova.apache.org by mleoking <gi...@git.apache.org> on 2015/09/24 11:26:51 UTC

[GitHub] cordova-android pull request: Fixed CB-9697 Cordova emulate for An...

GitHub user mleoking opened a pull request:

    https://github.com/apache/cordova-android/pull/219

    Fixed CB-9697 Cordova emulate for Android versions 4.1.1 does not work

    After running 'cordova emulate android' the apk is not installed & shown on the emulator despite the log shows the app is successfully launched.
    
    This issue is related to https://issues.apache.org/jira/browse/CB-9080 and https://issues.apache.org/jira/browse/CB-8912. These two previous issues fix the problem in 'device.js' and error in 'emulator.js' is still not corrected.
    
    The `emulator.js` file try to run this command:
    
    exec, 'adb -s ' + target.target + ' install -r -d "' + apk_path + '"', os.tmpdir(), execOptions
    
    The '-d' option is not supported by Android 4.1.1
    
    Remove the '-d' option will fix this issue.

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/mleoking/cordova-android mleoking-patch-1-4.1.x

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/cordova-android/pull/219.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #219
    
----
commit 682c709e96670718c30f27bda0991c6e70826d60
Author: Changwang Zhang <ml...@gmail.com>
Date:   2015-09-24T09:15:36Z

    Fixed CB-9697 Cordova emulate for Android versions 4.1.1 does not work
    
    After running 'cordova emulate android' the apk is not installed & shown on the emulator despite the log shows the app is successfully launched.
    
    This issue is related to https://issues.apache.org/jira/browse/CB-9080 and https://issues.apache.org/jira/browse/CB-8912. These two previous issues fix the problem in 'device.js' and error in 'emulator.js' is still not corrected.
    
    The `emulator.js` file try to run this command:
    
    exec, 'adb -s ' + target.target + ' install -r -d "' + apk_path + '"', os.tmpdir(), execOptions
    
    The '-d' option is not supported by Android 4.1.1
    
    Remove the '-d' option will fix this issue.

----


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@cordova.apache.org
For additional commands, e-mail: dev-help@cordova.apache.org


[GitHub] cordova-android pull request: Fixed CB-9697 Cordova emulate for An...

Posted by daserge <gi...@git.apache.org>.
Github user daserge commented on the pull request:

    https://github.com/apache/cordova-android/pull/219#issuecomment-142880086
  
    Is `-d` just about reinstalling an app with version less than the installed one has?


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@cordova.apache.org
For additional commands, e-mail: dev-help@cordova.apache.org


[GitHub] cordova-android pull request: Fixed CB-9697 Cordova emulate for An...

Posted by mleoking <gi...@git.apache.org>.
Github user mleoking commented on the pull request:

    https://github.com/apache/cordova-android/pull/219#issuecomment-142937008
  
    @daserge Thanks for letting me know about [the commit](https://github.com/apache/cordova-android/commit/bf57aa1df061b3fcd429bb8d673de02bcb26f872#diff-257a87acd541c25468767e36993508b9L101). It does not remove the `-d` option from `emulator.js` though.
    
    I am not sure how `-d` is useful for the app development. If it is of no use, we can remove it from all branches?
    
    Can someone explain this?
    
    @infil00p @mwbrooks
    
    



---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@cordova.apache.org
For additional commands, e-mail: dev-help@cordova.apache.org


[GitHub] cordova-android pull request: Fixed CB-9697 Cordova emulate for An...

Posted by nikhilkh <gi...@git.apache.org>.
Github user nikhilkh commented on the pull request:

    https://github.com/apache/cordova-android/pull/219#issuecomment-149642614
  
    We do not plan to make a release to Android 4.1.x. I do not see much point in merging this.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@cordova.apache.org
For additional commands, e-mail: dev-help@cordova.apache.org


[GitHub] cordova-android pull request: Fixed CB-9697 Cordova emulate for An...

Posted by mleoking <gi...@git.apache.org>.
Github user mleoking commented on the pull request:

    https://github.com/apache/cordova-android/pull/219#issuecomment-142874106
  
    @daserge If you visit https://github.com/apache/cordova-android/blob/4.1.x/bin/templates/cordova/lib/device.js in the `4.1.x branch`, you will see that `device.js` is already fixed (-d is removed). But `emulator.js` is not. So, this pull just fix `emulator.js` in the `4.1.x branch`.
    
    I am not sure whether the `-d` option should be removed for more branches. It depends on whether other versions of android system support this option.
    
    It would be really nice if someone can do a systematic test and fix them all. :)


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@cordova.apache.org
For additional commands, e-mail: dev-help@cordova.apache.org


[GitHub] cordova-android pull request: Fixed CB-9697 Cordova emulate for An...

Posted by mleoking <gi...@git.apache.org>.
Github user mleoking commented on the pull request:

    https://github.com/apache/cordova-android/pull/219#issuecomment-149733109
  
    @nikhilkh I created this patch because the ionic framework by default download this branch (Android 4.1.x) of cordova when adding the android platform. 
    
    As ionic is widely popular, I suppose this bug would affect many people. Personally, every time, I create a new ionic project and add the android platform, I need to manually fix this file. 
    
    So, if you can please fix it. 


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@cordova.apache.org
For additional commands, e-mail: dev-help@cordova.apache.org


[GitHub] cordova-android pull request #219: Fixed CB-9697 Cordova emulate for Android...

Posted by asfgit <gi...@git.apache.org>.
Github user asfgit closed the pull request at:

    https://github.com/apache/cordova-android/pull/219


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@cordova.apache.org
For additional commands, e-mail: dev-help@cordova.apache.org


[GitHub] cordova-android pull request: Fixed CB-9697 Cordova emulate for An...

Posted by daserge <gi...@git.apache.org>.
Github user daserge commented on the pull request:

    https://github.com/apache/cordova-android/pull/219#issuecomment-142878060
  
    @mleoking Thanks for the explanation!
    I think `-d` was also being removed in master before [this commit](https://github.com/apache/cordova-android/commit/bf57aa1df061b3fcd429bb8d673de02bcb26f872#diff-257a87acd541c25468767e36993508b9L101), so I'm not sure that this fix should only go to the `4.1.x` branch.
    What does `-d` option do on >4.1.1 devices? 
    I could not find anything more than 
    `-d: Allow version code downgrade.`


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@cordova.apache.org
For additional commands, e-mail: dev-help@cordova.apache.org


[GitHub] cordova-android pull request: Fixed CB-9697 Cordova emulate for An...

Posted by daserge <gi...@git.apache.org>.
Github user daserge commented on the pull request:

    https://github.com/apache/cordova-android/pull/219#issuecomment-142867588
  
    @mleoking thanks!
    It should be fixed in `device.js` as well.
    I believe this is a duplicate of #216 though.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@cordova.apache.org
For additional commands, e-mail: dev-help@cordova.apache.org