Return-Path: X-Original-To: apmail-cordova-dev-archive@www.apache.org Delivered-To: apmail-cordova-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id B8454F523 for ; Fri, 19 Apr 2013 21:20:29 +0000 (UTC) Received: (qmail 83441 invoked by uid 500); 19 Apr 2013 21:20:29 -0000 Delivered-To: apmail-cordova-dev-archive@cordova.apache.org Received: (qmail 83408 invoked by uid 500); 19 Apr 2013 21:20:29 -0000 Mailing-List: contact dev-help@cordova.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@cordova.apache.org Delivered-To: mailing list dev@cordova.apache.org Received: (qmail 83398 invoked by uid 99); 19 Apr 2013 21:20:29 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 19 Apr 2013 21:20:29 +0000 X-ASF-Spam-Status: No, hits=-0.7 required=5.0 tests=RCVD_IN_DNSWL_LOW,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of fil@adobe.com designates 64.18.1.238 as permitted sender) Received: from [64.18.1.238] (HELO exprod6og122.obsmtp.com) (64.18.1.238) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 19 Apr 2013 21:20:24 +0000 Received: from outbound-smtp-1.corp.adobe.com ([192.150.11.134]) by exprod6ob122.postini.com ([64.18.5.12]) with SMTP ID DSNKUXG1AwCEqEj4s8itjjAWsrOTidDhqdV4@postini.com; Fri, 19 Apr 2013 14:20:04 PDT Received: from inner-relay-4.eur.adobe.com (inner-relay-4.adobe.com [193.104.215.14]) by outbound-smtp-1.corp.adobe.com (8.12.10/8.12.10) with ESMTP id r3JLGq1v006474 for ; Fri, 19 Apr 2013 14:16:52 -0700 (PDT) Received: from nahub01.corp.adobe.com (nahub01.corp.adobe.com [10.8.189.97]) by inner-relay-4.eur.adobe.com (8.12.10/8.12.9) with ESMTP id r3JLK1GU018418 for ; Fri, 19 Apr 2013 14:20:01 -0700 (PDT) Received: from nambxv01a.corp.adobe.com ([10.8.189.95]) by nahub01.corp.adobe.com ([10.8.189.97]) with mapi; Fri, 19 Apr 2013 14:20:00 -0700 From: Filip Maj To: "dev@cordova.apache.org" Date: Fri, 19 Apr 2013 14:19:57 -0700 Subject: Re: [cordova-cli] npm Version Update Thread-Topic: [cordova-cli] npm Version Update Thread-Index: Ac49Q6YPdzXocki4RKW6jgyALuVa9A== Message-ID: In-Reply-To: Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: user-agent: Microsoft-MacOutlook/14.3.2.130206 acceptlanguage: en-US Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Virus-Checked: Checked by ClamAV on apache.org Rockin, love it On 4/19/13 2:17 PM, "Michael Brooks" wrote: >Hey all, > >I'm planning to change the way we version the Cordova CLI. > >TL;DR >--- > > 2.7.0+1.0.5 =3D=3D=3D Cordova 2.7.0 and npm module version 1.0.5 > 2.7.1+1.0.12 =3D=3D=3D Cordova 2.7.1 and npm module version 1.0.12 > >Current State >--- > >Today, the Cordova CLI uses a major.minor.patch version identifiers to >publish to npm. The major and minor identifiers track the Cordova >framework >version, while the patch identifier is reserved for tracking Cordova CLI's >updates. > >For example, the current release is 2.6.2. This means it supports Cordova >2.6.x and has released two npm version updates since Cordova 2.6.0. > >The Problem >--- > >The problem is that this approach to versioning does not accurately >represent the Cordova framework or the npm module. > >When the Cordova framework releases a minor patch, such as Cordova 2.6.1, >then the npm module cannot represent that update. > >When the Cordova CLI changes the public module's API, it cannot represent >it. This would typically be reserved for a major or minor identifier. > >The Solution >--- > >In semantic versioning, the version precedance is as follows [1]: > >1.0.0-alpha < 1.0.0-alpha.1 < 1.0.0-beta.2 < 1.0.0-beta.11 < 1.0.0-rc.1 < >1.0.0-rc.1+build.1 < 1.0.0 < 1.0.0+0.3.7 < 1.3.7+build < >1.3.7+build.2.b8f12d7 < 1.3.7+build.11.e0f985a > >We can adopt the following scheme to accurately track both the Cordova >framework version and the npm version: > >major.minor.patch+major.minor.patch > >The first three m.m.p are to track the Cordova framework. >The second three m.m.p track the npm module. > >I would prefer to flip these, but to keep tagging consistent and backwards >compatible, we must keep the Cordova framework as the first three >identifies. > >Examples: > > 2.7.0-rc.1+1.0.0 > 2.7.0+1.0.5 > 2.7.1+1.0.12 > >The Benefits >--- > >Now Cordova users know exactly what Cordova version is used by the CLI: > > 2.7.0+1.0.5 =3D=3D=3D Cordova 2.7.0 > 2.7.1+1.0.12 =3D=3D=3D Cordova 2.7.1 > >Now npm module users can rely on semantic versioning (normal node >practice): > > 2.7.0+1.0.5 =3D=3D=3D Cordova CLI is 1.0.5 > 2.7.1+1.0.12 =3D=3D=3D Cordova CLI is 1.0.12 > 2.7.1+1.1.0 =3D=3D=3D Cordova CLI is 1.1.0 - sweet, a nice API was added= ! > 2.7.1+2.0.0 =3D=3D=3D Cordova CLI is 2.0.0 - oh no! my old APIs are remo= ved! > >[1] http://semver.org/ @see 12)