cordova-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Michael Brooks <>
Subject Re: [cordova-cli] versioning
Date Mon, 25 Mar 2013 18:06:05 GMT
+1 to locking the CLI to a version
+1 to the Grunt vision

However, I'd like to propose a different approach to the CLI versioning and
it can also solve the `create` command issue to help move towards a dumb
global `cordova`.

## Cordova-CLI

- npm version is still associated with a Cordova distribution
- Cordova-CLI does not vendor the Cordova distribution
- Adding a platform will lazy load the platform distribution into
    - We can lazy load by downloading a gzip from the Apache Git web server
- Next time the platform is needed, it is copied from

## Cordova Create

- Creating an app should be a lazy load of the Hello World app
   - Cached in ~/.cordova/app/<name>-<version>/
- We can update the Hello World app to match a standard Cordova CLI project
- Now the global Cordova CLI is a dumb tool
   - On create: lazy loading or copying the hello world app
   - On project command: shelling to ./node_modules/bin/cordova <command>

On Fri, Mar 22, 2013 at 1:08 PM, Filip Maj <> wrote:

> As Tommay pointed out, you need to create the cordova project structure in
> the first place with some manner of tool..
> On 3/22/13 11:58 AM, "tommy-carlos Williams" <> wrote:
> >I don't have much to add except that I really like this about Grunt.
> >
> >However, it would get "interesting" with Cordova since the global is what
> >creates a project in the first place. I still think it could work and
> >have the global only responsible for creating dirs and setting up
> >package.json stuff etc...
> >
> >+1 for looking into this.
> >
> >On 23/03/2013, at 4:53, Brian LeRoux <> wrote:
> >
> >> Right now the global executable is version locked to a Cordova
> >> release. If you have a project running 2.5 you are required to have
> >> Cordova/CLI 2.5. If you need to then work in Cordova 2.4 you need to
> >> downgrade (not really but you would to be safe).
> >>
> >> In Grunt .4 the global executable is dumb. It just shells to locally
> >> installed ./node_module version of Grunt. This enables project level
> >> versioning of Grunt. Nice feature. We can do the same thing: with the
> >> caveat that you would then require a package.json and ./node_modules
> >> folder in our Cordova projects.
> >>
> >> Discuss.

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message