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 4514318DD3 for ; Tue, 22 Mar 2016 06:28:55 +0000 (UTC) Received: (qmail 87398 invoked by uid 500); 22 Mar 2016 06:28:50 -0000 Delivered-To: apmail-cordova-dev-archive@cordova.apache.org Received: (qmail 87346 invoked by uid 500); 22 Mar 2016 06:28:50 -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 87322 invoked by uid 99); 22 Mar 2016 06:28:49 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd1-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 22 Mar 2016 06:28:49 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd1-us-west.apache.org (ASF Mail Server at spamd1-us-west.apache.org) with ESMTP id 451E2C111D for ; Tue, 22 Mar 2016 06:28:49 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd1-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: 1.429 X-Spam-Level: * X-Spam-Status: No, score=1.429 tagged_above=-999 required=6.31 tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, HTML_MESSAGE=2, KAM_LOTSOFHASH=0.25, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_MSPIKE_H3=-0.01, RCVD_IN_MSPIKE_WL=-0.01, SPF_PASS=-0.001] autolearn=disabled Authentication-Results: spamd1-us-west.apache.org (amavisd-new); dkim=pass (2048-bit key) header.d=gmail.com Received: from mx1-lw-eu.apache.org ([10.40.0.8]) by localhost (spamd1-us-west.apache.org [10.40.0.7]) (amavisd-new, port 10024) with ESMTP id 0Qddr5h7wtgd for ; Tue, 22 Mar 2016 06:28:47 +0000 (UTC) Received: from mail-ob0-f182.google.com (mail-ob0-f182.google.com [209.85.214.182]) by mx1-lw-eu.apache.org (ASF Mail Server at mx1-lw-eu.apache.org) with ESMTPS id 5BD6F5F47A for ; Tue, 22 Mar 2016 06:28:46 +0000 (UTC) Received: by mail-ob0-f182.google.com with SMTP id xj3so24104906obb.0 for ; Mon, 21 Mar 2016 23:28:46 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to; bh=OvTaWf7KTHxoRWEyAZ/1uFZa3uhXJL8RYXcR1WZgbdw=; b=B5kfgjMeUNriACsKPni/HgnmYTW9qKkVWII0S2aSESw8SzsbcyjO4Tp1OOQdmtYCEE MLIyXkt+uedXf9IJpfWm3YzCcww2KdQYaPBwefiZrYLuCut8jiTuctZWw4kCwfsVTVPL 8FNtqMQjrgVrfG4pHF40Ax/n16om//k9y8JcdIg3smBqhXCX/ujNEu4ejVbCJzrGwAUn f+c3r6G0AhauDeyJ9ekD17pFpOBVE5EDnfsqmsV6k0zj7VQb6viJspqD5AYjbjjk6TGE 9GK1F3jIWbW+BfprUpu/I7qbz85oX4m6oHufakfGOmynAdHLDrMJp+oNFgaaDqO9u1A8 IztQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:date :message-id:subject:from:to; bh=OvTaWf7KTHxoRWEyAZ/1uFZa3uhXJL8RYXcR1WZgbdw=; b=ETKrS7aI49vU/EjAhqBbAuEZtuSgon/e7lMY+2pzfgzJ8cfUTRRgzeOLA6CN8bZUo2 jpGNENtEZHc6zbvlCi72UMo1dr2wQyix8oANIIKIBWgqIkWLwJTBpWI4oZz61mF36DvD lhUxbFIcoVHRy7VQpZl12ZHBkNy0RowkEaaHF7JgVIMv8bGHFf5dAn09AeLD6CfcAY/7 WRoxpvQYvqQuJpowO1ICWi/1oyUqSRsOH/OEJZF2N+8ReLw11RZW/8q93dfm5Fkzo1/p PHcaeBz0Vi9XEykAM/NXSFDTuHNAqVkh4K5MrFVTrZeQl2VUjwhUwMmeIPbPKKlfw6t4 qT0g== X-Gm-Message-State: AD7BkJK1KU2+pEZ11aKnnnTEmMRUMx9GKjdBcF+4x2i++VEDyb2mjZjeR+tkP4flmr2oeVZfPztcZtFty+yoqw== MIME-Version: 1.0 X-Received: by 10.60.39.194 with SMTP id r2mr20578393oek.69.1458628118492; Mon, 21 Mar 2016 23:28:38 -0700 (PDT) Received: by 10.76.6.52 with HTTP; Mon, 21 Mar 2016 23:28:38 -0700 (PDT) In-Reply-To: References: Date: Mon, 21 Mar 2016 20:28:38 -1000 Message-ID: Subject: Re: [Android] Need a solution to config.xml and AndroidManifest.xml feature requests From: Jesse To: "dev@cordova.apache.org" Content-Type: multipart/alternative; boundary=089e015365f0dcbc91052e9d52c2 --089e015365f0dcbc91052e9d52c2 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable I like having the same xml fragments in config.xml as we use in plugin.xml We will need to address precedence, as a plugin.xml and config.xml can disagree. > On Mar 21, 2016, at 12:46 PM, Shazron wrote: > > Continuing on Simon's point, we already have duplication of entries > for preference tags in https://issues.apache.org/jira/browse/CB-9264 > and a post-processing step does the removal of dupes. Not sure if this > removal method would be adequate (as long as the desired tag to > express is written to the config file *last*) > > On Mon, Mar 21, 2016 at 3:41 PM, Simon MacDonald > wrote: >> I agree the config-file is the way to go but we need to go one step more >> and enable the changing of attributes in the config file instead of just >> adding lines to AndroidManifest.xml. For instance, the first bug CB-1089= 4 >> talks about adding a preference for screen sizes. >> >> The default AndroidManifest.xml that is created with Cordova Android wil= l >> add the line: >> >> > android:normalScreens=3D"true" android:resizeable=3D"true" >> android:smallScreens=3D"true" android:xlargeScreens=3D"true" /> >> >> and if you want to make smallScreens=3D"false" you have no way of doing = it as >> it adds a duplicate line if you are using the config-file way of doing >> things. We really need attribute level granularity in the config-file tag. >> >> >> >> Simon Mac Donald >> http://hi.im/simonmacdonald >> >> On Mon, Mar 21, 2016 at 4:52 PM, Richard Knoll >> wrote: >> >>> I agree that config-file is the way to go. After an offline discussion >>> with Nikhil, Parashu, and Jason, one question that came up was whether all >>> of this native config stuff belongs in config.xml or should be separate= d >>> out. One idea would be to define separate files for each configuration file >>> you wish to modify (something like AndroidManifest.merge.xml). Those files >>> would follow the same format as the config-file tag and you could add >>> entries to build.json or config.xml specifying what native config each file >>> modifies. It breaks from how we do it in plugin.xml, but it prevents having >>> gigantic config.xml files that are mostly composed of native fragments. The >>> current config file mixing that we do is somewhat messy. >>> Thoughts? >>> >>> Richard >>> >>> -----Original Message----- >>> From: Alexis Kofman [mailto:alexis.kofman@gmail.com] >>> Sent: Monday, March 21, 2016 1:39 PM >>> To: dev@cordova.apache.org >>> Subject: Re: [Android] Need a solution to config.xml and >>> AndroidManifest.xml feature requests >>> >>> Hello all, >>> >>> I agree with Julio that it is less confusing keeping the same mecanism >>> that the one it already exists with the plugin.xml. >>> Le 21 mars 2016 19:17, "julio cesar sanchez" a >>> =C3=A9crit : >>> >>>> I think we should add the config-file tag to the config.xml. >>>> It's already implemented on the plugin.xml. It allows you to modify >>>> the AndroidManifest.xml or the info.plist when you install a plugin. >>>> But the number of plugins that just modify the AndroidManifest.xml or >>>> info.plist is increasing, I think that should be on the config.xml too= . >>>> >>>> So we don't duplicate anything with our own tags, we just let them add >>>> whatever they want from the config-file tag. >>>> And if something can't be edited from the config-file tag, we tell >>>> them to create a hook. >>>> >>>> Phonegap build uses the config-file tag on the config.xml to allow >>>> their users to edit the AndroidManifest.xml and the info.plist >>>> >>>> @Parashuram idea might work on android, but I think we should have >>>> something that can be used on all the platforms >>>> >>>> >>>> >>>> 2016-03-21 18:40 GMT+01:00 Parashuram N : >>>> >>>>> Given that we are now using Gradle for builds, could these simply be >>>>> gradle sub-projects that define an AndroidManifest.xml, that gets >>>>> merged during Android build ? One way could be to support specifying >>>>> "sub-projects" in config.xml, and these changes get picked up. Would >>>>> it work for all cases ? >>>>> >>>>> -----Original Message----- >>>>> From: Joe Bowser [mailto:bowserj@gmail.com] >>>>> Sent: Monday, March 21, 2016 10:07 AM >>>>> To: dev >>>>> Subject: [Android] Need a solution to config.xml and >>>>> AndroidManifest.xml feature requests >>>>> >>>>> Hey >>>>> >>>>> So, if you've been paying attention to the JIRA, we've been getting >>>>> slammed with a ton of feature requests/bugs regarding the Android >>>> Manifest >>>>> where people want to add a 1:1 mapping between the two XML files. >>>>> >>>>> The thing is that it's getting out of control, and we need to find a >>>>> better solution to this problem. I'm not sure what a better >>>>> solution to this is, but if you want to see some of the issues that >>>>> are related to this, here's a small list: >>>> https://na01.safelinks.protection.outlook.com/?url=3Dhttps%3a%2f%2fiss= ue >>>> s.apache.org%2fjira%2fbrowse%2fCB-10894&data=3D01%7c01%7cpanarasi%40mi= cr >>>> osoft.com%7c4430fe17c9d94a96f19608d351ab4028%7c72f988bf86f141af91ab2d7 >>>> cd011db47%7c1&sdata=3Df3qD84Rx%2bc%2bDzryeeXDCIX%2bhrCk%2boM%2f26%2fT5= OA >>>> y9RMA%3d >>>> https://na01.safelinks.protection.outlook.com/?url=3Dhttps%3a%2f%2fiss= ue >>>> s.apache.org%2fjira%2fbrowse%2fCB-10917&data=3D01%7c01%7cpanarasi%40mi= cr >>>> osoft.com%7c4430fe17c9d94a96f19608d351ab4028%7c72f988bf86f141af91ab2d7 >>>> cd011db47%7c1&sdata=3DI1ycCL25rWlN4uTU%2fPXFBkv1PYXrDeX6dF6%2fMzyNSbE%= 3d >>>> https://na01.safelinks.protection.outlook.com/?url=3Dhttps%3a%2f%2fiss= ue >>>> s.apache.org%2fjira%2fbrowse%2fCB-8159&data=3D01%7c01%7cpanarasi%40mic= ro >>>> soft.com%7c4430fe17c9d94a96f19608d351ab4028%7c72f988bf86f141af91ab2d7c >>>> d011db47%7c1&sdata=3DHS3ZRL%2fxY%2fJWZo5eMQPGFO6BS2W03z13va8NV7sZpjo%3= d >>>> https://na01.safelinks.protection.outlook.com/?url=3Dhttps%3a%2f%2fiss= ue >>>> s.apache.org%2fjira%2fbrowse%2fCB-10755&data=3D01%7c01%7cpanarasi%40mi= cr >>>> osoft.com%7c4430fe17c9d94a96f19608d351ab4028%7c72f988bf86f141af91ab2d7 >>>> cd011db47%7c1&sdata=3DPeZms4TWbWqHInf%2fnYYbL3e5o9aB3Ijcl8fQxoUmsgU%3d >>>> https://na01.safelinks.protection.outlook.com/?url=3Dhttps%3a%2f%2fiss= ue >>>> s.apache.org%2fjira%2fbrowse%2fCB-8976&data=3D01%7c01%7cpanarasi%40mic= ro >>>> soft.com%7c4430fe17c9d94a96f19608d351ab4028%7c72f988bf86f141af91ab2d7c >>>> d011db47%7c1&sdata=3D4VoysIEst8o7k3kvkyYu9MeBDF8VZ3q7aG6oLcoCN2w%3d >>>>> >>>>> All of these are either indirectly or directly related to the >>>>> AndroidManifest, and it's clear that if we just allowed people to >>>>> edit an AndroidManifest, or at least allow portions of it to be >>>>> immutable, we >>>> would >>>>> be better off. Obviously, plugins that install third-party >>>>> activities >>>> and >>>>> content providers would have to edit the manifest, but I think that >>>> things >>>>> are getting out of hand with the things that people want to control >>>>> from config.xml. >>>>> >>>>> What do people think? Does anyone have a good solution to this problem? >>>>> Are we really abstracting anything out by duplicating the same >>>>> config in our own config.xml? >>> >>> --------------------------------------------------------------------- >>> To unsubscribe, e-mail: dev-unsubscribe@cordova.apache.org >>> For additional commands, e-mail: dev-help@cordova.apache.org > > --------------------------------------------------------------------- > To unsubscribe, e-mail: dev-unsubscribe@cordova.apache.org > For additional commands, e-mail: dev-help@cordova.apache.org > --089e015365f0dcbc91052e9d52c2--