RE: Proposal: Expose check_reqs at the CLI level

2015-05-05 Thread Vladimir Kotikov (Akvelon)
Hey, guys.

Leo and Josh's feedback is addressed and since there is no more issues, I'm 
going to merge these changes tomorrow.
If there is still any notes/questions, please let me know.

---
Best regards, Vladimir

-Original Message-
From: Vladimir Kotikov (Akvelon) [mailto:v-vlk...@microsoft.com] 
Sent: Thursday, 23 April, 2015 21:39
To: dev@cordova.apache.org
Subject: RE: Proposal: Expose check_reqs at the CLI level

Yes,  check_reqs logic is still being executed on each build by platform build 
script and it's not executed in `platform add`

---
Best regards, Vladimir

-Original Message-
From: Parashuram N (MS OPEN TECH) [mailto:panar...@microsoft.com]
Sent: Thursday, April 23, 2015 9:04 PM
To: dev@cordova.apache.org
Subject: RE: Proposal: Expose check_reqs at the CLI level

Also,  Vlad, can you confirm if check_reqs runs on build, or on platform add ?

-Original Message-
From: Parashuram N (MS OPEN TECH) [mailto:panar...@microsoft.com]
Sent: Thursday, April 23, 2015 11:00 AM
To: dev@cordova.apache.org
Subject: RE: Proposal: Expose check_reqs at the CLI level

My bad - I did not mean that this will run when platform is added. I mean, 
this can run only when a project is present and platform has already been 
added. For this first phase, we are not implementing this command for a 
platform that has not already been added to the project.  

-Original Message-
From: Josh Soref [mailto:jso...@blackberry.com]
Sent: Thursday, April 23, 2015 10:52 AM
To: dev@cordova.apache.org
Subject: RE: Proposal: Expose check_reqs at the CLI level

You mean run but not error?

Because, again, this code *used* to run when platforms were added -- except, 
that then it errored when the requirements weren’t satisfied.

 -Original Message-
 From: Parashuram N (MS OPEN TECH) [mailto:panar...@microsoft.com]
 Sent: Thursday, April 23, 2015 1:23 PM
 To: dev@cordova.apache.org
 Subject: RE: Proposal: Expose check_reqs at the CLI level
 
 I think as the first step, it would make sense to run it when platform 
 is added and project is present. We could change it later to run a system 
 wide check.
 For now, this just picks up what check_reqs already does.
 
 We may need another effort to improve check_reqs itself.
 
 -Original Message-
 From: Vladimir Kotikov (Akvelon) [mailto:v-vlk...@microsoft.com]
 Sent: Thursday, April 23, 2015 1:28 AM
 To: dev@cordova.apache.org
 Subject: RE: Proposal: Expose check_reqs at the CLI level
 
 Hey, Leo. Thanks for feedback!
 
 I've changed verb name to requirements because it looks like it is a 
 happy medium for the majority.
 Updated code for cordova lib and cordova-cli submitted through the 
 following PRs: https://github.com/apache/cordova-cli/pull/212
 https://github.com/apache/cordova-lib/pull/208.
 
 Regarding your questions:
 1. The specification for command is exactly the same as you mentioned:
 
   cordova requirements [platform...]
 
 I've also added a help file to cordova-cli, so 'cordova help 
 requirements' will work now, and will provide all information about usage.
 
 2. There are no special options for requirements command. There are 
 common options for all cli commands like '--sillent' and '--verbose'
 and they're supported automatically.
 
 3. The command requires a project and platform added to project. This 
 was the fastest way to implement it, and it could be changed in future 
 if we decide to support case when project doesn't exists.
 
 ---
 Best regards, Vladimir
 
 -Original Message-
 From: Treggiari, Leo [mailto:leo.treggi...@intel.com]
 Sent: Wednesday, 22 April, 2015 18:11
 To: dev@cordova.apache.org
 Subject: RE: Proposal: Expose check_reqs at the CLI level
 
 Hi Vladimir,
 
 It's great to see this being worked on and discussed.  My comments 
 below are mine and mine alone.
 
 In addition to the code changes, I would have preferred to see a 
 specification of the command, e.g.
 
   cordova check-reqs platform [platform...]
 
 I took a quick look at the CLI code changes and didn't see any option 
 processing.  Are there any options?
 Do the platform(s) specified on the command need to have been already 
 added to the project?
 Does the command require a project - i.e. be executed in a project directory?
 Regarding the command name, I don't think being 'cute' is helpful to 
 users - i.e. I recommend against 'doctor'.
 I think 'check-requirements' would be OK.  It's long but how many 
 times does a user need to type it?
 
 Thanks,
 Leo
 
 -Original Message-
 From: Vladimir Kotikov (Akvelon) [mailto:v-vlk...@microsoft.com]
 Sent: Wednesday, April 22, 2015 7:18 AM
 To: dev@cordova.apache.org
 Subject: RE: Proposal: Expose check_reqs at the CLI level
 
 Hey, guys. Have anyone looked at it?
 I've made some refactoring to make changes more readable, and updated 
 data contract between platform's check_reqs code and LIB API.
 
 Josh, regarding command name. I thought

RE: Proposal: Expose check_reqs at the CLI level

2015-04-23 Thread Parashuram N (MS OPEN TECH)
My bad - I did not mean that this will run when platform is added. I mean, 
this can run only when a project is present and platform has already been 
added. For this first phase, we are not implementing this command for a 
platform that has not already been added to the project.  

-Original Message-
From: Josh Soref [mailto:jso...@blackberry.com] 
Sent: Thursday, April 23, 2015 10:52 AM
To: dev@cordova.apache.org
Subject: RE: Proposal: Expose check_reqs at the CLI level

You mean run but not error?

Because, again, this code *used* to run when platforms were added -- except, 
that then it errored when the requirements weren’t satisfied.

 -Original Message-
 From: Parashuram N (MS OPEN TECH) [mailto:panar...@microsoft.com]
 Sent: Thursday, April 23, 2015 1:23 PM
 To: dev@cordova.apache.org
 Subject: RE: Proposal: Expose check_reqs at the CLI level
 
 I think as the first step, it would make sense to run it when platform is 
 added
 and project is present. We could change it later to run a system wide check.
 For now, this just picks up what check_reqs already does.
 
 We may need another effort to improve check_reqs itself.
 
 -Original Message-
 From: Vladimir Kotikov (Akvelon) [mailto:v-vlk...@microsoft.com]
 Sent: Thursday, April 23, 2015 1:28 AM
 To: dev@cordova.apache.org
 Subject: RE: Proposal: Expose check_reqs at the CLI level
 
 Hey, Leo. Thanks for feedback!
 
 I've changed verb name to requirements because it looks like it is a happy
 medium for the majority.
 Updated code for cordova lib and cordova-cli submitted through the
 following PRs: https://github.com/apache/cordova-cli/pull/212
 https://github.com/apache/cordova-lib/pull/208.
 
 Regarding your questions:
 1. The specification for command is exactly the same as you mentioned:
 
   cordova requirements [platform...]
 
 I've also added a help file to cordova-cli, so 'cordova help requirements' 
 will
 work now, and will provide all information about usage.
 
 2. There are no special options for requirements command. There are
 common options for all cli commands like '--sillent' and '--verbose' and
 they're supported automatically.
 
 3. The command requires a project and platform added to project. This was
 the fastest way to implement it, and it could be changed in future if we
 decide to support case when project doesn't exists.
 
 ---
 Best regards, Vladimir
 
 -Original Message-
 From: Treggiari, Leo [mailto:leo.treggi...@intel.com]
 Sent: Wednesday, 22 April, 2015 18:11
 To: dev@cordova.apache.org
 Subject: RE: Proposal: Expose check_reqs at the CLI level
 
 Hi Vladimir,
 
 It's great to see this being worked on and discussed.  My comments below
 are mine and mine alone.
 
 In addition to the code changes, I would have preferred to see a specification
 of the command, e.g.
 
   cordova check-reqs platform [platform...]
 
 I took a quick look at the CLI code changes and didn't see any option
 processing.  Are there any options?
 Do the platform(s) specified on the command need to have been already
 added to the project?
 Does the command require a project - i.e. be executed in a project directory?
 Regarding the command name, I don't think being 'cute' is helpful to users -
 i.e. I recommend against 'doctor'.
 I think 'check-requirements' would be OK.  It's long but how many times does
 a user need to type it?
 
 Thanks,
 Leo
 
 -Original Message-
 From: Vladimir Kotikov (Akvelon) [mailto:v-vlk...@microsoft.com]
 Sent: Wednesday, April 22, 2015 7:18 AM
 To: dev@cordova.apache.org
 Subject: RE: Proposal: Expose check_reqs at the CLI level
 
 Hey, guys. Have anyone looked at it?
 I've made some refactoring to make changes more readable, and updated
 data contract between platform's check_reqs code and LIB API.
 
 Josh, regarding command name. I thought that there is still no agreement
 about verb name.
 Personally I agree that `cordova doctor` or `cordova requirements` sounds
 better, but this is just a command name ant it could be changed at any time.
 
 ---
 Best regards, Vladimir
 
 -Original Message-
 From: Parashuram N (MS OPEN TECH) [mailto:panar...@microsoft.com]
 Sent: Monday, 20 April, 2015 22:04
 To: dev@cordova.apache.org
 Subject: RE: Proposal: Expose check_reqs at the CLI level
 
 This was only an initial implementation - no pull request has been sent. I
 think this is just a way for folks to play with what Vlad has now. I am sure 
 we
 will change the verb name before a PR comes in.
 
 -Original Message-
 From: Josh Soref [mailto:jso...@blackberry.com]
 Sent: Monday, April 20, 2015 11:59 AM
 To: dev@cordova.apache.org
 Subject: RE: Proposal: Expose check_reqs at the CLI level
 
 -1
 
 Didn't everyone agree to call it `cordova doctor` or worst, `cordova
 requirements`?
 
  -Original Message-
  From: Vladimir Kotikov (Akvelon) [mailto:v-vlk...@microsoft.com]
  Sent: Monday, April 20, 2015 11:46 AM
  To: dev@cordova.apache.org

RE: Proposal: Expose check_reqs at the CLI level

2015-04-23 Thread Parashuram N (MS OPEN TECH)
I think as the first step, it would make sense to run it when platform is added 
and project is present. We could change it later to run a system wide check. 
For now, this just picks up what check_reqs already does. 

We may need another effort to improve check_reqs itself. 

-Original Message-
From: Vladimir Kotikov (Akvelon) [mailto:v-vlk...@microsoft.com] 
Sent: Thursday, April 23, 2015 1:28 AM
To: dev@cordova.apache.org
Subject: RE: Proposal: Expose check_reqs at the CLI level

Hey, Leo. Thanks for feedback!

I've changed verb name to requirements because it looks like it is a happy 
medium for the majority.
Updated code for cordova lib and cordova-cli submitted through the following 
PRs: https://github.com/apache/cordova-cli/pull/212 
https://github.com/apache/cordova-lib/pull/208. 

Regarding your questions:
1. The specification for command is exactly the same as you mentioned:

cordova requirements [platform...]

I've also added a help file to cordova-cli, so 'cordova help requirements' will 
work now, and will provide all information about usage.

2. There are no special options for requirements command. There are common 
options for all cli commands like '--sillent' and '--verbose' and they're 
supported automatically.

3. The command requires a project and platform added to project. This was the 
fastest way to implement it, and it could be changed in future if we decide to 
support case when project doesn't exists.

---
Best regards, Vladimir

-Original Message-
From: Treggiari, Leo [mailto:leo.treggi...@intel.com]
Sent: Wednesday, 22 April, 2015 18:11
To: dev@cordova.apache.org
Subject: RE: Proposal: Expose check_reqs at the CLI level

Hi Vladimir,

It's great to see this being worked on and discussed.  My comments below are 
mine and mine alone.

In addition to the code changes, I would have preferred to see a specification 
of the command, e.g.

cordova check-reqs platform [platform...]

I took a quick look at the CLI code changes and didn't see any option 
processing.  Are there any options?
Do the platform(s) specified on the command need to have been already added to 
the project?
Does the command require a project - i.e. be executed in a project directory?
Regarding the command name, I don't think being 'cute' is helpful to users - 
i.e. I recommend against 'doctor'.
I think 'check-requirements' would be OK.  It's long but how many times does a 
user need to type it?

Thanks,
Leo

-Original Message-
From: Vladimir Kotikov (Akvelon) [mailto:v-vlk...@microsoft.com]
Sent: Wednesday, April 22, 2015 7:18 AM
To: dev@cordova.apache.org
Subject: RE: Proposal: Expose check_reqs at the CLI level

Hey, guys. Have anyone looked at it?
I've made some refactoring to make changes more readable, and updated data 
contract between platform's check_reqs code and LIB API.

Josh, regarding command name. I thought that there is still no agreement about 
verb name.
Personally I agree that `cordova doctor` or `cordova requirements` sounds 
better, but this is just a command name ant it could be changed at any time. 

---
Best regards, Vladimir

-Original Message-
From: Parashuram N (MS OPEN TECH) [mailto:panar...@microsoft.com]
Sent: Monday, 20 April, 2015 22:04
To: dev@cordova.apache.org
Subject: RE: Proposal: Expose check_reqs at the CLI level

This was only an initial implementation - no pull request has been sent. I 
think this is just a way for folks to play with what Vlad has now. I am sure we 
will change the verb name before a PR comes in. 

-Original Message-
From: Josh Soref [mailto:jso...@blackberry.com]
Sent: Monday, April 20, 2015 11:59 AM
To: dev@cordova.apache.org
Subject: RE: Proposal: Expose check_reqs at the CLI level

-1

Didn't everyone agree to call it `cordova doctor` or worst, `cordova 
requirements`?

 -Original Message-
 From: Vladimir Kotikov (Akvelon) [mailto:v-vlk...@microsoft.com]
 Sent: Monday, April 20, 2015 11:46 AM
 To: dev@cordova.apache.org
 Subject: RE: Proposal: Expose check_reqs at the CLI level
 
 Hi, list.
 
 I would like to share a draft implementation for check_reqs command 
 and check_reqs API:
 Changes  could be found here:
 CLI: https://github.com/apache/cordova-
 cli/compare/master...MSOpenTech:requirements_check
 LIB: https://github.com/apache/cordova-
 lib/compare/master...MSOpenTech:requirements_check
 Cordova-android: https://github.com/apache/cordova-
 android/compare/master...MSOpenTech:requirements_check
 
 The implementation consists of following:
 1. 'cordova check-reqs' command for cordova CLI, which calls 
 corresponding cordova-lib API with options, specified from CLI
 
 2. 'check_reqs' module for cordova-lib, which works as a wrapper 
 around platforms' check_reqs scripts. It returns a promise, either 
 resolved if check_reqs platform script is found and ran successfully 
 or rejected in case if check_reqs script is failed due to some internal 
 errors

RE: Proposal: Expose check_reqs at the CLI level

2015-04-23 Thread Vladimir Kotikov (Akvelon)
Yes,  check_reqs logic is still being executed on each build by platform build 
script and it's not executed in `platform add`

---
Best regards, Vladimir

-Original Message-
From: Parashuram N (MS OPEN TECH) [mailto:panar...@microsoft.com] 
Sent: Thursday, April 23, 2015 9:04 PM
To: dev@cordova.apache.org
Subject: RE: Proposal: Expose check_reqs at the CLI level

Also,  Vlad, can you confirm if check_reqs runs on build, or on platform add ?

-Original Message-
From: Parashuram N (MS OPEN TECH) [mailto:panar...@microsoft.com]
Sent: Thursday, April 23, 2015 11:00 AM
To: dev@cordova.apache.org
Subject: RE: Proposal: Expose check_reqs at the CLI level

My bad - I did not mean that this will run when platform is added. I mean, 
this can run only when a project is present and platform has already been 
added. For this first phase, we are not implementing this command for a 
platform that has not already been added to the project.  

-Original Message-
From: Josh Soref [mailto:jso...@blackberry.com]
Sent: Thursday, April 23, 2015 10:52 AM
To: dev@cordova.apache.org
Subject: RE: Proposal: Expose check_reqs at the CLI level

You mean run but not error?

Because, again, this code *used* to run when platforms were added -- except, 
that then it errored when the requirements weren’t satisfied.

 -Original Message-
 From: Parashuram N (MS OPEN TECH) [mailto:panar...@microsoft.com]
 Sent: Thursday, April 23, 2015 1:23 PM
 To: dev@cordova.apache.org
 Subject: RE: Proposal: Expose check_reqs at the CLI level
 
 I think as the first step, it would make sense to run it when platform 
 is added and project is present. We could change it later to run a system 
 wide check.
 For now, this just picks up what check_reqs already does.
 
 We may need another effort to improve check_reqs itself.
 
 -Original Message-
 From: Vladimir Kotikov (Akvelon) [mailto:v-vlk...@microsoft.com]
 Sent: Thursday, April 23, 2015 1:28 AM
 To: dev@cordova.apache.org
 Subject: RE: Proposal: Expose check_reqs at the CLI level
 
 Hey, Leo. Thanks for feedback!
 
 I've changed verb name to requirements because it looks like it is a 
 happy medium for the majority.
 Updated code for cordova lib and cordova-cli submitted through the 
 following PRs: https://github.com/apache/cordova-cli/pull/212
 https://github.com/apache/cordova-lib/pull/208.
 
 Regarding your questions:
 1. The specification for command is exactly the same as you mentioned:
 
   cordova requirements [platform...]
 
 I've also added a help file to cordova-cli, so 'cordova help 
 requirements' will work now, and will provide all information about usage.
 
 2. There are no special options for requirements command. There are 
 common options for all cli commands like '--sillent' and '--verbose'
 and they're supported automatically.
 
 3. The command requires a project and platform added to project. This 
 was the fastest way to implement it, and it could be changed in future 
 if we decide to support case when project doesn't exists.
 
 ---
 Best regards, Vladimir
 
 -Original Message-
 From: Treggiari, Leo [mailto:leo.treggi...@intel.com]
 Sent: Wednesday, 22 April, 2015 18:11
 To: dev@cordova.apache.org
 Subject: RE: Proposal: Expose check_reqs at the CLI level
 
 Hi Vladimir,
 
 It's great to see this being worked on and discussed.  My comments 
 below are mine and mine alone.
 
 In addition to the code changes, I would have preferred to see a 
 specification of the command, e.g.
 
   cordova check-reqs platform [platform...]
 
 I took a quick look at the CLI code changes and didn't see any option 
 processing.  Are there any options?
 Do the platform(s) specified on the command need to have been already 
 added to the project?
 Does the command require a project - i.e. be executed in a project directory?
 Regarding the command name, I don't think being 'cute' is helpful to 
 users - i.e. I recommend against 'doctor'.
 I think 'check-requirements' would be OK.  It's long but how many 
 times does a user need to type it?
 
 Thanks,
 Leo
 
 -Original Message-
 From: Vladimir Kotikov (Akvelon) [mailto:v-vlk...@microsoft.com]
 Sent: Wednesday, April 22, 2015 7:18 AM
 To: dev@cordova.apache.org
 Subject: RE: Proposal: Expose check_reqs at the CLI level
 
 Hey, guys. Have anyone looked at it?
 I've made some refactoring to make changes more readable, and updated 
 data contract between platform's check_reqs code and LIB API.
 
 Josh, regarding command name. I thought that there is still no 
 agreement about verb name.
 Personally I agree that `cordova doctor` or `cordova requirements` 
 sounds better, but this is just a command name ant it could be changed at any 
 time.
 
 ---
 Best regards, Vladimir
 
 -Original Message-
 From: Parashuram N (MS OPEN TECH) [mailto:panar...@microsoft.com]
 Sent: Monday, 20 April, 2015 22:04
 To: dev@cordova.apache.org
 Subject: RE: Proposal: Expose

RE: Proposal: Expose check_reqs at the CLI level

2015-04-23 Thread Josh Soref
You mean run but not error?

Because, again, this code *used* to run when platforms were added -- except, 
that then it errored when the requirements weren’t satisfied.

 -Original Message-
 From: Parashuram N (MS OPEN TECH) [mailto:panar...@microsoft.com]
 Sent: Thursday, April 23, 2015 1:23 PM
 To: dev@cordova.apache.org
 Subject: RE: Proposal: Expose check_reqs at the CLI level
 
 I think as the first step, it would make sense to run it when platform is 
 added
 and project is present. We could change it later to run a system wide check.
 For now, this just picks up what check_reqs already does.
 
 We may need another effort to improve check_reqs itself.
 
 -Original Message-
 From: Vladimir Kotikov (Akvelon) [mailto:v-vlk...@microsoft.com]
 Sent: Thursday, April 23, 2015 1:28 AM
 To: dev@cordova.apache.org
 Subject: RE: Proposal: Expose check_reqs at the CLI level
 
 Hey, Leo. Thanks for feedback!
 
 I've changed verb name to requirements because it looks like it is a happy
 medium for the majority.
 Updated code for cordova lib and cordova-cli submitted through the
 following PRs: https://github.com/apache/cordova-cli/pull/212
 https://github.com/apache/cordova-lib/pull/208.
 
 Regarding your questions:
 1. The specification for command is exactly the same as you mentioned:
 
   cordova requirements [platform...]
 
 I've also added a help file to cordova-cli, so 'cordova help requirements' 
 will
 work now, and will provide all information about usage.
 
 2. There are no special options for requirements command. There are
 common options for all cli commands like '--sillent' and '--verbose' and
 they're supported automatically.
 
 3. The command requires a project and platform added to project. This was
 the fastest way to implement it, and it could be changed in future if we
 decide to support case when project doesn't exists.
 
 ---
 Best regards, Vladimir
 
 -Original Message-
 From: Treggiari, Leo [mailto:leo.treggi...@intel.com]
 Sent: Wednesday, 22 April, 2015 18:11
 To: dev@cordova.apache.org
 Subject: RE: Proposal: Expose check_reqs at the CLI level
 
 Hi Vladimir,
 
 It's great to see this being worked on and discussed.  My comments below
 are mine and mine alone.
 
 In addition to the code changes, I would have preferred to see a specification
 of the command, e.g.
 
   cordova check-reqs platform [platform...]
 
 I took a quick look at the CLI code changes and didn't see any option
 processing.  Are there any options?
 Do the platform(s) specified on the command need to have been already
 added to the project?
 Does the command require a project - i.e. be executed in a project directory?
 Regarding the command name, I don't think being 'cute' is helpful to users -
 i.e. I recommend against 'doctor'.
 I think 'check-requirements' would be OK.  It's long but how many times does
 a user need to type it?
 
 Thanks,
 Leo
 
 -Original Message-
 From: Vladimir Kotikov (Akvelon) [mailto:v-vlk...@microsoft.com]
 Sent: Wednesday, April 22, 2015 7:18 AM
 To: dev@cordova.apache.org
 Subject: RE: Proposal: Expose check_reqs at the CLI level
 
 Hey, guys. Have anyone looked at it?
 I've made some refactoring to make changes more readable, and updated
 data contract between platform's check_reqs code and LIB API.
 
 Josh, regarding command name. I thought that there is still no agreement
 about verb name.
 Personally I agree that `cordova doctor` or `cordova requirements` sounds
 better, but this is just a command name ant it could be changed at any time.
 
 ---
 Best regards, Vladimir
 
 -Original Message-
 From: Parashuram N (MS OPEN TECH) [mailto:panar...@microsoft.com]
 Sent: Monday, 20 April, 2015 22:04
 To: dev@cordova.apache.org
 Subject: RE: Proposal: Expose check_reqs at the CLI level
 
 This was only an initial implementation - no pull request has been sent. I
 think this is just a way for folks to play with what Vlad has now. I am sure 
 we
 will change the verb name before a PR comes in.
 
 -Original Message-
 From: Josh Soref [mailto:jso...@blackberry.com]
 Sent: Monday, April 20, 2015 11:59 AM
 To: dev@cordova.apache.org
 Subject: RE: Proposal: Expose check_reqs at the CLI level
 
 -1
 
 Didn't everyone agree to call it `cordova doctor` or worst, `cordova
 requirements`?
 
  -Original Message-
  From: Vladimir Kotikov (Akvelon) [mailto:v-vlk...@microsoft.com]
  Sent: Monday, April 20, 2015 11:46 AM
  To: dev@cordova.apache.org
  Subject: RE: Proposal: Expose check_reqs at the CLI level
 
  Hi, list.
 
  I would like to share a draft implementation for check_reqs command
  and check_reqs API:
  Changes  could be found here:
  CLI: https://github.com/apache/cordova-
  cli/compare/master...MSOpenTech:requirements_check
  LIB: https://github.com/apache/cordova-
  lib/compare/master...MSOpenTech:requirements_check
  Cordova-android: https://github.com/apache/cordova-
  android/compare/master

RE: Proposal: Expose check_reqs at the CLI level

2015-04-23 Thread Parashuram N (MS OPEN TECH)
Also,  Vlad, can you confirm if check_reqs runs on build, or on platform add ?

-Original Message-
From: Parashuram N (MS OPEN TECH) [mailto:panar...@microsoft.com] 
Sent: Thursday, April 23, 2015 11:00 AM
To: dev@cordova.apache.org
Subject: RE: Proposal: Expose check_reqs at the CLI level

My bad - I did not mean that this will run when platform is added. I mean, 
this can run only when a project is present and platform has already been 
added. For this first phase, we are not implementing this command for a 
platform that has not already been added to the project.  

-Original Message-
From: Josh Soref [mailto:jso...@blackberry.com]
Sent: Thursday, April 23, 2015 10:52 AM
To: dev@cordova.apache.org
Subject: RE: Proposal: Expose check_reqs at the CLI level

You mean run but not error?

Because, again, this code *used* to run when platforms were added -- except, 
that then it errored when the requirements weren’t satisfied.

 -Original Message-
 From: Parashuram N (MS OPEN TECH) [mailto:panar...@microsoft.com]
 Sent: Thursday, April 23, 2015 1:23 PM
 To: dev@cordova.apache.org
 Subject: RE: Proposal: Expose check_reqs at the CLI level
 
 I think as the first step, it would make sense to run it when platform 
 is added and project is present. We could change it later to run a system 
 wide check.
 For now, this just picks up what check_reqs already does.
 
 We may need another effort to improve check_reqs itself.
 
 -Original Message-
 From: Vladimir Kotikov (Akvelon) [mailto:v-vlk...@microsoft.com]
 Sent: Thursday, April 23, 2015 1:28 AM
 To: dev@cordova.apache.org
 Subject: RE: Proposal: Expose check_reqs at the CLI level
 
 Hey, Leo. Thanks for feedback!
 
 I've changed verb name to requirements because it looks like it is a 
 happy medium for the majority.
 Updated code for cordova lib and cordova-cli submitted through the 
 following PRs: https://github.com/apache/cordova-cli/pull/212
 https://github.com/apache/cordova-lib/pull/208.
 
 Regarding your questions:
 1. The specification for command is exactly the same as you mentioned:
 
   cordova requirements [platform...]
 
 I've also added a help file to cordova-cli, so 'cordova help 
 requirements' will work now, and will provide all information about usage.
 
 2. There are no special options for requirements command. There are 
 common options for all cli commands like '--sillent' and '--verbose' 
 and they're supported automatically.
 
 3. The command requires a project and platform added to project. This 
 was the fastest way to implement it, and it could be changed in future 
 if we decide to support case when project doesn't exists.
 
 ---
 Best regards, Vladimir
 
 -Original Message-
 From: Treggiari, Leo [mailto:leo.treggi...@intel.com]
 Sent: Wednesday, 22 April, 2015 18:11
 To: dev@cordova.apache.org
 Subject: RE: Proposal: Expose check_reqs at the CLI level
 
 Hi Vladimir,
 
 It's great to see this being worked on and discussed.  My comments 
 below are mine and mine alone.
 
 In addition to the code changes, I would have preferred to see a 
 specification of the command, e.g.
 
   cordova check-reqs platform [platform...]
 
 I took a quick look at the CLI code changes and didn't see any option 
 processing.  Are there any options?
 Do the platform(s) specified on the command need to have been already 
 added to the project?
 Does the command require a project - i.e. be executed in a project directory?
 Regarding the command name, I don't think being 'cute' is helpful to 
 users - i.e. I recommend against 'doctor'.
 I think 'check-requirements' would be OK.  It's long but how many 
 times does a user need to type it?
 
 Thanks,
 Leo
 
 -Original Message-
 From: Vladimir Kotikov (Akvelon) [mailto:v-vlk...@microsoft.com]
 Sent: Wednesday, April 22, 2015 7:18 AM
 To: dev@cordova.apache.org
 Subject: RE: Proposal: Expose check_reqs at the CLI level
 
 Hey, guys. Have anyone looked at it?
 I've made some refactoring to make changes more readable, and updated 
 data contract between platform's check_reqs code and LIB API.
 
 Josh, regarding command name. I thought that there is still no 
 agreement about verb name.
 Personally I agree that `cordova doctor` or `cordova requirements` 
 sounds better, but this is just a command name ant it could be changed at any 
 time.
 
 ---
 Best regards, Vladimir
 
 -Original Message-
 From: Parashuram N (MS OPEN TECH) [mailto:panar...@microsoft.com]
 Sent: Monday, 20 April, 2015 22:04
 To: dev@cordova.apache.org
 Subject: RE: Proposal: Expose check_reqs at the CLI level
 
 This was only an initial implementation - no pull request has been 
 sent. I think this is just a way for folks to play with what Vlad has 
 now. I am sure we will change the verb name before a PR comes in.
 
 -Original Message-
 From: Josh Soref [mailto:jso...@blackberry.com]
 Sent: Monday, April 20, 2015 11:59 AM
 To: dev@cordova.apache.org

RE: Proposal: Expose check_reqs at the CLI level

2015-04-23 Thread Vladimir Kotikov (Akvelon)
Hey, Leo. Thanks for feedback!

I've changed verb name to requirements because it looks like it is a happy 
medium for the majority.
Updated code for cordova lib and cordova-cli submitted through the following 
PRs: https://github.com/apache/cordova-cli/pull/212 
https://github.com/apache/cordova-lib/pull/208. 

Regarding your questions:
1. The specification for command is exactly the same as you mentioned:

cordova requirements [platform...]

I've also added a help file to cordova-cli, so 'cordova help requirements' will 
work now, and will provide all information about usage.

2. There are no special options for requirements command. There are common 
options for all cli commands like '--sillent' and '--verbose' and they're 
supported automatically.

3. The command requires a project and platform added to project. This was the 
fastest way to implement it, and it could be changed in future if we decide to 
support case when project doesn't exists.

---
Best regards, Vladimir

-Original Message-
From: Treggiari, Leo [mailto:leo.treggi...@intel.com] 
Sent: Wednesday, 22 April, 2015 18:11
To: dev@cordova.apache.org
Subject: RE: Proposal: Expose check_reqs at the CLI level

Hi Vladimir,

It's great to see this being worked on and discussed.  My comments below are 
mine and mine alone.

In addition to the code changes, I would have preferred to see a specification 
of the command, e.g.

cordova check-reqs platform [platform...]

I took a quick look at the CLI code changes and didn't see any option 
processing.  Are there any options?
Do the platform(s) specified on the command need to have been already added to 
the project?
Does the command require a project - i.e. be executed in a project directory?
Regarding the command name, I don't think being 'cute' is helpful to users - 
i.e. I recommend against 'doctor'.
I think 'check-requirements' would be OK.  It's long but how many times does a 
user need to type it?

Thanks,
Leo

-Original Message-
From: Vladimir Kotikov (Akvelon) [mailto:v-vlk...@microsoft.com]
Sent: Wednesday, April 22, 2015 7:18 AM
To: dev@cordova.apache.org
Subject: RE: Proposal: Expose check_reqs at the CLI level

Hey, guys. Have anyone looked at it?
I've made some refactoring to make changes more readable, and updated data 
contract between platform's check_reqs code and LIB API.

Josh, regarding command name. I thought that there is still no agreement about 
verb name.
Personally I agree that `cordova doctor` or `cordova requirements` sounds 
better, but this is just a command name ant it could be changed at any time. 

---
Best regards, Vladimir

-Original Message-
From: Parashuram N (MS OPEN TECH) [mailto:panar...@microsoft.com]
Sent: Monday, 20 April, 2015 22:04
To: dev@cordova.apache.org
Subject: RE: Proposal: Expose check_reqs at the CLI level

This was only an initial implementation - no pull request has been sent. I 
think this is just a way for folks to play with what Vlad has now. I am sure we 
will change the verb name before a PR comes in. 

-Original Message-
From: Josh Soref [mailto:jso...@blackberry.com]
Sent: Monday, April 20, 2015 11:59 AM
To: dev@cordova.apache.org
Subject: RE: Proposal: Expose check_reqs at the CLI level

-1

Didn't everyone agree to call it `cordova doctor` or worst, `cordova 
requirements`?

 -Original Message-
 From: Vladimir Kotikov (Akvelon) [mailto:v-vlk...@microsoft.com]
 Sent: Monday, April 20, 2015 11:46 AM
 To: dev@cordova.apache.org
 Subject: RE: Proposal: Expose check_reqs at the CLI level
 
 Hi, list.
 
 I would like to share a draft implementation for check_reqs command 
 and check_reqs API:
 Changes  could be found here:
 CLI: https://github.com/apache/cordova-
 cli/compare/master...MSOpenTech:requirements_check
 LIB: https://github.com/apache/cordova-
 lib/compare/master...MSOpenTech:requirements_check
 Cordova-android: https://github.com/apache/cordova-
 android/compare/master...MSOpenTech:requirements_check
 
 The implementation consists of following:
 1. 'cordova check-reqs' command for cordova CLI, which calls 
 corresponding cordova-lib API with options, specified from CLI
 
 2. 'check_reqs' module for cordova-lib, which works as a wrapper 
 around platforms' check_reqs scripts. It returns a promise, either 
 resolved if check_reqs platform script is found and ran successfully 
 or rejected in case if check_reqs script is failed due to some internal 
 errors or not found at all.
 
 3. check_reqs script for android platform, updated to return array of 
 requirements.
 
 * Each requirements is an object with following fields:
 - id - some short id, could be useful for tools, that consume API 
 directly
 - name - readable name for this requirement, such as 'Jav JDK' 
 or 'Gradle build tools', etc.
 - installed - Boolean paremeter that indicates if requirement 
 is properly installed/satisfied
 - reason - error

RE: Proposal: Expose check_reqs at the CLI level

2015-04-22 Thread Josh Soref
We're going to type it often enough that I'd be upset at both check_reqs and 
check-requirements

requirements is good enough.

 -Original Message-
 From: Treggiari, Leo [mailto:leo.treggi...@intel.com]
 Sent: Wednesday, April 22, 2015 11:11 AM
 To: dev@cordova.apache.org
 Subject: RE: Proposal: Expose check_reqs at the CLI level
 
 Hi Vladimir,
 
 It's great to see this being worked on and discussed.  My comments below
 are mine and mine alone.
 
 In addition to the code changes, I would have preferred to see a specification
 of the command, e.g.
 
   cordova check-reqs platform [platform...]
 
 I took a quick look at the CLI code changes and didn't see any option
 processing.  Are there any options?
 Do the platform(s) specified on the command need to have been already
 added to the project?
 Does the command require a project - i.e. be executed in a project directory?
 Regarding the command name, I don't think being 'cute' is helpful to users -
 i.e. I recommend against 'doctor'.
 I think 'check-requirements' would be OK.  It's long but how many times does
 a user need to type it?
 
 Thanks,
 Leo
 
 -Original Message-
 From: Vladimir Kotikov (Akvelon) [mailto:v-vlk...@microsoft.com]
 Sent: Wednesday, April 22, 2015 7:18 AM
 To: dev@cordova.apache.org
 Subject: RE: Proposal: Expose check_reqs at the CLI level
 
 Hey, guys. Have anyone looked at it?
 I've made some refactoring to make changes more readable, and updated
 data contract between platform's check_reqs code and LIB API.
 
 Josh, regarding command name. I thought that there is still no agreement
 about verb name.
 Personally I agree that `cordova doctor` or `cordova requirements` sounds
 better, but this is just a command name ant it could be changed at any time.
 
 ---
 Best regards, Vladimir
 
 -Original Message-
 From: Parashuram N (MS OPEN TECH) [mailto:panar...@microsoft.com]
 Sent: Monday, 20 April, 2015 22:04
 To: dev@cordova.apache.org
 Subject: RE: Proposal: Expose check_reqs at the CLI level
 
 This was only an initial implementation - no pull request has been sent. I
 think this is just a way for folks to play with what Vlad has now. I am sure 
 we
 will change the verb name before a PR comes in.
 
 -Original Message-
 From: Josh Soref [mailto:jso...@blackberry.com]
 Sent: Monday, April 20, 2015 11:59 AM
 To: dev@cordova.apache.org
 Subject: RE: Proposal: Expose check_reqs at the CLI level
 
 -1
 
 Didn't everyone agree to call it `cordova doctor` or worst, `cordova
 requirements`?
 
  -Original Message-
  From: Vladimir Kotikov (Akvelon) [mailto:v-vlk...@microsoft.com]
  Sent: Monday, April 20, 2015 11:46 AM
  To: dev@cordova.apache.org
  Subject: RE: Proposal: Expose check_reqs at the CLI level
 
  Hi, list.
 
  I would like to share a draft implementation for check_reqs command
  and check_reqs API:
  Changes  could be found here:
  CLI: https://github.com/apache/cordova-
  cli/compare/master...MSOpenTech:requirements_check
  LIB: https://github.com/apache/cordova-
  lib/compare/master...MSOpenTech:requirements_check
  Cordova-android: https://github.com/apache/cordova-
  android/compare/master...MSOpenTech:requirements_check
 
  The implementation consists of following:
  1. 'cordova check-reqs' command for cordova CLI, which calls
  corresponding cordova-lib API with options, specified from CLI
 
  2. 'check_reqs' module for cordova-lib, which works as a wrapper
  around platforms' check_reqs scripts. It returns a promise, either
  resolved if check_reqs platform script is found and ran successfully
  or rejected in case if check_reqs script is failed due to some internal 
  errors
 or not found at all.
 
  3. check_reqs script for android platform, updated to return array of
  requirements.
 
  * Each requirements is an object with following fields:
  - id - some short id, could be useful for tools, that consume API 
  directly
  - name - readable name for this requirement, such as 'Jav JDK'
  or 'Gradle build tools', etc.
  - installed - Boolean paremeter that indicates if requirement
  is properly installed/satisfied
  - reason - error, reported by requirements check routines if
  requirement is missing.
 
  Please note that work is still in progress, and will be changed
  according to review comments.
  TBD:
  * move presentation logic from LIB to CLI;
  * refine data format, returned by cordova-lib API
  * add other platforms
  * and more... :)
 
  ---
  Best regards, Vladimir
 
  -Original Message-
  From: Parashuram N (MS OPEN TECH) [mailto:panar...@microsoft.com]
  Sent: Monday, 20 April, 2015 3:49
  To: dev@cordova.apache.org
  Subject: RE: Proposal: Expose check_reqs at the CLI level
 
  Looks like implementing a global level check_reqs without a project
  seems harder, I would suggest we make it a part of a second phase of
  this implementation. For now, we have a basic version

RE: Proposal: Expose check_reqs at the CLI level

2015-04-22 Thread Vladimir Kotikov (Akvelon)
Hey, guys. Have anyone looked at it?
I've made some refactoring to make changes more readable, and updated data 
contract between platform's check_reqs code and LIB API.

Josh, regarding command name. I thought that there is still no agreement about 
verb name.
Personally I agree that `cordova doctor` or `cordova requirements` sounds 
better, but this is just a command name ant it could be changed at any time. 

---
Best regards, Vladimir

-Original Message-
From: Parashuram N (MS OPEN TECH) [mailto:panar...@microsoft.com] 
Sent: Monday, 20 April, 2015 22:04
To: dev@cordova.apache.org
Subject: RE: Proposal: Expose check_reqs at the CLI level

This was only an initial implementation - no pull request has been sent. I 
think this is just a way for folks to play with what Vlad has now. I am sure we 
will change the verb name before a PR comes in. 

-Original Message-
From: Josh Soref [mailto:jso...@blackberry.com]
Sent: Monday, April 20, 2015 11:59 AM
To: dev@cordova.apache.org
Subject: RE: Proposal: Expose check_reqs at the CLI level

-1

Didn't everyone agree to call it `cordova doctor` or worst, `cordova 
requirements`?

 -Original Message-
 From: Vladimir Kotikov (Akvelon) [mailto:v-vlk...@microsoft.com]
 Sent: Monday, April 20, 2015 11:46 AM
 To: dev@cordova.apache.org
 Subject: RE: Proposal: Expose check_reqs at the CLI level
 
 Hi, list.
 
 I would like to share a draft implementation for check_reqs command 
 and check_reqs API:
 Changes  could be found here:
 CLI: https://github.com/apache/cordova-
 cli/compare/master...MSOpenTech:requirements_check
 LIB: https://github.com/apache/cordova-
 lib/compare/master...MSOpenTech:requirements_check
 Cordova-android: https://github.com/apache/cordova-
 android/compare/master...MSOpenTech:requirements_check
 
 The implementation consists of following:
 1. 'cordova check-reqs' command for cordova CLI, which calls 
 corresponding cordova-lib API with options, specified from CLI
 
 2. 'check_reqs' module for cordova-lib, which works as a wrapper 
 around platforms' check_reqs scripts. It returns a promise, either 
 resolved if check_reqs platform script is found and ran successfully 
 or rejected in case if check_reqs script is failed due to some internal 
 errors or not found at all.
 
 3. check_reqs script for android platform, updated to return array of 
 requirements.
 
 * Each requirements is an object with following fields:
 - id - some short id, could be useful for tools, that consume API 
 directly
 - name - readable name for this requirement, such as 'Jav JDK' 
 or 'Gradle build tools', etc.
 - installed - Boolean paremeter that indicates if requirement 
 is properly installed/satisfied
 - reason - error, reported by requirements check routines if 
 requirement is missing.
 
 Please note that work is still in progress, and will be changed 
 according to review comments.
 TBD:
 * move presentation logic from LIB to CLI;
 * refine data format, returned by cordova-lib API
 * add other platforms
 * and more... :)
 
 ---
 Best regards, Vladimir
 
 -Original Message-
 From: Parashuram N (MS OPEN TECH) [mailto:panar...@microsoft.com]
 Sent: Monday, 20 April, 2015 3:49
 To: dev@cordova.apache.org
 Subject: RE: Proposal: Expose check_reqs at the CLI level
 
 Looks like implementing a global level check_reqs without a project 
 seems harder, I would suggest we make it a part of a second phase of 
 this implementation. For now, we have a basic version that simply 
 abstracts out existing check_reqs into a separate, platform level 
 command. This could be a good first phase, and should also give us an 
 idea about how developers use this command.
 
 As a part of Phase 2, anyone from the community should be able to 
 build on a cordova level check reqs, and possibly extend it to 
 checking reqs when no project is present.
 
 
 -Original Message-
 From: Josh Soref [mailto:jso...@blackberry.com]
 Sent: Wednesday, April 15, 2015 8:53 AM
 To: dev@cordova.apache.org
 Subject: RE: Proposal: Expose check_reqs at the CLI level
 
 We already support:
 
 `cordova build android`
 
 There's no need for the extra `platform` verb..
 
 But,
 `cordova build android --nobuild` isn't any more intuitive than w/ the 
 extra platform.
 
 
 And yes, as I noted, and others have noted, we used to run check_reqs 
 in add, we're not going back to doing that.
 
 A `cordova doctor` or `cordova requirements` verb seems fine.
 
 I'm also fine `cordova doctor PLATFORM` instead of `cordova platform 
 doctor PLATFORM`,
 
 As for when someone is likely to want to ask what requirements do I 
 need for a platform, it's fairly arbitrary.
 
 Someone who is given a project might know that they don't have the 
 environment for a platform, they aren't likely to want to go down a 
 build rabbit hole, so, I'm -1 on hiding it anywhere near build.
 
 It's perfectly reasonable from my

RE: Proposal: Expose check_reqs at the CLI level

2015-04-22 Thread Treggiari, Leo
Hi Vladimir,

It's great to see this being worked on and discussed.  My comments below are 
mine and mine alone.

In addition to the code changes, I would have preferred to see a specification 
of the command, e.g.

cordova check-reqs platform [platform...]

I took a quick look at the CLI code changes and didn't see any option 
processing.  Are there any options?
Do the platform(s) specified on the command need to have been already added to 
the project?
Does the command require a project - i.e. be executed in a project directory?
Regarding the command name, I don't think being 'cute' is helpful to users - 
i.e. I recommend against 'doctor'.
I think 'check-requirements' would be OK.  It's long but how many times does a 
user need to type it?

Thanks,
Leo

-Original Message-
From: Vladimir Kotikov (Akvelon) [mailto:v-vlk...@microsoft.com] 
Sent: Wednesday, April 22, 2015 7:18 AM
To: dev@cordova.apache.org
Subject: RE: Proposal: Expose check_reqs at the CLI level

Hey, guys. Have anyone looked at it?
I've made some refactoring to make changes more readable, and updated data 
contract between platform's check_reqs code and LIB API.

Josh, regarding command name. I thought that there is still no agreement about 
verb name.
Personally I agree that `cordova doctor` or `cordova requirements` sounds 
better, but this is just a command name ant it could be changed at any time. 

---
Best regards, Vladimir

-Original Message-
From: Parashuram N (MS OPEN TECH) [mailto:panar...@microsoft.com] 
Sent: Monday, 20 April, 2015 22:04
To: dev@cordova.apache.org
Subject: RE: Proposal: Expose check_reqs at the CLI level

This was only an initial implementation - no pull request has been sent. I 
think this is just a way for folks to play with what Vlad has now. I am sure we 
will change the verb name before a PR comes in. 

-Original Message-
From: Josh Soref [mailto:jso...@blackberry.com]
Sent: Monday, April 20, 2015 11:59 AM
To: dev@cordova.apache.org
Subject: RE: Proposal: Expose check_reqs at the CLI level

-1

Didn't everyone agree to call it `cordova doctor` or worst, `cordova 
requirements`?

 -Original Message-
 From: Vladimir Kotikov (Akvelon) [mailto:v-vlk...@microsoft.com]
 Sent: Monday, April 20, 2015 11:46 AM
 To: dev@cordova.apache.org
 Subject: RE: Proposal: Expose check_reqs at the CLI level
 
 Hi, list.
 
 I would like to share a draft implementation for check_reqs command 
 and check_reqs API:
 Changes  could be found here:
 CLI: https://github.com/apache/cordova-
 cli/compare/master...MSOpenTech:requirements_check
 LIB: https://github.com/apache/cordova-
 lib/compare/master...MSOpenTech:requirements_check
 Cordova-android: https://github.com/apache/cordova-
 android/compare/master...MSOpenTech:requirements_check
 
 The implementation consists of following:
 1. 'cordova check-reqs' command for cordova CLI, which calls 
 corresponding cordova-lib API with options, specified from CLI
 
 2. 'check_reqs' module for cordova-lib, which works as a wrapper 
 around platforms' check_reqs scripts. It returns a promise, either 
 resolved if check_reqs platform script is found and ran successfully 
 or rejected in case if check_reqs script is failed due to some internal 
 errors or not found at all.
 
 3. check_reqs script for android platform, updated to return array of 
 requirements.
 
 * Each requirements is an object with following fields:
 - id - some short id, could be useful for tools, that consume API 
 directly
 - name - readable name for this requirement, such as 'Jav JDK' 
 or 'Gradle build tools', etc.
 - installed - Boolean paremeter that indicates if requirement 
 is properly installed/satisfied
 - reason - error, reported by requirements check routines if 
 requirement is missing.
 
 Please note that work is still in progress, and will be changed 
 according to review comments.
 TBD:
 * move presentation logic from LIB to CLI;
 * refine data format, returned by cordova-lib API
 * add other platforms
 * and more... :)
 
 ---
 Best regards, Vladimir
 
 -Original Message-
 From: Parashuram N (MS OPEN TECH) [mailto:panar...@microsoft.com]
 Sent: Monday, 20 April, 2015 3:49
 To: dev@cordova.apache.org
 Subject: RE: Proposal: Expose check_reqs at the CLI level
 
 Looks like implementing a global level check_reqs without a project 
 seems harder, I would suggest we make it a part of a second phase of 
 this implementation. For now, we have a basic version that simply 
 abstracts out existing check_reqs into a separate, platform level 
 command. This could be a good first phase, and should also give us an 
 idea about how developers use this command.
 
 As a part of Phase 2, anyone from the community should be able to 
 build on a cordova level check reqs, and possibly extend it to 
 checking reqs when no project is present.
 
 
 -Original Message-
 From: Josh Soref

Re: Proposal: Expose check_reqs at the CLI level

2015-04-22 Thread Jesse
I liked 'doctor', I don't think it is cute, it is in use elsewhere.
The words always seem to be the hard part, here are some alternatives :

doctor
requirements
examine
exam
diagnose
check
audit
inspect
eval



@purplecabbage
risingj.com

On Wed, Apr 22, 2015 at 9:43 AM, Josh Soref jso...@blackberry.com wrote:

 We're going to type it often enough that I'd be upset at both check_reqs
 and check-requirements

 requirements is good enough.

  -Original Message-
  From: Treggiari, Leo [mailto:leo.treggi...@intel.com]
  Sent: Wednesday, April 22, 2015 11:11 AM
  To: dev@cordova.apache.org
  Subject: RE: Proposal: Expose check_reqs at the CLI level
 
  Hi Vladimir,
 
  It's great to see this being worked on and discussed.  My comments below
  are mine and mine alone.
 
  In addition to the code changes, I would have preferred to see a
 specification
  of the command, e.g.
 
cordova check-reqs platform [platform...]
 
  I took a quick look at the CLI code changes and didn't see any option
  processing.  Are there any options?
  Do the platform(s) specified on the command need to have been already
  added to the project?
  Does the command require a project - i.e. be executed in a project
 directory?
  Regarding the command name, I don't think being 'cute' is helpful to
 users -
  i.e. I recommend against 'doctor'.
  I think 'check-requirements' would be OK.  It's long but how many times
 does
  a user need to type it?
 
  Thanks,
  Leo
 
  -Original Message-
  From: Vladimir Kotikov (Akvelon) [mailto:v-vlk...@microsoft.com]
  Sent: Wednesday, April 22, 2015 7:18 AM
  To: dev@cordova.apache.org
  Subject: RE: Proposal: Expose check_reqs at the CLI level
 
  Hey, guys. Have anyone looked at it?
  I've made some refactoring to make changes more readable, and updated
  data contract between platform's check_reqs code and LIB API.
 
  Josh, regarding command name. I thought that there is still no agreement
  about verb name.
  Personally I agree that `cordova doctor` or `cordova requirements` sounds
  better, but this is just a command name ant it could be changed at any
 time.
 
  ---
  Best regards, Vladimir
 
  -Original Message-
  From: Parashuram N (MS OPEN TECH) [mailto:panar...@microsoft.com]
  Sent: Monday, 20 April, 2015 22:04
  To: dev@cordova.apache.org
  Subject: RE: Proposal: Expose check_reqs at the CLI level
 
  This was only an initial implementation - no pull request has been sent.
 I
  think this is just a way for folks to play with what Vlad has now. I am
 sure we
  will change the verb name before a PR comes in.
 
  -Original Message-
  From: Josh Soref [mailto:jso...@blackberry.com]
  Sent: Monday, April 20, 2015 11:59 AM
  To: dev@cordova.apache.org
  Subject: RE: Proposal: Expose check_reqs at the CLI level
 
  -1
 
  Didn't everyone agree to call it `cordova doctor` or worst, `cordova
  requirements`?
 
   -Original Message-
   From: Vladimir Kotikov (Akvelon) [mailto:v-vlk...@microsoft.com]
   Sent: Monday, April 20, 2015 11:46 AM
   To: dev@cordova.apache.org
   Subject: RE: Proposal: Expose check_reqs at the CLI level
  
   Hi, list.
  
   I would like to share a draft implementation for check_reqs command
   and check_reqs API:
   Changes  could be found here:
   CLI: https://github.com/apache/cordova-
   cli/compare/master...MSOpenTech:requirements_check
   LIB: https://github.com/apache/cordova-
   lib/compare/master...MSOpenTech:requirements_check
   Cordova-android: https://github.com/apache/cordova-
   android/compare/master...MSOpenTech:requirements_check
  
   The implementation consists of following:
   1. 'cordova check-reqs' command for cordova CLI, which calls
   corresponding cordova-lib API with options, specified from CLI
  
   2. 'check_reqs' module for cordova-lib, which works as a wrapper
   around platforms' check_reqs scripts. It returns a promise, either
   resolved if check_reqs platform script is found and ran successfully
   or rejected in case if check_reqs script is failed due to some
 internal errors
  or not found at all.
  
   3. check_reqs script for android platform, updated to return array of
   requirements.
  
   * Each requirements is an object with following fields:
   - id - some short id, could be useful for tools, that consume
 API directly
   - name - readable name for this requirement, such as 'Jav JDK'
   or 'Gradle build tools', etc.
   - installed - Boolean paremeter that indicates if requirement
   is properly installed/satisfied
   - reason - error, reported by requirements check routines if
   requirement is missing.
  
   Please note that work is still in progress, and will be changed
   according to review comments.
   TBD:
   * move presentation logic from LIB to CLI;
   * refine data format, returned by cordova-lib API
   * add other platforms
   * and more... :)
  
   ---
   Best regards, Vladimir

RE: Proposal: Expose check_reqs at the CLI level

2015-04-20 Thread Vladimir Kotikov (Akvelon)
Hi, list.

I would like to share a draft implementation for check_reqs command and 
check_reqs API: 
Changes  could be found here:
CLI: 
https://github.com/apache/cordova-cli/compare/master...MSOpenTech:requirements_check
 
LIB: 
https://github.com/apache/cordova-lib/compare/master...MSOpenTech:requirements_check
 
Cordova-android: 
https://github.com/apache/cordova-android/compare/master...MSOpenTech:requirements_check
 

The implementation consists of following:
1. 'cordova check-reqs' command for cordova CLI, which calls corresponding 
cordova-lib API with options, specified from CLI

2. 'check_reqs' module for cordova-lib, which works as a wrapper around 
platforms' check_reqs scripts. It returns a promise, either resolved if 
check_reqs platform script is found and ran successfully or rejected in case if 
check_reqs script is failed due to some internal errors or not found at all.

3. check_reqs script for android platform, updated to return array of 
requirements.

* Each requirements is an object with following fields: 
- id - some short id, could be useful for tools, that consume API 
directly
- name - readable name for this requirement, such as 'Jav JDK' or 
'Gradle build tools', etc.
- installed - Boolean paremeter that indicates if requirement is 
properly installed/satisfied
- reason - error, reported by requirements check routines if 
requirement is missing.

Please note that work is still in progress, and will be changed according to 
review comments.
TBD:
* move presentation logic from LIB to CLI;
* refine data format, returned by cordova-lib API
* add other platforms
* and more... :)

---
Best regards, Vladimir

-Original Message-
From: Parashuram N (MS OPEN TECH) [mailto:panar...@microsoft.com] 
Sent: Monday, 20 April, 2015 3:49
To: dev@cordova.apache.org
Subject: RE: Proposal: Expose check_reqs at the CLI level

Looks like implementing a global level check_reqs without a project seems 
harder, I would suggest we make it a part of a second phase of this 
implementation. For now, we have a basic version that simply abstracts out 
existing check_reqs into a separate, platform level command. This could be a 
good first phase, and should also give us an idea about how developers use this 
command.

As a part of Phase 2, anyone from the community should be able to build on a 
cordova level check reqs, and possibly extend it to checking reqs when no 
project is present. 


-Original Message-
From: Josh Soref [mailto:jso...@blackberry.com]
Sent: Wednesday, April 15, 2015 8:53 AM
To: dev@cordova.apache.org
Subject: RE: Proposal: Expose check_reqs at the CLI level

We already support:

`cordova build android`

There's no need for the extra `platform` verb..

But,
`cordova build android --nobuild` isn't any more intuitive than w/ the extra 
platform.


And yes, as I noted, and others have noted, we used to run check_reqs in add, 
we're not going back to doing that.

A `cordova doctor` or `cordova requirements` verb seems fine.

I'm also fine `cordova doctor PLATFORM` instead of `cordova platform doctor 
PLATFORM`,

As for when someone is likely to want to ask what requirements do I need for 
a platform, it's fairly arbitrary.

Someone who is given a project might know that they don't have the environment 
for a platform, they aren't likely to want to go down a build rabbit hole, 
so, I'm -1 on hiding it anywhere near build.

It's perfectly reasonable from my perspective for someone to want to run 
`cordova requirements PLATFORM` without a project at all.
Imagine someone is getting started, they install cordova, and know they want 
to develop for PLATFORM, they could reasonably want to set up their 
requirements for that platform before trying to create a project...

I don't know if anyone's check_reqs scripts actually requires a project, I 
actually think they don't, so it's probably sufficient to run them straight 
from the platform origin instead of from a created project.

One notable thing: check_reqs isn't a .js file yet, as an API, it's 
check_reqs (*nix) and check_reqs + something from %PATHEXT% (Windows)

 -Original Message-
 From: agri...@google.com [mailto:agri...@google.com] On Behalf Of
 Andrew Grieve
 Sent: Wednesday, April 15, 2015 11:00 AM
 To: dev
 Subject: Re: Proposal: Expose check_reqs at the CLI level

 We've worked to make iOS add'able from Windows, so I do think it's a good
 idea to *not* run check_reqs from add (we used to but removed it).

 We already run it on build, so potentially we already have this command:
 cordova platform build android --nobuild



 On Tue, Apr 14, 2015 at 9:51 PM, Treggiari, Leo leo.treggi...@intel.com
 wrote:

  My opinions.
 
  Q1.  Just say that platform is not added, so cannot check requirements.
 
  I don't think it is important to support the platform-not-added case.
 
  Q2.  Should the requirements be checked when a platform is added, or
 when

RE: Proposal: Expose check_reqs at the CLI level

2015-04-20 Thread Josh Soref
-1

Didn't everyone agree to call it `cordova doctor` or worst, `cordova 
requirements`?

 -Original Message-
 From: Vladimir Kotikov (Akvelon) [mailto:v-vlk...@microsoft.com]
 Sent: Monday, April 20, 2015 11:46 AM
 To: dev@cordova.apache.org
 Subject: RE: Proposal: Expose check_reqs at the CLI level
 
 Hi, list.
 
 I would like to share a draft implementation for check_reqs command and
 check_reqs API:
 Changes  could be found here:
 CLI: https://github.com/apache/cordova-
 cli/compare/master...MSOpenTech:requirements_check
 LIB: https://github.com/apache/cordova-
 lib/compare/master...MSOpenTech:requirements_check
 Cordova-android: https://github.com/apache/cordova-
 android/compare/master...MSOpenTech:requirements_check
 
 The implementation consists of following:
 1. 'cordova check-reqs' command for cordova CLI, which calls corresponding
 cordova-lib API with options, specified from CLI
 
 2. 'check_reqs' module for cordova-lib, which works as a wrapper around
 platforms' check_reqs scripts. It returns a promise, either resolved if
 check_reqs platform script is found and ran successfully or rejected in case 
 if
 check_reqs script is failed due to some internal errors or not found at all.
 
 3. check_reqs script for android platform, updated to return array of
 requirements.
 
 * Each requirements is an object with following fields:
 - id - some short id, could be useful for tools, that consume API 
 directly
 - name - readable name for this requirement, such as 'Jav JDK' or 
 'Gradle
 build tools', etc.
 - installed - Boolean paremeter that indicates if requirement is 
 properly
 installed/satisfied
 - reason - error, reported by requirements check routines if 
 requirement
 is missing.
 
 Please note that work is still in progress, and will be changed according to
 review comments.
 TBD:
 * move presentation logic from LIB to CLI;
 * refine data format, returned by cordova-lib API
 * add other platforms
 * and more... :)
 
 ---
 Best regards, Vladimir
 
 -Original Message-
 From: Parashuram N (MS OPEN TECH) [mailto:panar...@microsoft.com]
 Sent: Monday, 20 April, 2015 3:49
 To: dev@cordova.apache.org
 Subject: RE: Proposal: Expose check_reqs at the CLI level
 
 Looks like implementing a global level check_reqs without a project seems
 harder, I would suggest we make it a part of a second phase of this
 implementation. For now, we have a basic version that simply abstracts out
 existing check_reqs into a separate, platform level command. This could be a
 good first phase, and should also give us an idea about how developers use
 this command.
 
 As a part of Phase 2, anyone from the community should be able to build on
 a cordova level check reqs, and possibly extend it to checking reqs when no
 project is present.
 
 
 -Original Message-
 From: Josh Soref [mailto:jso...@blackberry.com]
 Sent: Wednesday, April 15, 2015 8:53 AM
 To: dev@cordova.apache.org
 Subject: RE: Proposal: Expose check_reqs at the CLI level
 
 We already support:
 
 `cordova build android`
 
 There's no need for the extra `platform` verb..
 
 But,
 `cordova build android --nobuild` isn't any more intuitive than w/ the extra
 platform.
 
 
 And yes, as I noted, and others have noted, we used to run check_reqs in
 add,
 we're not going back to doing that.
 
 A `cordova doctor` or `cordova requirements` verb seems fine.
 
 I'm also fine `cordova doctor PLATFORM` instead of `cordova platform doctor
 PLATFORM`,
 
 As for when someone is likely to want to ask what requirements do I need
 for
 a platform, it's fairly arbitrary.
 
 Someone who is given a project might know that they don't have the
 environment
 for a platform, they aren't likely to want to go down a build rabbit hole,
 so, I'm -1 on hiding it anywhere near build.
 
 It's perfectly reasonable from my perspective for someone to want to run
 `cordova requirements PLATFORM` without a project at all.
 Imagine someone is getting started, they install cordova, and know they
 want
 to develop for PLATFORM, they could reasonably want to set up their
 requirements for that platform before trying to create a project...
 
 I don't know if anyone's check_reqs scripts actually requires a project, I
 actually think they don't, so it's probably sufficient to run them straight
 from the platform origin instead of from a created project.
 
 One notable thing: check_reqs isn't a .js file yet, as an API, it's
 check_reqs (*nix) and check_reqs + something from %PATHEXT%
 (Windows)
 
  -Original Message-
  From: agri...@google.com [mailto:agri...@google.com] On Behalf Of
  Andrew Grieve
  Sent: Wednesday, April 15, 2015 11:00 AM
  To: dev
  Subject: Re: Proposal: Expose check_reqs at the CLI level
 
  We've worked to make iOS add'able from Windows, so I do think it's a good
  idea to *not* run check_reqs from add (we used to but removed it).
 
  We already run it on build, so

RE: Proposal: Expose check_reqs at the CLI level

2015-04-20 Thread Parashuram N (MS OPEN TECH)
This was only an initial implementation - no pull request has been sent. I 
think this is just a way for folks to play with what Vlad has now. I am sure we 
will change the verb name before a PR comes in. 

-Original Message-
From: Josh Soref [mailto:jso...@blackberry.com] 
Sent: Monday, April 20, 2015 11:59 AM
To: dev@cordova.apache.org
Subject: RE: Proposal: Expose check_reqs at the CLI level

-1

Didn't everyone agree to call it `cordova doctor` or worst, `cordova 
requirements`?

 -Original Message-
 From: Vladimir Kotikov (Akvelon) [mailto:v-vlk...@microsoft.com]
 Sent: Monday, April 20, 2015 11:46 AM
 To: dev@cordova.apache.org
 Subject: RE: Proposal: Expose check_reqs at the CLI level
 
 Hi, list.
 
 I would like to share a draft implementation for check_reqs command and
 check_reqs API:
 Changes  could be found here:
 CLI: https://github.com/apache/cordova-
 cli/compare/master...MSOpenTech:requirements_check
 LIB: https://github.com/apache/cordova-
 lib/compare/master...MSOpenTech:requirements_check
 Cordova-android: https://github.com/apache/cordova-
 android/compare/master...MSOpenTech:requirements_check
 
 The implementation consists of following:
 1. 'cordova check-reqs' command for cordova CLI, which calls corresponding
 cordova-lib API with options, specified from CLI
 
 2. 'check_reqs' module for cordova-lib, which works as a wrapper around
 platforms' check_reqs scripts. It returns a promise, either resolved if
 check_reqs platform script is found and ran successfully or rejected in case 
 if
 check_reqs script is failed due to some internal errors or not found at all.
 
 3. check_reqs script for android platform, updated to return array of
 requirements.
 
 * Each requirements is an object with following fields:
 - id - some short id, could be useful for tools, that consume API 
 directly
 - name - readable name for this requirement, such as 'Jav JDK' or 
 'Gradle
 build tools', etc.
 - installed - Boolean paremeter that indicates if requirement is 
 properly
 installed/satisfied
 - reason - error, reported by requirements check routines if 
 requirement
 is missing.
 
 Please note that work is still in progress, and will be changed according to
 review comments.
 TBD:
 * move presentation logic from LIB to CLI;
 * refine data format, returned by cordova-lib API
 * add other platforms
 * and more... :)
 
 ---
 Best regards, Vladimir
 
 -Original Message-
 From: Parashuram N (MS OPEN TECH) [mailto:panar...@microsoft.com]
 Sent: Monday, 20 April, 2015 3:49
 To: dev@cordova.apache.org
 Subject: RE: Proposal: Expose check_reqs at the CLI level
 
 Looks like implementing a global level check_reqs without a project seems
 harder, I would suggest we make it a part of a second phase of this
 implementation. For now, we have a basic version that simply abstracts out
 existing check_reqs into a separate, platform level command. This could be a
 good first phase, and should also give us an idea about how developers use
 this command.
 
 As a part of Phase 2, anyone from the community should be able to build on
 a cordova level check reqs, and possibly extend it to checking reqs when no
 project is present.
 
 
 -Original Message-
 From: Josh Soref [mailto:jso...@blackberry.com]
 Sent: Wednesday, April 15, 2015 8:53 AM
 To: dev@cordova.apache.org
 Subject: RE: Proposal: Expose check_reqs at the CLI level
 
 We already support:
 
 `cordova build android`
 
 There's no need for the extra `platform` verb..
 
 But,
 `cordova build android --nobuild` isn't any more intuitive than w/ the extra
 platform.
 
 
 And yes, as I noted, and others have noted, we used to run check_reqs in
 add,
 we're not going back to doing that.
 
 A `cordova doctor` or `cordova requirements` verb seems fine.
 
 I'm also fine `cordova doctor PLATFORM` instead of `cordova platform doctor
 PLATFORM`,
 
 As for when someone is likely to want to ask what requirements do I need
 for
 a platform, it's fairly arbitrary.
 
 Someone who is given a project might know that they don't have the
 environment
 for a platform, they aren't likely to want to go down a build rabbit hole,
 so, I'm -1 on hiding it anywhere near build.
 
 It's perfectly reasonable from my perspective for someone to want to run
 `cordova requirements PLATFORM` without a project at all.
 Imagine someone is getting started, they install cordova, and know they
 want
 to develop for PLATFORM, they could reasonably want to set up their
 requirements for that platform before trying to create a project...
 
 I don't know if anyone's check_reqs scripts actually requires a project, I
 actually think they don't, so it's probably sufficient to run them straight
 from the platform origin instead of from a created project.
 
 One notable thing: check_reqs isn't a .js file yet, as an API, it's
 check_reqs (*nix) and check_reqs + something from %PATHEXT%
 (Windows

Re: Proposal: Expose check_reqs at the CLI level

2015-04-15 Thread Andrew Grieve
We've worked to make iOS add'able from Windows, so I do think it's a good
idea to *not* run check_reqs from add (we used to but removed it).

We already run it on build, so potentially we already have this command:
cordova platform build android --nobuild



On Tue, Apr 14, 2015 at 9:51 PM, Treggiari, Leo leo.treggi...@intel.com
wrote:

 My opinions.

 Q1.  Just say that platform is not added, so cannot check requirements.

 I don't think it is important to support the platform-not-added case.

 Q2.  Should the requirements be checked when a platform is added, or when
 it is built ?

 'platform add' should work even when the requirements are not met.  If
 requirements
 used to be checked on 'platform add', then I suspect they were removed to
 support
 the scenario of using the same Cordova project on multiple host platforms.
 E.g. a team with some developers on Windows and some on Mac.  As a user of
 Cordova CLI on Windows, I want it to be OK to have the project I'm working
 on have the
 iOS platform added and I only get errors if I try to do something (build,
 emulate)
 which requires the native SDK.

 Leo

 -Original Message-
 From: Parashuram N (MS OPEN TECH) [mailto:panar...@microsoft.com]
 Sent: Tuesday, April 14, 2015 6:04 PM
 To: dev@cordova.apache.org
 Subject: RE: Proposal: Expose check_reqs at the CLI level

 I think you raise an interesting point on the behavior of check_reqs for
 platform that are not yet added.

 The options, as you mention are

 Question 1
 1 -  Add the platform, run check_reqs script, remove the platform and
 report results.
 1.5 - Just download the check_reqs script (or use it from the cached
 platform directory) without adding the platform, and run that.
 2 -  Just say that platform is not added, so cannot check requirements.

 Question 2: It also comes to the case of - when would a user want to run
 the requirement check
 - before starting a cordova project ?
 - before adding a platform ?
 - should the requirements be checked when a platform is added, or when it
 is built ?

 The answer to the above questions will help us understand if a top level
 req_check is required or not. We should also look at what check_reqs do
 today - the do not tell you ALL the missing pieces for building an SDK.

 It would be good to hear what the others in the community think about
 these answers.

 -Original Message-
 From: Josh Soref [mailto:jso...@blackberry.com]
 Sent: Tuesday, April 14, 2015 9:55 AM
 To: dev@cordova.apache.org
 Subject: RE: Proposal: Expose check_reqs at the CLI level

 Fwiw, for the case of a platform that isn't in a project yet, I'd envision:

 `cordova platform doctor not-yet-installed`

 to do effectively:
 ```sh
 (
 PLATFORM=not-yet-installed
 (cordova platform add $PLATFORM 21)  /dev/null 
 cordova platform doctor $PLATFORM;
 (cordova platform remove $PLATFORM 21)
 )
 ```

 i.e. add the platform (or create a temporary project, and add the platform
 to the temporary project), and then run platform doctor, and then remove
 the
 platform (and if it was in a temporary project, delete the temporary
 project...).

 I don't really want to expos a 'check_reqs' verb via CLI.

 If we really really want to, we could have `cordova platform requirements
 [PLATFORM...]` as a verb, that's ok.

 If someone wants to call `check_reqs` directly, they're welcome to do so,
 but it's an incredibly ugly thing and doesn't belong in a public facing
 interface.


  -Original Message-
  From: Parashuram N (MS OPEN TECH) [mailto:panar...@microsoft.com]
  Sent: Tuesday, April 14, 2015 10:19 AM
  To: dev@cordova.apache.org
  Subject: Re: Proposal: Expose check_reqs at the CLI level
 
  Carlos, you are right, check_reqs should be in the platform repo, CLI
 will
  just proxy the call to the platforms.
 
  On 4/13/15, 10:29 PM, Carlos Santana csantan...@gmail.com wrote:
 
  +1 if check_reqs are kept in the platform repos, currently check_reqs is
 a
  platform concerned
  if it's available from CLI it will be just a proxy to the platform
  check_reqs.
  
  if don't keep it in the platform repo, and add this logic to cli repo,
 we
  will need to maintained a list of reqs for each platform, for each
 version
  of each platform.
  
  This is the reason why it was removed from cli and just is present in
 the
  platform repo/code
  
  
  
  On Mon, Apr 13, 2015 at 5:13 PM, Josh Soref jso...@blackberry.com
  wrote:
  
   I'm +1 for `cordova doctor` and `cordova platform doctor
  {platformname}`.
  
   The former should apply to all current platforms, the latter should
  support
   doctoring for available but not added platforms -- if said platform
 were
   specified.
   And we should note in the documentation or `cordova doctor` that it
 may
  do
   other checks -- e.g. linting the config.xml, warning about CSP,
 possibly
   mentioning when a plugin is out of date -- just to indicate to people
  that
   the behavior may evolve.
  
   Not that this is more or less fixing

RE: Proposal: Expose check_reqs at the CLI level

2015-04-15 Thread Josh Soref
We already support:

`cordova build android`

There's no need for the extra `platform` verb..

But,
`cordova build android --nobuild` isn't any more intuitive than w/ the extra 
platform.


And yes, as I noted, and others have noted, we used to run check_reqs in add, 
we're not going back to doing that.

A `cordova doctor` or `cordova requirements` verb seems fine.

I'm also fine `cordova doctor PLATFORM` instead of `cordova platform doctor 
PLATFORM`,

As for when someone is likely to want to ask what requirements do I need for 
a platform, it's fairly arbitrary.

Someone who is given a project might know that they don't have the environment 
for a platform, they aren't likely to want to go down a build rabbit hole, 
so, I'm -1 on hiding it anywhere near build.

It's perfectly reasonable from my perspective for someone to want to run 
`cordova requirements PLATFORM` without a project at all.
Imagine someone is getting started, they install cordova, and know they want 
to develop for PLATFORM, they could reasonably want to set up their 
requirements for that platform before trying to create a project...

I don't know if anyone's check_reqs scripts actually requires a project, I 
actually think they don't, so it's probably sufficient to run them straight 
from the platform origin instead of from a created project.

One notable thing: check_reqs isn't a .js file yet, as an API, it's 
check_reqs (*nix) and check_reqs + something from %PATHEXT% (Windows)

 -Original Message-
 From: agri...@google.com [mailto:agri...@google.com] On Behalf Of
 Andrew Grieve
 Sent: Wednesday, April 15, 2015 11:00 AM
 To: dev
 Subject: Re: Proposal: Expose check_reqs at the CLI level

 We've worked to make iOS add'able from Windows, so I do think it's a good
 idea to *not* run check_reqs from add (we used to but removed it).

 We already run it on build, so potentially we already have this command:
 cordova platform build android --nobuild



 On Tue, Apr 14, 2015 at 9:51 PM, Treggiari, Leo leo.treggi...@intel.com
 wrote:

  My opinions.
 
  Q1.  Just say that platform is not added, so cannot check requirements.
 
  I don't think it is important to support the platform-not-added case.
 
  Q2.  Should the requirements be checked when a platform is added, or
 when
  it is built ?
 
  'platform add' should work even when the requirements are not met.  If
  requirements
  used to be checked on 'platform add', then I suspect they were removed to
  support
  the scenario of using the same Cordova project on multiple host platforms.
  E.g. a team with some developers on Windows and some on Mac.  As a user
 of
  Cordova CLI on Windows, I want it to be OK to have the project I'm working
  on have the
  iOS platform added and I only get errors if I try to do something (build,
  emulate)
  which requires the native SDK.
 
  Leo
 
  -Original Message-
  From: Parashuram N (MS OPEN TECH) [mailto:panar...@microsoft.com]
  Sent: Tuesday, April 14, 2015 6:04 PM
  To: dev@cordova.apache.org
  Subject: RE: Proposal: Expose check_reqs at the CLI level
 
  I think you raise an interesting point on the behavior of check_reqs for
  platform that are not yet added.
 
  The options, as you mention are
 
  Question 1
  1 -  Add the platform, run check_reqs script, remove the platform and
  report results.
  1.5 - Just download the check_reqs script (or use it from the cached
  platform directory) without adding the platform, and run that.
  2 -  Just say that platform is not added, so cannot check requirements.
 
  Question 2: It also comes to the case of - when would a user want to run
  the requirement check
  - before starting a cordova project ?
  - before adding a platform ?
  - should the requirements be checked when a platform is added, or when it
  is built ?
 
  The answer to the above questions will help us understand if a top level
  req_check is required or not. We should also look at what check_reqs do
  today - the do not tell you ALL the missing pieces for building an SDK.
 
  It would be good to hear what the others in the community think about
  these answers.
 
  -Original Message-
  From: Josh Soref [mailto:jso...@blackberry.com]
  Sent: Tuesday, April 14, 2015 9:55 AM
  To: dev@cordova.apache.org
  Subject: RE: Proposal: Expose check_reqs at the CLI level
 
  Fwiw, for the case of a platform that isn't in a project yet, I'd 
  envision:
 
  `cordova platform doctor not-yet-installed`
 
  to do effectively:
  ```sh
  (
  PLATFORM=not-yet-installed
  (cordova platform add $PLATFORM 21)  /dev/null 
  cordova platform doctor $PLATFORM;
  (cordova platform remove $PLATFORM 21)
  )
  ```
 
  i.e. add the platform (or create a temporary project, and add the platform
  to the temporary project), and then run platform doctor, and then remove
  the
  platform (and if it was in a temporary project, delete the temporary
  project...).
 
  I don't really want to expos a 'check_reqs' verb via CLI.
 
  If we really really

Re: Proposal: Expose check_reqs at the CLI level

2015-04-15 Thread julio cesar sanchez
+1 to Josh, I think it should be possible to check even before you create a
project


El miércoles, 15 de abril de 2015, Josh Soref jso...@blackberry.com
escribió:

 We already support:

 `cordova build android`

 There's no need for the extra `platform` verb..

 But,
 `cordova build android --nobuild` isn't any more intuitive than w/ the
 extra
 platform.


 And yes, as I noted, and others have noted, we used to run check_reqs in
 add,
 we're not going back to doing that.

 A `cordova doctor` or `cordova requirements` verb seems fine.

 I'm also fine `cordova doctor PLATFORM` instead of `cordova platform doctor
 PLATFORM`,

 As for when someone is likely to want to ask what requirements do I need
 for
 a platform, it's fairly arbitrary.

 Someone who is given a project might know that they don't have the
 environment
 for a platform, they aren't likely to want to go down a build rabbit
 hole,
 so, I'm -1 on hiding it anywhere near build.

 It's perfectly reasonable from my perspective for someone to want to run
 `cordova requirements PLATFORM` without a project at all.
 Imagine someone is getting started, they install cordova, and know they
 want
 to develop for PLATFORM, they could reasonably want to set up their
 requirements for that platform before trying to create a project...

 I don't know if anyone's check_reqs scripts actually requires a project, I
 actually think they don't, so it's probably sufficient to run them straight
 from the platform origin instead of from a created project.

 One notable thing: check_reqs isn't a .js file yet, as an API, it's
 check_reqs (*nix) and check_reqs + something from %PATHEXT% (Windows)

  -Original Message-
  From: agri...@google.com javascript:; [mailto:agri...@google.com
 javascript:;] On Behalf Of
  Andrew Grieve
  Sent: Wednesday, April 15, 2015 11:00 AM
  To: dev
  Subject: Re: Proposal: Expose check_reqs at the CLI level
 
  We've worked to make iOS add'able from Windows, so I do think it's a good
  idea to *not* run check_reqs from add (we used to but removed it).
 
  We already run it on build, so potentially we already have this command:
  cordova platform build android --nobuild
 
 
 
  On Tue, Apr 14, 2015 at 9:51 PM, Treggiari, Leo leo.treggi...@intel.com
 javascript:;
  wrote:
 
   My opinions.
  
   Q1.  Just say that platform is not added, so cannot check requirements.
  
   I don't think it is important to support the platform-not-added case.
  
   Q2.  Should the requirements be checked when a platform is added, or
  when
   it is built ?
  
   'platform add' should work even when the requirements are not met.  If
   requirements
   used to be checked on 'platform add', then I suspect they were removed
 to
   support
   the scenario of using the same Cordova project on multiple host
 platforms.
   E.g. a team with some developers on Windows and some on Mac.  As a user
  of
   Cordova CLI on Windows, I want it to be OK to have the project I'm
 working
   on have the
   iOS platform added and I only get errors if I try to do something
 (build,
   emulate)
   which requires the native SDK.
  
   Leo
  
   -Original Message-
   From: Parashuram N (MS OPEN TECH) [mailto:panar...@microsoft.com
 javascript:;]
   Sent: Tuesday, April 14, 2015 6:04 PM
   To: dev@cordova.apache.org javascript:;
   Subject: RE: Proposal: Expose check_reqs at the CLI level
  
   I think you raise an interesting point on the behavior of check_reqs
 for
   platform that are not yet added.
  
   The options, as you mention are
  
   Question 1
   1 -  Add the platform, run check_reqs script, remove the platform and
   report results.
   1.5 - Just download the check_reqs script (or use it from the cached
   platform directory) without adding the platform, and run that.
   2 -  Just say that platform is not added, so cannot check requirements.
  
   Question 2: It also comes to the case of - when would a user want to
 run
   the requirement check
   - before starting a cordova project ?
   - before adding a platform ?
   - should the requirements be checked when a platform is added, or when
 it
   is built ?
  
   The answer to the above questions will help us understand if a top
 level
   req_check is required or not. We should also look at what check_reqs do
   today - the do not tell you ALL the missing pieces for building an SDK.
  
   It would be good to hear what the others in the community think about
   these answers.
  
   -Original Message-
   From: Josh Soref [mailto:jso...@blackberry.com javascript:;]
   Sent: Tuesday, April 14, 2015 9:55 AM
   To: dev@cordova.apache.org javascript:;
   Subject: RE: Proposal: Expose check_reqs at the CLI level
  
   Fwiw, for the case of a platform that isn't in a project yet, I'd
   envision:
  
   `cordova platform doctor not-yet-installed`
  
   to do effectively:
   ```sh
   (
   PLATFORM=not-yet-installed
   (cordova platform add $PLATFORM 21)  /dev/null 
   cordova platform doctor $PLATFORM

Re: Proposal: Expose check_reqs at the CLI level

2015-04-14 Thread Sachax
Absolutely +1

Sent from my iPhone - 4eSPJ
Sacha Herbert





Website:www.sachax.com
Studio: Via A. Bertani, 20a - 00153 Roma
Office: +39 06 933 798 66
Mobile: +39 392 188 0793
Twitter:sachax08
Skype:  as3_master



 




Il presente messaggio e-mail contiene informazioni confidenziali indirizzate 
esclusivamente alle persone sopra indicate. Se il ricevente non è tra dette 
persone, il presente messaggio e-mail non dovrà essere copiato, reso noto o 
altrimenti distribuito in alcun modo. Se avete per errore ricevuto il presente 
messaggio, informate di ciò  il mittente con urgenza e cancellate il messaggio 
dal vostro sistema. Trasmissioni via e-mail non possono essere garantite in 
merito alla loro sicurezza o correttezza poiché mezzi di comunicazione che 
possono essere intercettati, corrotti, persi, distrutti, trasmessi in ritardo o 
in modo incompleto, nonche' contenenti virus. Il mittente perciò non potra' 
accettare alcuna responsabilità per errori o omissioni nei contenuti del 
presente messaggio, quale conseguenza della suatrasmissione.  Qualora fosse 
necessaria una verifica, siete pregati di richiedere  copia cartacea del 
presente messaggio.
This message contains confidential information and is intended only for the 
named addressee. If you are not named addressee you should not copy or 
distribute this e-mail. If you have received this e-mail by mistake,please 
notify the sender immediately and delete this e-mail from your system. E-mail 
transmission cannot be guaranteed to be secure or error-free as information 
could be intercepted, corrupted, lost, destroyed, arrivelate or incomplete, or 
contain viruses. The sender therefore does not accept liability for any errors 
or omissions in the contents of this message which arise as a result of e-mail 
transmission. If verification is required please request a hard-copy version.


 On 13 Apr 2015, at 20:53, Parashuram N (MS OPEN TECH) 
 panar...@microsoft.com wrote:
 
 Hi,
 
 One of the main problems a lot of developers seem to have is the issue to 
 setting up their machines for building various platforms. This came out from 
 the Stack overflow survey, and the number of questions on stack overflow, 
 twitter. Etc.
 
 I thought it would be helpful to have a check_reqs command exposed at the CLI 
 level. This is similar to `brew doctor` or `appium doctor`. The idea is
 
 
 1.   Have a way for the user to see if they have all dependencies (like 
 JAVA_HOME or ANDROID_HOME) set up? This happens at build time, but moving it 
 out to a CLI level command where you can run cordova check_reqs (or something 
 similar) would be useful to the users.
 
 2.   Today, the build command shows one error at a time. The check_reqs 
 could run all the checks, and show a summary of the issues so that the user 
 can fix them all, instead of fixing one, running build, fixing again, etc.
 
 What does the community think of this idea ? Can we implement a prototype and 
 see if this is useful to our developers ?
 Note that this does not change or break existing functionality - it just 
 exposes the already existing check_reqs in the CLI. Build will continue to 
 call check_reqs.
 
 Please vote on this proposal, or raise any concerns you may have.


Re: Proposal: Expose check_reqs at the CLI level

2015-04-14 Thread Parashuram N (MS OPEN TECH)
Carlos, you are right, check_reqs should be in the platform repo, CLI will
just proxy the call to the platforms.

On 4/13/15, 10:29 PM, Carlos Santana csantan...@gmail.com wrote:

+1 if check_reqs are kept in the platform repos, currently check_reqs is a
platform concerned
if it's available from CLI it will be just a proxy to the platform
check_reqs.

if don't keep it in the platform repo, and add this logic to cli repo, we
will need to maintained a list of reqs for each platform, for each version
of each platform.

This is the reason why it was removed from cli and just is present in the
platform repo/code



On Mon, Apr 13, 2015 at 5:13 PM, Josh Soref jso...@blackberry.com wrote:

 I'm +1 for `cordova doctor` and `cordova platform doctor
{platformname}`.

 The former should apply to all current platforms, the latter should
support
 doctoring for available but not added platforms -- if said platform were
 specified.
 And we should note in the documentation or `cordova doctor` that it may
do
 other checks -- e.g. linting the config.xml, warning about CSP, possibly
 mentioning when a plugin is out of date -- just to indicate to people
that
 the behavior may evolve.

 Not that this is more or less fixing a regression that we introduced
when
 we
 made `cordova platform add` not call check_reqs.

  -Original Message-
  From: Parashuram N (MS OPEN TECH) [mailto:panar...@microsoft.com]
  Sent: Monday, April 13, 2015 2:53 PM
  To: dev@cordova.apache.org
  Subject: Proposal: Expose check_reqs at the CLI level
 
  Hi,
 
  One of the main problems a lot of developers seem to have is the
issue to
  setting up their machines for building various platforms. This came
out
 from
  the Stack overflow survey, and the number of questions on stack
overflow,
  twitter. Etc.
 
  I thought it would be helpful to have a check_reqs command exposed at
the
  CLI level. This is similar to `brew doctor` or `appium doctor`. The
idea
 is
 
 
  1.   Have a way for the user to see if they have all dependencies
 (like
  JAVA_HOME or ANDROID_HOME) set up? This happens at build time, but
  moving it out to a CLI level command where you can run cordova
check_reqs
  (or something similar) would be useful to the users.
 
  2.   Today, the build command shows one error at a time. The
 check_reqs
  could run all the checks, and show a summary of the issues so that the
 user
  can fix them all, instead of fixing one, running build, fixing again,
 etc.
 
  What does the community think of this idea ? Can we implement a
prototype
  and see if this is useful to our developers ?
  Note that this does not change or break existing functionality - it
just
 exposes
  the already existing check_reqs in the CLI. Build will continue to
call
  check_reqs.
 
  Please vote on this proposal, or raise any concerns you may have.




-- 
Carlos Santana
csantan...@gmail.com


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



RE: Proposal: Expose check_reqs at the CLI level

2015-04-14 Thread Parashuram N (MS OPEN TECH)
I think you raise an interesting point on the behavior of check_reqs for 
platform that are not yet added. 

The options, as you mention are 

Question 1
1 -  Add the platform, run check_reqs script, remove the platform and report 
results.
1.5 - Just download the check_reqs script (or use it from the cached platform 
directory) without adding the platform, and run that. 
2 -  Just say that platform is not added, so cannot check requirements. 

Question 2: It also comes to the case of - when would a user want to run the 
requirement check
- before starting a cordova project ?
- before adding a platform ? 
- should the requirements be checked when a platform is added, or when it is 
built ? 

The answer to the above questions will help us understand if a top level 
req_check is required or not. We should also look at what check_reqs do today - 
the do not tell you ALL the missing pieces for building an SDK.

It would be good to hear what the others in the community think about these 
answers. 

-Original Message-
From: Josh Soref [mailto:jso...@blackberry.com] 
Sent: Tuesday, April 14, 2015 9:55 AM
To: dev@cordova.apache.org
Subject: RE: Proposal: Expose check_reqs at the CLI level

Fwiw, for the case of a platform that isn't in a project yet, I'd envision:

`cordova platform doctor not-yet-installed`

to do effectively:
```sh
(
PLATFORM=not-yet-installed
(cordova platform add $PLATFORM 21)  /dev/null 
cordova platform doctor $PLATFORM;
(cordova platform remove $PLATFORM 21)
)
```

i.e. add the platform (or create a temporary project, and add the platform
to the temporary project), and then run platform doctor, and then remove the
platform (and if it was in a temporary project, delete the temporary
project...).

I don't really want to expos a 'check_reqs' verb via CLI.

If we really really want to, we could have `cordova platform requirements
[PLATFORM...]` as a verb, that's ok.

If someone wants to call `check_reqs` directly, they're welcome to do so,
but it's an incredibly ugly thing and doesn't belong in a public facing
interface.


 -Original Message-
 From: Parashuram N (MS OPEN TECH) [mailto:panar...@microsoft.com]
 Sent: Tuesday, April 14, 2015 10:19 AM
 To: dev@cordova.apache.org
 Subject: Re: Proposal: Expose check_reqs at the CLI level
 
 Carlos, you are right, check_reqs should be in the platform repo, CLI will
 just proxy the call to the platforms.
 
 On 4/13/15, 10:29 PM, Carlos Santana csantan...@gmail.com wrote:
 
 +1 if check_reqs are kept in the platform repos, currently check_reqs is
a
 platform concerned
 if it's available from CLI it will be just a proxy to the platform
 check_reqs.
 
 if don't keep it in the platform repo, and add this logic to cli repo, we
 will need to maintained a list of reqs for each platform, for each
version
 of each platform.
 
 This is the reason why it was removed from cli and just is present in the
 platform repo/code
 
 
 
 On Mon, Apr 13, 2015 at 5:13 PM, Josh Soref jso...@blackberry.com
 wrote:
 
  I'm +1 for `cordova doctor` and `cordova platform doctor
 {platformname}`.
 
  The former should apply to all current platforms, the latter should
 support
  doctoring for available but not added platforms -- if said platform
were
  specified.
  And we should note in the documentation or `cordova doctor` that it may
 do
  other checks -- e.g. linting the config.xml, warning about CSP,
possibly
  mentioning when a plugin is out of date -- just to indicate to people
 that
  the behavior may evolve.
 
  Not that this is more or less fixing a regression that we introduced
 when
  we
  made `cordova platform add` not call check_reqs.
 
   -Original Message-
   From: Parashuram N (MS OPEN TECH) [mailto:panar...@microsoft.com]
   Sent: Monday, April 13, 2015 2:53 PM
   To: dev@cordova.apache.org
   Subject: Proposal: Expose check_reqs at the CLI level
  
   Hi,
  
   One of the main problems a lot of developers seem to have is the
 issue to
   setting up their machines for building various platforms. This came
 out
  from
   the Stack overflow survey, and the number of questions on stack
 overflow,
   twitter. Etc.
  
   I thought it would be helpful to have a check_reqs command exposed at
 the
   CLI level. This is similar to `brew doctor` or `appium doctor`. The
 idea
  is
  
  
   1.   Have a way for the user to see if they have all dependencies
  (like
   JAVA_HOME or ANDROID_HOME) set up? This happens at build time, but
   moving it out to a CLI level command where you can run cordova
 check_reqs
   (or something similar) would be useful to the users.
  
   2.   Today, the build command shows one error at a time. The
  check_reqs
   could run all the checks, and show a summary of the issues so that
the
  user
   can fix them all, instead of fixing one, running build, fixing again,
  etc.
  
   What does the community think of this idea ? Can we implement a
 prototype
   and see if this is useful to our developers ?
   Note

RE: Proposal: Expose check_reqs at the CLI level

2015-04-14 Thread Treggiari, Leo
My opinions.

Q1.  Just say that platform is not added, so cannot check requirements. 

I don't think it is important to support the platform-not-added case.

Q2.  Should the requirements be checked when a platform is added, or when it is 
built ?

'platform add' should work even when the requirements are not met.  If 
requirements 
used to be checked on 'platform add', then I suspect they were removed to 
support
the scenario of using the same Cordova project on multiple host platforms.
E.g. a team with some developers on Windows and some on Mac.  As a user of
Cordova CLI on Windows, I want it to be OK to have the project I'm working on 
have the 
iOS platform added and I only get errors if I try to do something (build, 
emulate) 
which requires the native SDK.

Leo

-Original Message-
From: Parashuram N (MS OPEN TECH) [mailto:panar...@microsoft.com] 
Sent: Tuesday, April 14, 2015 6:04 PM
To: dev@cordova.apache.org
Subject: RE: Proposal: Expose check_reqs at the CLI level

I think you raise an interesting point on the behavior of check_reqs for 
platform that are not yet added. 

The options, as you mention are 

Question 1
1 -  Add the platform, run check_reqs script, remove the platform and report 
results.
1.5 - Just download the check_reqs script (or use it from the cached platform 
directory) without adding the platform, and run that. 
2 -  Just say that platform is not added, so cannot check requirements. 

Question 2: It also comes to the case of - when would a user want to run the 
requirement check
- before starting a cordova project ?
- before adding a platform ? 
- should the requirements be checked when a platform is added, or when it is 
built ? 

The answer to the above questions will help us understand if a top level 
req_check is required or not. We should also look at what check_reqs do today - 
the do not tell you ALL the missing pieces for building an SDK.

It would be good to hear what the others in the community think about these 
answers. 

-Original Message-
From: Josh Soref [mailto:jso...@blackberry.com] 
Sent: Tuesday, April 14, 2015 9:55 AM
To: dev@cordova.apache.org
Subject: RE: Proposal: Expose check_reqs at the CLI level

Fwiw, for the case of a platform that isn't in a project yet, I'd envision:

`cordova platform doctor not-yet-installed`

to do effectively:
```sh
(
PLATFORM=not-yet-installed
(cordova platform add $PLATFORM 21)  /dev/null 
cordova platform doctor $PLATFORM;
(cordova platform remove $PLATFORM 21)
)
```

i.e. add the platform (or create a temporary project, and add the platform
to the temporary project), and then run platform doctor, and then remove the
platform (and if it was in a temporary project, delete the temporary
project...).

I don't really want to expos a 'check_reqs' verb via CLI.

If we really really want to, we could have `cordova platform requirements
[PLATFORM...]` as a verb, that's ok.

If someone wants to call `check_reqs` directly, they're welcome to do so,
but it's an incredibly ugly thing and doesn't belong in a public facing
interface.


 -Original Message-
 From: Parashuram N (MS OPEN TECH) [mailto:panar...@microsoft.com]
 Sent: Tuesday, April 14, 2015 10:19 AM
 To: dev@cordova.apache.org
 Subject: Re: Proposal: Expose check_reqs at the CLI level
 
 Carlos, you are right, check_reqs should be in the platform repo, CLI will
 just proxy the call to the platforms.
 
 On 4/13/15, 10:29 PM, Carlos Santana csantan...@gmail.com wrote:
 
 +1 if check_reqs are kept in the platform repos, currently check_reqs is
a
 platform concerned
 if it's available from CLI it will be just a proxy to the platform
 check_reqs.
 
 if don't keep it in the platform repo, and add this logic to cli repo, we
 will need to maintained a list of reqs for each platform, for each
version
 of each platform.
 
 This is the reason why it was removed from cli and just is present in the
 platform repo/code
 
 
 
 On Mon, Apr 13, 2015 at 5:13 PM, Josh Soref jso...@blackberry.com
 wrote:
 
  I'm +1 for `cordova doctor` and `cordova platform doctor
 {platformname}`.
 
  The former should apply to all current platforms, the latter should
 support
  doctoring for available but not added platforms -- if said platform
were
  specified.
  And we should note in the documentation or `cordova doctor` that it may
 do
  other checks -- e.g. linting the config.xml, warning about CSP,
possibly
  mentioning when a plugin is out of date -- just to indicate to people
 that
  the behavior may evolve.
 
  Not that this is more or less fixing a regression that we introduced
 when
  we
  made `cordova platform add` not call check_reqs.
 
   -Original Message-
   From: Parashuram N (MS OPEN TECH) [mailto:panar...@microsoft.com]
   Sent: Monday, April 13, 2015 2:53 PM
   To: dev@cordova.apache.org
   Subject: Proposal: Expose check_reqs at the CLI level
  
   Hi,
  
   One of the main problems a lot of developers seem to have is the
 issue to
   setting up

Re: Proposal: Expose check_reqs at the CLI level

2015-04-13 Thread taylor
I recently got started with Cordova and this was one of my biggest problems. It 
would be even better if the command could provide hints on how to fix the 
issues. 




Regards,
Taylor Gibb


CEO and Founder - Developer Hut | Microsoft MVP | FoRG 





From: Shazron
Sent: ‎Monday‎, ‎April‎ ‎13‎, ‎2015 ‎8‎:‎56‎ ‎PM
To: dev@cordova.apache.org





+1
This will be great for users

On Mon, Apr 13, 2015 at 11:53 AM, Parashuram N (MS OPEN TECH)
panar...@microsoft.com wrote:
 Hi,

 One of the main problems a lot of developers seem to have is the issue to 
 setting up their machines for building various platforms. This came out from 
 the Stack overflow survey, and the number of questions on stack overflow, 
 twitter. Etc.

 I thought it would be helpful to have a check_reqs command exposed at the CLI 
 level. This is similar to `brew doctor` or `appium doctor`. The idea is


 1.   Have a way for the user to see if they have all dependencies (like 
 JAVA_HOME or ANDROID_HOME) set up? This happens at build time, but moving it 
 out to a CLI level command where you can run cordova check_reqs (or something 
 similar) would be useful to the users.

 2.   Today, the build command shows one error at a time. The check_reqs 
 could run all the checks, and show a summary of the issues so that the user 
 can fix them all, instead of fixing one, running build, fixing again, etc.

 What does the community think of this idea ? Can we implement a prototype and 
 see if this is useful to our developers ?
 Note that this does not change or break existing functionality - it just 
 exposes the already existing check_reqs in the CLI. Build will continue to 
 call check_reqs.

 Please vote on this proposal, or raise any concerns you may have.

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

Re: Proposal: Expose check_reqs at the CLI level

2015-04-13 Thread Jesse
+1
Sounds great!

@purplecabbage
risingj.com

On Mon, Apr 13, 2015 at 11:56 AM, Shazron shaz...@gmail.com wrote:

 +1
 This will be great for users

 On Mon, Apr 13, 2015 at 11:53 AM, Parashuram N (MS OPEN TECH)
 panar...@microsoft.com wrote:
  Hi,
 
  One of the main problems a lot of developers seem to have is the issue
 to setting up their machines for building various platforms. This came out
 from the Stack overflow survey, and the number of questions on stack
 overflow, twitter. Etc.
 
  I thought it would be helpful to have a check_reqs command exposed at
 the CLI level. This is similar to `brew doctor` or `appium doctor`. The
 idea is
 
 
  1.   Have a way for the user to see if they have all dependencies
 (like JAVA_HOME or ANDROID_HOME) set up? This happens at build time, but
 moving it out to a CLI level command where you can run cordova check_reqs
 (or something similar) would be useful to the users.
 
  2.   Today, the build command shows one error at a time. The
 check_reqs could run all the checks, and show a summary of the issues so
 that the user can fix them all, instead of fixing one, running build,
 fixing again, etc.
 
  What does the community think of this idea ? Can we implement a
 prototype and see if this is useful to our developers ?
  Note that this does not change or break existing functionality - it just
 exposes the already existing check_reqs in the CLI. Build will continue to
 call check_reqs.
 
  Please vote on this proposal, or raise any concerns you may have.

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




Re: Proposal: Expose check_reqs at the CLI level

2015-04-13 Thread Shazron
+1
This will be great for users

On Mon, Apr 13, 2015 at 11:53 AM, Parashuram N (MS OPEN TECH)
panar...@microsoft.com wrote:
 Hi,

 One of the main problems a lot of developers seem to have is the issue to 
 setting up their machines for building various platforms. This came out from 
 the Stack overflow survey, and the number of questions on stack overflow, 
 twitter. Etc.

 I thought it would be helpful to have a check_reqs command exposed at the CLI 
 level. This is similar to `brew doctor` or `appium doctor`. The idea is


 1.   Have a way for the user to see if they have all dependencies (like 
 JAVA_HOME or ANDROID_HOME) set up? This happens at build time, but moving it 
 out to a CLI level command where you can run cordova check_reqs (or something 
 similar) would be useful to the users.

 2.   Today, the build command shows one error at a time. The check_reqs 
 could run all the checks, and show a summary of the issues so that the user 
 can fix them all, instead of fixing one, running build, fixing again, etc.

 What does the community think of this idea ? Can we implement a prototype and 
 see if this is useful to our developers ?
 Note that this does not change or break existing functionality - it just 
 exposes the already existing check_reqs in the CLI. Build will continue to 
 call check_reqs.

 Please vote on this proposal, or raise any concerns you may have.

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



RE: Proposal: Expose check_reqs at the CLI level

2015-04-13 Thread Dmitry Blotsky
+1 for me too, even though my +1 points don't matter :)

I've actually run into this issue when writing documentation for setting up 
slaves for medic. My short documentation is here: 
https://github.com/apache/cordova-medic/blob/master/SLAVES.md, but it is best 
for it to refer to the official Cordova docs instead.

Should we make a JIRA task for better docs and automated platform dependency 
detection?

Kindly,
Dmitry

-Original Message-
From: Shazron [mailto:shaz...@gmail.com] 
Sent: Monday, April 13, 2015 11:56 AM
To: dev@cordova.apache.org
Subject: Re: Proposal: Expose check_reqs at the CLI level

+1
This will be great for users

On Mon, Apr 13, 2015 at 11:53 AM, Parashuram N (MS OPEN TECH) 
panar...@microsoft.com wrote:
 Hi,

 One of the main problems a lot of developers seem to have is the issue to 
 setting up their machines for building various platforms. This came out from 
 the Stack overflow survey, and the number of questions on stack overflow, 
 twitter. Etc.

 I thought it would be helpful to have a check_reqs command exposed at 
 the CLI level. This is similar to `brew doctor` or `appium doctor`. 
 The idea is


 1.   Have a way for the user to see if they have all dependencies (like 
 JAVA_HOME or ANDROID_HOME) set up? This happens at build time, but moving it 
 out to a CLI level command where you can run cordova check_reqs (or something 
 similar) would be useful to the users.

 2.   Today, the build command shows one error at a time. The check_reqs 
 could run all the checks, and show a summary of the issues so that the user 
 can fix them all, instead of fixing one, running build, fixing again, etc.

 What does the community think of this idea ? Can we implement a prototype and 
 see if this is useful to our developers ?
 Note that this does not change or break existing functionality - it just 
 exposes the already existing check_reqs in the CLI. Build will continue to 
 call check_reqs.

 Please vote on this proposal, or raise any concerns you may have.

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



Re: Proposal: Expose check_reqs at the CLI level

2015-04-13 Thread Jesse
Everyone's +1's count! It's the -1's that may be scrutinized

@purplecabbage
risingj.com

On Mon, Apr 13, 2015 at 12:11 PM, Dmitry Blotsky dblot...@microsoft.com
wrote:

 +1 for me too, even though my +1 points don't matter :)

 I've actually run into this issue when writing documentation for setting
 up slaves for medic. My short documentation is here:
 https://github.com/apache/cordova-medic/blob/master/SLAVES.md, but it is
 best for it to refer to the official Cordova docs instead.

 Should we make a JIRA task for better docs and automated platform
 dependency detection?

 Kindly,
 Dmitry

 -Original Message-
 From: Shazron [mailto:shaz...@gmail.com]
 Sent: Monday, April 13, 2015 11:56 AM
 To: dev@cordova.apache.org
 Subject: Re: Proposal: Expose check_reqs at the CLI level

 +1
 This will be great for users

 On Mon, Apr 13, 2015 at 11:53 AM, Parashuram N (MS OPEN TECH) 
 panar...@microsoft.com wrote:
  Hi,
 
  One of the main problems a lot of developers seem to have is the issue
 to setting up their machines for building various platforms. This came out
 from the Stack overflow survey, and the number of questions on stack
 overflow, twitter. Etc.
 
  I thought it would be helpful to have a check_reqs command exposed at
  the CLI level. This is similar to `brew doctor` or `appium doctor`.
  The idea is
 
 
  1.   Have a way for the user to see if they have all dependencies
 (like JAVA_HOME or ANDROID_HOME) set up? This happens at build time, but
 moving it out to a CLI level command where you can run cordova check_reqs
 (or something similar) would be useful to the users.
 
  2.   Today, the build command shows one error at a time. The
 check_reqs could run all the checks, and show a summary of the issues so
 that the user can fix them all, instead of fixing one, running build,
 fixing again, etc.
 
  What does the community think of this idea ? Can we implement a
 prototype and see if this is useful to our developers ?
  Note that this does not change or break existing functionality - it just
 exposes the already existing check_reqs in the CLI. Build will continue to
 call check_reqs.
 
  Please vote on this proposal, or raise any concerns you may have.

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




RE: Proposal: Expose check_reqs at the CLI level

2015-04-13 Thread Treggiari, Leo
+1   It sounds like a very good thing to do.

Leo

-Original Message-
From: Jesse [mailto:purplecabb...@gmail.com] 
Sent: Monday, April 13, 2015 12:24 PM
To: dev@cordova.apache.org
Subject: Re: Proposal: Expose check_reqs at the CLI level

Everyone's +1's count! It's the -1's that may be scrutinized

@purplecabbage
risingj.com

On Mon, Apr 13, 2015 at 12:11 PM, Dmitry Blotsky dblot...@microsoft.com
wrote:

 +1 for me too, even though my +1 points don't matter :)

 I've actually run into this issue when writing documentation for setting
 up slaves for medic. My short documentation is here:
 https://github.com/apache/cordova-medic/blob/master/SLAVES.md, but it is
 best for it to refer to the official Cordova docs instead.

 Should we make a JIRA task for better docs and automated platform
 dependency detection?

 Kindly,
 Dmitry

 -Original Message-
 From: Shazron [mailto:shaz...@gmail.com]
 Sent: Monday, April 13, 2015 11:56 AM
 To: dev@cordova.apache.org
 Subject: Re: Proposal: Expose check_reqs at the CLI level

 +1
 This will be great for users

 On Mon, Apr 13, 2015 at 11:53 AM, Parashuram N (MS OPEN TECH) 
 panar...@microsoft.com wrote:
  Hi,
 
  One of the main problems a lot of developers seem to have is the issue
 to setting up their machines for building various platforms. This came out
 from the Stack overflow survey, and the number of questions on stack
 overflow, twitter. Etc.
 
  I thought it would be helpful to have a check_reqs command exposed at
  the CLI level. This is similar to `brew doctor` or `appium doctor`.
  The idea is
 
 
  1.   Have a way for the user to see if they have all dependencies
 (like JAVA_HOME or ANDROID_HOME) set up? This happens at build time, but
 moving it out to a CLI level command where you can run cordova check_reqs
 (or something similar) would be useful to the users.
 
  2.   Today, the build command shows one error at a time. The
 check_reqs could run all the checks, and show a summary of the issues so
 that the user can fix them all, instead of fixing one, running build,
 fixing again, etc.
 
  What does the community think of this idea ? Can we implement a
 prototype and see if this is useful to our developers ?
  Note that this does not change or break existing functionality - it just
 exposes the already existing check_reqs in the CLI. Build will continue to
 call check_reqs.
 
  Please vote on this proposal, or raise any concerns you may have.

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




RE: Proposal: Expose check_reqs at the CLI level

2015-04-13 Thread Josh Soref
I'm +1 for `cordova doctor` and `cordova platform doctor {platformname}`.

The former should apply to all current platforms, the latter should support
doctoring for available but not added platforms -- if said platform were
specified.
And we should note in the documentation or `cordova doctor` that it may do
other checks -- e.g. linting the config.xml, warning about CSP, possibly
mentioning when a plugin is out of date -- just to indicate to people that
the behavior may evolve.

Not that this is more or less fixing a regression that we introduced when we
made `cordova platform add` not call check_reqs.

 -Original Message-
 From: Parashuram N (MS OPEN TECH) [mailto:panar...@microsoft.com]
 Sent: Monday, April 13, 2015 2:53 PM
 To: dev@cordova.apache.org
 Subject: Proposal: Expose check_reqs at the CLI level
 
 Hi,
 
 One of the main problems a lot of developers seem to have is the issue to
 setting up their machines for building various platforms. This came out
from
 the Stack overflow survey, and the number of questions on stack overflow,
 twitter. Etc.
 
 I thought it would be helpful to have a check_reqs command exposed at the
 CLI level. This is similar to `brew doctor` or `appium doctor`. The idea
is
 
 
 1.   Have a way for the user to see if they have all dependencies
(like
 JAVA_HOME or ANDROID_HOME) set up? This happens at build time, but
 moving it out to a CLI level command where you can run cordova check_reqs
 (or something similar) would be useful to the users.
 
 2.   Today, the build command shows one error at a time. The
check_reqs
 could run all the checks, and show a summary of the issues so that the
user
 can fix them all, instead of fixing one, running build, fixing again, etc.
 
 What does the community think of this idea ? Can we implement a prototype
 and see if this is useful to our developers ?
 Note that this does not change or break existing functionality - it just
exposes
 the already existing check_reqs in the CLI. Build will continue to call
 check_reqs.
 
 Please vote on this proposal, or raise any concerns you may have.


smime.p7s
Description: S/MIME cryptographic signature


Re: Proposal: Expose check_reqs at the CLI level

2015-04-13 Thread Carlos Santana
+1 if check_reqs are kept in the platform repos, currently check_reqs is a
platform concerned
if it's available from CLI it will be just a proxy to the platform
check_reqs.

if don't keep it in the platform repo, and add this logic to cli repo, we
will need to maintained a list of reqs for each platform, for each version
of each platform.

This is the reason why it was removed from cli and just is present in the
platform repo/code



On Mon, Apr 13, 2015 at 5:13 PM, Josh Soref jso...@blackberry.com wrote:

 I'm +1 for `cordova doctor` and `cordova platform doctor {platformname}`.

 The former should apply to all current platforms, the latter should support
 doctoring for available but not added platforms -- if said platform were
 specified.
 And we should note in the documentation or `cordova doctor` that it may do
 other checks -- e.g. linting the config.xml, warning about CSP, possibly
 mentioning when a plugin is out of date -- just to indicate to people that
 the behavior may evolve.

 Not that this is more or less fixing a regression that we introduced when
 we
 made `cordova platform add` not call check_reqs.

  -Original Message-
  From: Parashuram N (MS OPEN TECH) [mailto:panar...@microsoft.com]
  Sent: Monday, April 13, 2015 2:53 PM
  To: dev@cordova.apache.org
  Subject: Proposal: Expose check_reqs at the CLI level
 
  Hi,
 
  One of the main problems a lot of developers seem to have is the issue to
  setting up their machines for building various platforms. This came out
 from
  the Stack overflow survey, and the number of questions on stack overflow,
  twitter. Etc.
 
  I thought it would be helpful to have a check_reqs command exposed at the
  CLI level. This is similar to `brew doctor` or `appium doctor`. The idea
 is
 
 
  1.   Have a way for the user to see if they have all dependencies
 (like
  JAVA_HOME or ANDROID_HOME) set up? This happens at build time, but
  moving it out to a CLI level command where you can run cordova check_reqs
  (or something similar) would be useful to the users.
 
  2.   Today, the build command shows one error at a time. The
 check_reqs
  could run all the checks, and show a summary of the issues so that the
 user
  can fix them all, instead of fixing one, running build, fixing again,
 etc.
 
  What does the community think of this idea ? Can we implement a prototype
  and see if this is useful to our developers ?
  Note that this does not change or break existing functionality - it just
 exposes
  the already existing check_reqs in the CLI. Build will continue to call
  check_reqs.
 
  Please vote on this proposal, or raise any concerns you may have.




-- 
Carlos Santana
csantan...@gmail.com