You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@cordova.apache.org by jasongin <gi...@git.apache.org> on 2016/04/12 23:03:15 UTC

[GitHub] cordova-lib pull request: CB-11042: Add cordova run option to skip...

GitHub user jasongin opened a pull request:

    https://github.com/apache/cordova-lib/pull/426

    CB-11042: Add cordova run option to skip prepare

    I'm also submitting a PR for the cordova-cli repo to parse and document the --noprepare option.

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

    $ git pull https://github.com/jasongin/cordova-lib CB-11042

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

    https://github.com/apache/cordova-lib/pull/426.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 #426
    
----
commit 8b60d5f6e718d0e21ae5c39f5564e90dffda2bb0
Author: Jason Ginchereau <ja...@microsoft.com>
Date:   2016-04-12T20:57:06Z

    CB-11042: Add cordova run option to skip prepare

----


---
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-lib pull request: CB-11042: Add cordova run option to skip...

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

    https://github.com/apache/cordova-lib/pull/426


---
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-lib pull request: CB-11042: Add cordova run option to skip...

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

    https://github.com/apache/cordova-lib/pull/426#issuecomment-210667397
  
    LGTM


---
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-lib pull request: CB-11042: Add cordova run option to skip...

Posted by omefire <gi...@git.apache.org>.
Github user omefire commented on a diff in the pull request:

    https://github.com/apache/cordova-lib/pull/426#discussion_r59592544
  
    --- Diff: cordova-lib/src/cordova/run.js ---
    @@ -32,8 +32,10 @@ module.exports = function run(options) {
             var hooksRunner = new HooksRunner(projectRoot);
             return hooksRunner.fire('before_run', options)
             .then(function() {
    -            // Run a prepare first, then shell out to run
    -            return require('./cordova').raw.prepare(options);
    +            if (!options.options.noprepare) {
    +                // Run a prepare first, then shell out to run
    +                return require('./cordova').raw.prepare(options);
    +            }
    --- End diff --
    
    Please add ```return Q();``` in the alternative code path


---
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-lib pull request: CB-11042: Add cordova run option to skip...

Posted by jasongin <gi...@git.apache.org>.
Github user jasongin commented on a diff in the pull request:

    https://github.com/apache/cordova-lib/pull/426#discussion_r59596872
  
    --- Diff: cordova-lib/src/cordova/run.js ---
    @@ -32,8 +32,10 @@ module.exports = function run(options) {
             var hooksRunner = new HooksRunner(projectRoot);
             return hooksRunner.fire('before_run', options)
             .then(function() {
    -            // Run a prepare first, then shell out to run
    -            return require('./cordova').raw.prepare(options);
    +            if (!options.options.noprepare) {
    +                // Run a prepare first, then shell out to run
    +                return require('./cordova').raw.prepare(options);
    +            }
    --- End diff --
    
    Are you sure that's necessary? Any promise libraries I've used did not require returning another promise when the then function completes synchronously. Even for a similar case in this file, that is not done after the if block on line 72.


---
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