You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@cordova.apache.org by QiangOffice <Qi...@office2016.cc> on 2016/02/24 11:54:07 UTC
Ask for advice about 'cordova build' command
Hi Sir,
I have used cordova develop my app for five months, thank you support this nice framework for us.
For convenience, I wrote a batch file to build app automatically, but there is a catch, after the 'cordova build' command executed, the batch will end, commands which after 'cordova build' line cannot be executed, so what can I do to solve this problem?
Below is my batch file:
d:
cd cordovaWorkSpace\MyApp
cordova build
copy /y D: \cordovaWorkSpace\MyApp \platforms\android\build\outputs\apk\android-debug.apk C:\Users\Administrator\Desktop\myApp.apk
The last line can never be executed because after the 'cordova build' executed, the cmd window will exit. So please tell me a way to solve this problem.
Thanks
Name:Qiang
Email:QiangOffice@office2016.cc
RE: Ask for advice about 'cordova build' command
Posted by Nikhil Khandelwal <ni...@microsoft.com>.
I think you have to invoke cordova build with the CALL command to ensure it does not cause your script to exit.
call cordova build
-Nikhil
-----Original Message-----
From: So, Byoungro [mailto:byoungro.so@intel.com]
Sent: Wednesday, February 24, 2016 12:19 PM
To: dev@cordova.apache.org
Subject: RE: Ask for advice about 'cordova build' command
After-build hook is a reasonable solution, Qiang.
You may want to check if the source directory
"D: \cordovaWorkSpace\MyApp\platforms\android\build\outputs\apk\android-debug.apk".
It seems there is a space between "D:" and "\".
Another possible cause would be the permission issue on the target directory " C:\Users\Administrator\Desktop\myApp.apk"
Enjoy.
Byoungro So
SSG / DPD / Mobile Computing and Compilers Intel Corporation
-----Original Message-----
From: Steven Gill [mailto:stevengill97@gmail.com]
Sent: Wednesday, February 24, 2016 11:56 AM
To: dev@cordova.apache.org
Subject: Re: Ask for advice about 'cordova build' command
Hey!
Why not use a after_build hook instead?
https://na01.safelinks.protection.outlook.com/?url=http%3a%2f%2fcordova.apache.org%2fdocs%2fen%2flatest%2fguide%2fappdev%2fhooks%2findex.html&data=01%7c01%7cnikhilkh%40microsoft.com%7c544416d17eb0443eae1008d33d5878af%7c72f988bf86f141af91ab2d7cd011db47%7c1&sdata=n5t%2fvu1oJM8WGrif0FZlZ8eLIVXUgm%2bLnO3sISf2yGA%3d
On Wed, Feb 24, 2016 at 11:04 AM, Raphael Bircher <rb...@gmail.com>
wrote:
> Hi
>
> I remember that we have had a similar issue on a other project
> (OpenOffice Testtool) The only solution was to switch to VBA. As I
> know the Batch interpreter has issues with external processes.
>
> Have a nice day
> Raphael
>
> On Wed, Feb 24, 2016 at 11:54 AM, QiangOffice
> <Qi...@office2016.cc>
> wrote:
> > Hi Sir,
> > I have used cordova develop my app for five months, thank you
> > support
> this nice framework for us.
> > For convenience, I wrote a batch file to build app automatically,
> > but
> there is a catch, after the 'cordova build' command executed, the
> batch will end, commands which after 'cordova build' line cannot be
> executed, so what can I do to solve this problem?
> > Below is my batch file:
> > d:
> > cd cordovaWorkSpace\MyApp
> > cordova build
> > copy /y D: \cordovaWorkSpace\MyApp
> \platforms\android\build\outputs\apk\android-debug.apk
> C:\Users\Administrator\Desktop\myApp.apk
> >
> > The last line can never be executed because after the 'cordova build'
> executed, the cmd window will exit. So please tell me a way to solve
> this problem.
> >
> > Thanks
> >
> > Name:Qiang
> > Email:QiangOffice@office2016.cc
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@cordova.apache.org
> For additional commands, e-mail: dev-help@cordova.apache.org
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@cordova.apache.org
For additional commands, e-mail: dev-help@cordova.apache.org
RE: Ask for advice about 'cordova build' command
Posted by "So, Byoungro" <by...@intel.com>.
After-build hook is a reasonable solution, Qiang.
You may want to check if the source directory
"D: \cordovaWorkSpace\MyApp\platforms\android\build\outputs\apk\android-debug.apk".
It seems there is a space between "D:" and "\".
Another possible cause would be the permission issue on the target directory " C:\Users\Administrator\Desktop\myApp.apk"
Enjoy.
Byoungro So
SSG / DPD / Mobile Computing and Compilers
Intel Corporation
-----Original Message-----
From: Steven Gill [mailto:stevengill97@gmail.com]
Sent: Wednesday, February 24, 2016 11:56 AM
To: dev@cordova.apache.org
Subject: Re: Ask for advice about 'cordova build' command
Hey!
Why not use a after_build hook instead?
http://cordova.apache.org/docs/en/latest/guide/appdev/hooks/index.html
On Wed, Feb 24, 2016 at 11:04 AM, Raphael Bircher <rb...@gmail.com>
wrote:
> Hi
>
> I remember that we have had a similar issue on a other project
> (OpenOffice Testtool) The only solution was to switch to VBA. As I
> know the Batch interpreter has issues with external processes.
>
> Have a nice day
> Raphael
>
> On Wed, Feb 24, 2016 at 11:54 AM, QiangOffice
> <Qi...@office2016.cc>
> wrote:
> > Hi Sir,
> > I have used cordova develop my app for five months, thank you
> > support
> this nice framework for us.
> > For convenience, I wrote a batch file to build app automatically,
> > but
> there is a catch, after the 'cordova build' command executed, the
> batch will end, commands which after 'cordova build' line cannot be
> executed, so what can I do to solve this problem?
> > Below is my batch file:
> > d:
> > cd cordovaWorkSpace\MyApp
> > cordova build
> > copy /y D: \cordovaWorkSpace\MyApp
> \platforms\android\build\outputs\apk\android-debug.apk
> C:\Users\Administrator\Desktop\myApp.apk
> >
> > The last line can never be executed because after the 'cordova build'
> executed, the cmd window will exit. So please tell me a way to solve
> this problem.
> >
> > Thanks
> >
> > Name:Qiang
> > Email:QiangOffice@office2016.cc
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@cordova.apache.org
> For additional commands, e-mail: dev-help@cordova.apache.org
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@cordova.apache.org
For additional commands, e-mail: dev-help@cordova.apache.org
Re: Ask for advice about 'cordova build' command
Posted by Steven Gill <st...@gmail.com>.
Hey!
Why not use a after_build hook instead?
http://cordova.apache.org/docs/en/latest/guide/appdev/hooks/index.html
On Wed, Feb 24, 2016 at 11:04 AM, Raphael Bircher <rb...@gmail.com>
wrote:
> Hi
>
> I remember that we have had a similar issue on a other project
> (OpenOffice Testtool) The only solution was to switch to VBA. As I
> know the Batch interpreter has issues with external processes.
>
> Have a nice day
> Raphael
>
> On Wed, Feb 24, 2016 at 11:54 AM, QiangOffice <Qi...@office2016.cc>
> wrote:
> > Hi Sir,
> > I have used cordova develop my app for five months, thank you support
> this nice framework for us.
> > For convenience, I wrote a batch file to build app automatically, but
> there is a catch, after the 'cordova build' command executed, the batch
> will end, commands which after 'cordova build' line cannot be executed, so
> what can I do to solve this problem?
> > Below is my batch file:
> > d:
> > cd cordovaWorkSpace\MyApp
> > cordova build
> > copy /y D: \cordovaWorkSpace\MyApp
> \platforms\android\build\outputs\apk\android-debug.apk
> C:\Users\Administrator\Desktop\myApp.apk
> >
> > The last line can never be executed because after the 'cordova build'
> executed, the cmd window will exit. So please tell me a way to solve this
> problem.
> >
> > Thanks
> >
> > Name:Qiang
> > Email:QiangOffice@office2016.cc
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@cordova.apache.org
> For additional commands, e-mail: dev-help@cordova.apache.org
>
>
Re: Ask for advice about 'cordova build' command
Posted by Raphael Bircher <rb...@gmail.com>.
Hi
I remember that we have had a similar issue on a other project
(OpenOffice Testtool) The only solution was to switch to VBA. As I
know the Batch interpreter has issues with external processes.
Have a nice day
Raphael
On Wed, Feb 24, 2016 at 11:54 AM, QiangOffice <Qi...@office2016.cc> wrote:
> Hi Sir,
> I have used cordova develop my app for five months, thank you support this nice framework for us.
> For convenience, I wrote a batch file to build app automatically, but there is a catch, after the 'cordova build' command executed, the batch will end, commands which after 'cordova build' line cannot be executed, so what can I do to solve this problem?
> Below is my batch file:
> d:
> cd cordovaWorkSpace\MyApp
> cordova build
> copy /y D: \cordovaWorkSpace\MyApp \platforms\android\build\outputs\apk\android-debug.apk C:\Users\Administrator\Desktop\myApp.apk
>
> The last line can never be executed because after the 'cordova build' executed, the cmd window will exit. So please tell me a way to solve this problem.
>
> Thanks
>
> Name:Qiang
> Email:QiangOffice@office2016.cc
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@cordova.apache.org
For additional commands, e-mail: dev-help@cordova.apache.org