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 94DBB18EA1 for ; Tue, 19 May 2015 16:02:20 +0000 (UTC) Received: (qmail 75760 invoked by uid 500); 19 May 2015 16:02:20 -0000 Delivered-To: apmail-cordova-dev-archive@cordova.apache.org Received: (qmail 75723 invoked by uid 500); 19 May 2015 16:02:20 -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 75709 invoked by uid 99); 19 May 2015 16:02:19 -0000 Received: from Unknown (HELO spamd2-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 19 May 2015 16:02:19 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd2-us-west.apache.org (ASF Mail Server at spamd2-us-west.apache.org) with ESMTP id 86E3C1A2FDF for ; Tue, 19 May 2015 16:02:19 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd2-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: 2.871 X-Spam-Level: ** X-Spam-Status: No, score=2.871 tagged_above=-999 required=6.31 tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, HEADER_FROM_DIFFERENT_DOMAINS=0.001, HTML_MESSAGE=3, RCVD_IN_MSPIKE_H3=-0.01, RCVD_IN_MSPIKE_WL=-0.01, SPF_PASS=-0.001, T_RP_MATCHES_RCVD=-0.01, URIBL_BLOCKED=0.001] autolearn=disabled Authentication-Results: spamd2-us-west.apache.org (amavisd-new); dkim=pass (2048-bit key) header.d=google.com header.b=JsZbnMSP; dkim=pass (1024-bit key) header.d=chromium.org header.b=OtY6rcJZ Received: from mx1-us-east.apache.org ([10.40.0.8]) by localhost (spamd2-us-west.apache.org [10.40.0.9]) (amavisd-new, port 10024) with ESMTP id xr3f_s66xqxa for ; Tue, 19 May 2015 16:02:13 +0000 (UTC) Received: from mail-vn0-f49.google.com (mail-vn0-f49.google.com [209.85.216.49]) by mx1-us-east.apache.org (ASF Mail Server at mx1-us-east.apache.org) with ESMTPS id C7FE743DA6 for ; Tue, 19 May 2015 16:02:12 +0000 (UTC) Received: by vnbg129 with SMTP id g129so1445866vnb.9 for ; Tue, 19 May 2015 09:02:12 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=mime-version:sender:in-reply-to:references:from:date:message-id :subject:to:content-type; bh=+CF768gVtvrxFaj/XdvivCkWKUuEmNKShCQ98dCSpDs=; b=JsZbnMSP/UyaJ6VDIhj8vXKt8y8tVmzAXWdAzjR6hGyeO+bf8f54TNMu1F2fuHXxpx kdGiBamODz+ZvxGFaNR4aIjLy/dQ0t7SvCTajRpsAaqYEhcMS7B5R9KzMOt1gxGfkSDD 5CzQpFG0Crw6V7cEgiv6RoFi2dCbf7bnZgIemZ4vEa6Qyy/vzK8S+SrBLZAQV+INx6Hf KMYAqtFVpNI5R6t1nc73gAZms3yY0ZxSh7oUFcAwDGlDsHOhod4N4Bcy1ksoNfc4F4cd dDd0X+gLx4y2DkNbWrWvilxsgEbtVcUOd1aFu4OGLR8R18HNssBnWZE9hBmPPtRsbFeQ x31g== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=mime-version:sender:in-reply-to:references:from:date:message-id :subject:to:content-type; bh=+CF768gVtvrxFaj/XdvivCkWKUuEmNKShCQ98dCSpDs=; b=OtY6rcJZqx7VIO/ofhPru9L7IoNbdZxqGlWAKzwgSugVetmeVmMGUvimZdicJN5Ifz lx0xbc4fWR+No9ti4URMDDNjZEIRyxKFQs7x+nSA+9s9NNE3PLxa0BYDoQhKH1e4hGJc izhQx5Hry3ENPTukmrhyYmD4r3FInZOyYyY7s= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:sender:in-reply-to:references:from :date:message-id:subject:to:content-type; bh=+CF768gVtvrxFaj/XdvivCkWKUuEmNKShCQ98dCSpDs=; b=eYPB+1G89doc6loBYPtNpKlfA+cGLlk8dfRFBQM9Sw0jZMbWx4Akpv1vWcoV5eynOZ T1910EEcWNd57xSqmWQFuR/pTWzFZI4UfDBQmo86PMmAAoqmLshwqRx850/i56IuXl5K iKSXYEZvFFCeSeaYVLZzucQ+WhvdbyWbHeeO3usyFOrCvuKZ5ZnuL0y/1XG8y/GJhoUF KInoZc+sLNFr4MznOhjIOT8w4fgnf2DYFVzCaND3o9R1AmblVGaJAb/rLgYwP9NOW3YS IuZmX6/wf4ttaJFlLSdP0UNkIru4eW5pt+1R59HafB6Wfu3XxYQjCOegnJLROO7GSG5C L4fw== X-Gm-Message-State: ALoCoQm9NMdUMn9BvKDe/LIwq+wzh6BHyE2HqIWP5ObytQjDRuIAgFKm3dDV4ZXB2wHxMHPwDmWA X-Received: by 10.52.113.97 with SMTP id ix1mr28616910vdb.1.1432051332392; Tue, 19 May 2015 09:02:12 -0700 (PDT) MIME-Version: 1.0 Sender: mmocny@google.com Received: by 10.52.181.170 with HTTP; Tue, 19 May 2015 09:01:51 -0700 (PDT) In-Reply-To: References: <67B15EFC-EC31-400A-9360-B0D7C69362CA@microsoft.com> From: Michal Mocny Date: Tue, 19 May 2015 12:01:51 -0400 X-Google-Sender-Auth: DfFTznek2qQa8_d3lssJmu4dYNM Message-ID: Subject: Re: Behavior of --copy-from To: dev Content-Type: multipart/alternative; boundary=bcaec548a627f7d3d00516716e67 --bcaec548a627f7d3d00516716e67 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable The *intention* of copy-from / link-to is to import either (a) a web project, or (b) another cordova project. We used to check for (b) I think by the existence of a config.xml and www/ (note: double check config.xml is required). If that check passes, we copy those two nested contents only (I think) directly into the root of your new project. If the check failed, we would copy the entire folder into the www/ of the new project. There's some bug since you should get a valid cordova project no matter what the contents of the import (with caveats of importing invalid config.xml or bad apps). -Michal On Tue, May 19, 2015 at 7:12 AM, Raymond Camden wrote: > I definitely can't recreate the "end up with a folder that isn't a > project" but --copy-from does seem to ignore files it doesn't > recognize. I filed a bug for it. > > On Tue, May 19, 2015 at 6:07 AM, Raymond Camden > wrote: > > No, what seems to happen to me is: > > > > If I copy-from a directory that has a www folder in it, then it is > > treated as the *root* of the new project and a proper Cordova folder > > is not created. > > > > If I copy-from a dir that does NOT have a www folder in it, it is > > treated as the www folder of a new project. > > > > Nope, I lie. Ok, so this is weirder than I imagined. > > > > I made a new folder called "testwithwww". It has a file called > > something.txt and a folder called www with an index.html. > > > > I sourced a new project with it. My www folder copied fine, but > > something.txt was completely ignored. It did, however, make a proper > > Cordova project. > > > > So this is a bit different from what I saw earlier where my first test > > created something that wasn't a project, but it definitely failed to > > copy a file over. > > > > > > > > > > On Tue, May 19, 2015 at 2:18 AM, Dmitry Blotsky > wrote: > >> Hi Raymond, > >> > >> The semantics of =E2=80=9C--copy-from=E2=80=9D are: copy the passed pa= th in place of > the new project's =E2=80=9Cwww=E2=80=9D directory, which =E2=80=9Ccordova= create=E2=80=9D seems to obey. Is > that not what happened in your case? However, the failure to copy over > paths that start with =E2=80=9C.=E2=80=9D looks like a bug to me. Unless = someone says > otherwise, feel totally free file a bug in JIRA. > >> > >> Kindly, > >> Dmitry > >> > >> On May 17, 2015, at 7:56 AM, Raymond Camden > wrote: > >> > >> Well shoot - as a follow up - if I make a new Cordova project, lets > >> call it testsource2, and then copy .settings to it, and then follow up > >> by making a new project that uses copy-from pointing to testsource2, > >> the CLI isn't copying the .settings directory. That is a bug for sure, > >> right? > >> > >> On Sun, May 17, 2015 at 9:51 AM, Raymond Camden < > raymondcamden@gmail.com> wrote: > >> I thought I remember seeing a thread on this, but GMail is being a bit > >> cranky about how I search today. > >> > >> I had thought that if you used --copy-from and the directory you used > >> included www itself, then the folders would be copied over to a new > >> project and merged in with normal default items. > >> > >> I just tested with a folder that had 2 items: A .settings directory > >> and a www directory. While the CLI reported no issues, it did not > >> create a proper Cordova project. It literally just copied .settings > >> and www, but didn't do anything else to create a proper Cordova > >> project. > >> > >> So I'm guessing that the expectation is that if you do not use a > >> folder meant to be www, then your source directory should contain > >> everything required for a proper Cordova project. But that's not > >> forward-proof though. Imagine if Cordova 6 changes the project > >> structure a bit so that a Foo folder is required, then I wouldn't be > >> able to use my source dir w/o changing it. (Which, ok, probably won't > >> happen.) > >> > >> So is this expected? Is this ok with others? Should I file a ER > >> perhaps to make --copy-from in this situation add the rest of the > >> project assets? > >> > >> -- > >> > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D > >> Raymond Camden, Developer Advocate for MobileFirst at IBM > >> > >> Email : raymondcamden@gmail.com > >> Blog : www.raymondcamden.com > >> Twitter: raymondcamden > >> > >> > >> > >> -- > >> > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D > >> Raymond Camden, Developer Advocate for MobileFirst at IBM > >> > >> Email : raymondcamden@gmail.com > >> Blog : www.raymondcamden.com > >> Twitter: raymondcamden > >> > >> --------------------------------------------------------------------- > >> To unsubscribe, e-mail: dev-unsubscribe@cordova.apache.org dev-unsubscribe@cordova.apache.org> > >> For additional commands, e-mail: dev-help@cordova.apache.org dev-help@cordova.apache.org> > >> > > > > > > > > -- > > > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D > > Raymond Camden, Developer Advocate for MobileFirst at IBM > > > > Email : raymondcamden@gmail.com > > Blog : www.raymondcamden.com > > Twitter: raymondcamden > > > > -- > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D > Raymond Camden, Developer Advocate for MobileFirst at IBM > > Email : raymondcamden@gmail.com > Blog : www.raymondcamden.com > Twitter: raymondcamden > > --------------------------------------------------------------------- > To unsubscribe, e-mail: dev-unsubscribe@cordova.apache.org > For additional commands, e-mail: dev-help@cordova.apache.org > > --bcaec548a627f7d3d00516716e67--