Return-Path: X-Original-To: apmail-cordova-issues-archive@minotaur.apache.org Delivered-To: apmail-cordova-issues-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 20B1B17B1B for ; Tue, 30 Jun 2015 09:51:05 +0000 (UTC) Received: (qmail 36555 invoked by uid 500); 30 Jun 2015 09:51:05 -0000 Delivered-To: apmail-cordova-issues-archive@cordova.apache.org Received: (qmail 36531 invoked by uid 500); 30 Jun 2015 09:51:05 -0000 Mailing-List: contact issues-help@cordova.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Delivered-To: mailing list issues@cordova.apache.org Received: (qmail 36516 invoked by uid 99); 30 Jun 2015 09:51:04 -0000 Received: from arcas.apache.org (HELO arcas.apache.org) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 30 Jun 2015 09:51:04 +0000 Date: Tue, 30 Jun 2015 09:51:04 +0000 (UTC) From: "Leroy van Engelen (JIRA)" To: issues@cordova.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Comment Edited] (CB-9248) In config.xml, inside is not supported MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/CB-9248?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14608046#comment-14608046 ] Leroy van Engelen edited comment on CB-9248 at 6/30/15 9:50 AM: ---------------------------------------------------------------- Thanks for clarifying the way Cordova plugins are meant to work. It might be a good idea to mention in the `config.xml` documentation that `` does not apply to plugins. Currently it says: > When using the CLI to build applications, it is sometimes necessary to specify > preferences or other elements specific to a particular platform. Use the > element to specify configuration that should only appear in a > single platform-specific config.xml file. For us, most reasons to have different plugin dependencies per platform is because we use Phonegap Build (PGB). PGB currently provides the following platform versions with `phonegap-version` set to `cli-5.1.1` (taken from the defaults installed by cordova cli 5.1.1): - Android: 4.0.2 - iOS: 3.8.0 - wp8: 3.8.1 Now, these issues come up: - The `cordova-plugin-whitelist` plugin does not support iOS platform <= 4 (and I suspect it does not support any platform version <= 4). Therefore we only add it on Android - The latest `cordova-plugin-file-transfer` on wp8 (1.2.0) uses an API that is only available in `master` on `apache/cordova-wp8`, so we need to depend on an older version - The `com.phonegap.plugin.statusbar` plugin only works on iOS, so we need to exclude it for other platforms. There are other statusbar plugins (e.g. cordova-plugin-statusbar) but we would need to do a retest with that. So the main issues are that the choice of default platform versions on PGB is a bit unfortunate for us and that new versions of plugins can depend on unreleased versions of a platform :( was (Author: lvanengelen): Thanks for clarifying the way Cordova plugins are meant to work. It might be a good idea to mention in the `config.xml` documentation that `` does not apply to plugins. Currently it says: > When using the CLI to build applications, it is sometimes necessary to specify > preferences or other elements specific to a particular platform. Use the > element to specify configuration that should only appear in a > single platform-specific config.xml file. For us, most reasons to have different plugin dependencies per platform is because we use Phonegap Build (PGB). PGB currently provides the following platform versions with `phonegap-version` set to `cli-5.1.1` (taken from the defaults installed by cordova cli 5.1.1): Android: 4.0.2 iOS: 3.8.0 wp8: 3.8.1 Now, these issues come up: The `cordova-plugin-whitelist` plugin does not support iOS platform <= 4 (and I suspect it does not support any platform version <= 4). Therefore we only add it on Android The latest `cordova-plugin-file-transfer` on wp8 (1.2.0) uses an API that is only available in `master` on `apache/cordova-wp8`, so we need to depend on an older version The `com.phonegap.plugin.statusbar` plugin only works on iOS, so we need to exclude it for other platforms. There are other statusbar plugins (e.g. cordova-plugin-statusbar) but we would need to do a retest with that. So the main issues are that the choice of default platform versions on PGB is a bit unfortunate for us and that new versions of plugins can depend on unreleased versions of a platform > In config.xml, inside is not supported > ----------------------------------------------------------- > > Key: CB-9248 > URL: https://issues.apache.org/jira/browse/CB-9248 > Project: Apache Cordova > Issue Type: Bug > Components: CLI, CordovaLib > Affects Versions: 5.1.2 > Reporter: Leroy van Engelen > Assignee: Rob Paveza > > In config.xml it is possible to define plugins that should be installed using the tag. Some plugins are not available or are buggy on certain platforms. Therefore we need to include them depending on the platform. I would expect this to be possible by wrapping them in tags, but these are ignored. > The problem is that in `cordova-lib/src/configparser/ConfigParser.js` the methods `getPluginIdList` and `getPlugin` only top level definitions are taken into account. -- This message was sent by Atlassian JIRA (v6.3.4#6332) --------------------------------------------------------------------- To unsubscribe, e-mail: issues-unsubscribe@cordova.apache.org For additional commands, e-mail: issues-help@cordova.apache.org