+1 on this idea.

-Erik

From: Shazron
Sent: Thursday, May 2, 2013 5:28 PM
To: dev@cordova.apache.org
Reply To: dev@cordova.apache.org
Subject: Re: Standardising How to Get Cordova Version in a Project


Why don't we defer to each platform how to read the version - return it in
a script? kinda like bin/check_reqs


On Thu, May 2, 2013 at 2:18 PM, Tim Kim <timki...@gmail.com> wrote:

> Hey gang,
>
> So I'm working on the engine tag for plugman and I've come across a bit of
> a problem. For those who don't know, the engine tag is for checking whether
> a plugin needs a certain version of Cordova to work. It's one of the last
> outstanding features for the plugman spec that has yet to be implemented.
>
> Anyhow, the problem is figuring out what version of Cordova a particular
> project is using. Each platform is different in how they 'determine' which
> current version is being used. eg, VERSION files, a jar file that has the
> version string in it, cordova js file with version in the file name or
> first line, etc.
>
> Moving forward, I was hoping that we could include an additional config xml
> element to specify which version of Cordova is being used. So something
> like that could be added in during the create scripts. That way I can just
> reference the config xml file and get all the info I need.
>
> However, the problem with that approach is if a particular user decides to
> just upgrade their project but copying and pasting new files or changed
> version somehow, they will also have to remember to upgrade their version
> string in config xml. It's not so bad, but kinda annoying.
>
> If no change is made, I've done some work to solve this problem but it's
> pretty brittle. You supply a possible path(s) of where you think the
> version string might be and it'll try and figure it out for you. So it
> should work with the recent change of moving the version number to the top
> of the cordova.js file:
> https://github.com/timkim/plugman/tree/search_cordova
>
>
>
>
>
> --
> Timothy Kim
>

---------------------------------------------------------------------
This transmission (including any attachments) may contain confidential 
information, privileged material (including material protected by the 
solicitor-client or other applicable privileges), or constitute non-public 
information. Any use of this information by anyone other than the intended 
recipient is prohibited. If you have received this transmission in error, 
please immediately reply to the sender and delete this information from your 
system. Use, dissemination, distribution, or reproduction of this transmission 
by unintended recipients is not authorized and may be unlawful.

Reply via email to