[ 
https://issues.apache.org/jira/browse/CB-11042?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15239677#comment-15239677
 ] 

ASF GitHub Bot commented on CB-11042:
-------------------------------------

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


> Add cordova run option to skip prepare
> --------------------------------------
>
>                 Key: CB-11042
>                 URL: https://issues.apache.org/jira/browse/CB-11042
>             Project: Apache Cordova
>          Issue Type: Improvement
>          Components: CordovaLib
>            Reporter: Jason Ginchereau
>            Assignee: Jason Ginchereau
>
> The 'cordova run' command currently always does a "prepare" operation for the 
> target platform before launching the app. There is a --nobuild option (to 
> skip building the native project), but there isn't a --noprepare option.
> This option will be helpful to optimize build-and-run scenarios in the Visual 
> Studio tools for Cordova. VS always ensures the project is fully prepared and 
> built before trying to launch. So by the time it calls 'cordova run' there is 
> no need to do the prepare step, and it just causes the developer to wait 
> extra seconds for every iteration of the inner loop.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to