[GitHub] cordova-plugin-battery-status issue #57: CB-13028 (CI) Added browser platfor...
Github user alsorokin commented on the issue: https://github.com/apache/cordova-plugin-battery-status/pull/57 Well, without it we can't run iOS builds. And it seems we can't ask Travis to start Sauce Connect only for browser builds. --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. --- - To unsubscribe, e-mail: dev-unsubscr...@cordova.apache.org For additional commands, e-mail: dev-h...@cordova.apache.org
[GitHub] cordova-test-platform pull request #1: Doc requirements for platform api exp...
Github user audreyso commented on a diff in the pull request: https://github.com/apache/cordova-test-platform/pull/1#discussion_r128880654 --- Diff: PlatformRequirements.md --- @@ -0,0 +1,144 @@ + +# New Platform Checklist + +## Stand-alone scripts + +bin/create scripts +- bin/create _(typically a node script)_ +- bin/create.bat for windows +- windows .bat file typically just calls bin/create with node + +bin/update +- not entirely sure this code is run, or needs to exist with newish non-destructive platform updates + +## Package Expectations + +- Platforms must have a package.json in their root. +- Package.json exports a 'main', usually `"main": "src/cordova/Api.js"` +- This allows other modules to simply require() the path to this platform and get access to the Api. + +## Api (Platform) Expectations +- The PlatformApi class +- The PlatformApi class is an abstraction around a particular platform that exposes all the actions, properties, and methods for this platform so they are accessible programmatically. +- It can install & uninstall plugins with all source files, web assets and js files. +- It exposes a single 'prepare' method to provide a way for cordova-lib to apply a project's setting/www content to the platform. +- The PlatformApi class should be implemented by each platform that wants to use the new API flow. For those platforms, which don't provide their own PlatformApi, there will be a polyfill in cordova-lib. +- Platforms that implement their own PlatformApi instance should implement all prototype methods of this class to be fully compatible with cordova-lib. +- The PlatformApi instance should define the following field: +- platform : This is a String that defines a platform name. + +- Api.js exports static functions +- there is currently a requirement that the file be called Api.js (todo:change that) + + +- Api.js exports static function `updatePlatform(destination, options, events);` +- PlatformApi.updatePlatform = function (cordovaProject, options) {}; +- The `updatePlatform` method is equal to the bin/update script. It should update an already installed platform. It should accept a CordovaProject instance, that defines a project structure and configuration, that should be applied to the new platform, and an options object. +- cordovaProject: This is a CordovaProject instance that defines a project structure and configuration, that should be applied to the new platform. This argument is optional and if not defined, that platform is used as a standalone project and not as part of a Cordova project. +- options : This is an options object. The most common options are : +- options.customTemplate : This is a path to custom template, that should override the default one from platform. +- options.link : This is a flag that should indicate that the platform's sources will be linked to the installed platform instead of copying. + - The `updatePlatform` method must return a promise, which is either fulfilled with a PlatformApi instance or rejected with a CordovaError. + +- Api.js exports static function `createPlatform(destination, cfg, options, events);` +- PlatformApi.createPlatform = function(cordovaProject, options) {}; +- The `createPlatform method` is equal to the bin/create script. It should install the platform to a specified directory and create a platform project. It should accept a CordovaProject instance, that defines a project structure and configuration, that should be applied to the new platform, and an options object. +- cordovaProject : This is a CordovaProject instance that defines a project structure and configuration, that should be applied to the new platform. This argument is optional and if not defined, that platform is used as a standalone project and not as part of a Cordova project. +- options : This is an options object. The most common options are : +- options.customTemplate : This is a path to custom template, that should override the default one from the platform. --- End diff -- Thank you for explaining that! So would be enough to just write : - Templates allow developers to create apps based on boilerplate application code. - https://cordova.apache.org/docs/en/latest/guide/cli/template.html (and just exclude the rest of the information since it's already in the docs?) --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with
[GitHub] cordova-test-platform pull request #1: Doc requirements for platform api exp...
Github user audreyso commented on a diff in the pull request: https://github.com/apache/cordova-test-platform/pull/1#discussion_r128880058 --- Diff: PlatformRequirements.md --- @@ -0,0 +1,144 @@ + +# New Platform Checklist + +## Stand-alone scripts + +bin/create scripts +- bin/create _(typically a node script)_ +- bin/create.bat for windows +- windows .bat file typically just calls bin/create with node + +bin/update +- not entirely sure this code is run, or needs to exist with newish non-destructive platform updates + +## Package Expectations + +- Platforms must have a package.json in their root. +- Package.json exports a 'main', usually `"main": "src/cordova/Api.js"` +- This allows other modules to simply require() the path to this platform and get access to the Api. + +## Api (Platform) Expectations +- The PlatformApi class +- The PlatformApi class is an abstraction around a particular platform that exposes all the actions, properties, and methods for this platform so they are accessible programmatically. +- It can install & uninstall plugins with all source files, web assets and js files. +- It exposes a single 'prepare' method to provide a way for cordova-lib to apply a project's setting/www content to the platform. +- The PlatformApi class should be implemented by each platform that wants to use the new API flow. For those platforms, which don't provide their own PlatformApi, there will be a polyfill in cordova-lib. +- Platforms that implement their own PlatformApi instance should implement all prototype methods of this class to be fully compatible with cordova-lib. +- The PlatformApi instance should define the following field: +- platform : This is a String that defines a platform name. + +- Api.js exports static functions +- there is currently a requirement that the file be called Api.js (todo:change that) + + +- Api.js exports static function `updatePlatform(destination, options, events);` +- PlatformApi.updatePlatform = function (cordovaProject, options) {}; +- The `updatePlatform` method is equal to the bin/update script. It should update an already installed platform. It should accept a CordovaProject instance, that defines a project structure and configuration, that should be applied to the new platform, and an options object. +- cordovaProject: This is a CordovaProject instance that defines a project structure and configuration, that should be applied to the new platform. This argument is optional and if not defined, that platform is used as a standalone project and not as part of a Cordova project. +- options : This is an options object. The most common options are : +- options.customTemplate : This is a path to custom template, that should override the default one from platform. +- options.link : This is a flag that should indicate that the platform's sources will be linked to the installed platform instead of copying. + - The `updatePlatform` method must return a promise, which is either fulfilled with a PlatformApi instance or rejected with a CordovaError. + +- Api.js exports static function `createPlatform(destination, cfg, options, events);` +- PlatformApi.createPlatform = function(cordovaProject, options) {}; +- The `createPlatform method` is equal to the bin/create script. It should install the platform to a specified directory and create a platform project. It should accept a CordovaProject instance, that defines a project structure and configuration, that should be applied to the new platform, and an options object. +- cordovaProject : This is a CordovaProject instance that defines a project structure and configuration, that should be applied to the new platform. This argument is optional and if not defined, that platform is used as a standalone project and not as part of a Cordova project. +- options : This is an options object. The most common options are : +- options.customTemplate : This is a path to custom template, that should override the default one from the platform. +- options.link : This is a flag that should indicate that the platform's sources will be linked to the installed platform instead of copying. +- The `createPlatform` method must return a promise, which is either fulfilled with a PlatformApi instance or rejected with a CordovaError. + +The way most platforms work is somewhat tricky. The Api.js could be anywhere in the platform repo, ex. /templates/cordova/Api.js . When a new project is created for the platform, the platform copies this file (and supporting files ) to destination/cordova/Api.js. The project expectations demand that the Api.js file be available at
[GitHub] cordova-test-platform pull request #1: Doc requirements for platform api exp...
Github user purplecabbage commented on a diff in the pull request: https://github.com/apache/cordova-test-platform/pull/1#discussion_r128879785 --- Diff: PlatformRequirements.md --- @@ -0,0 +1,144 @@ + +# New Platform Checklist + +## Stand-alone scripts + +bin/create scripts +- bin/create _(typically a node script)_ +- bin/create.bat for windows +- windows .bat file typically just calls bin/create with node + +bin/update +- not entirely sure this code is run, or needs to exist with newish non-destructive platform updates + +## Package Expectations + +- Platforms must have a package.json in their root. +- Package.json exports a 'main', usually `"main": "src/cordova/Api.js"` +- This allows other modules to simply require() the path to this platform and get access to the Api. + +## Api (Platform) Expectations +- The PlatformApi class +- The PlatformApi class is an abstraction around a particular platform that exposes all the actions, properties, and methods for this platform so they are accessible programmatically. +- It can install & uninstall plugins with all source files, web assets and js files. +- It exposes a single 'prepare' method to provide a way for cordova-lib to apply a project's setting/www content to the platform. +- The PlatformApi class should be implemented by each platform that wants to use the new API flow. For those platforms, which don't provide their own PlatformApi, there will be a polyfill in cordova-lib. +- Platforms that implement their own PlatformApi instance should implement all prototype methods of this class to be fully compatible with cordova-lib. +- The PlatformApi instance should define the following field: +- platform : This is a String that defines a platform name. + +- Api.js exports static functions +- there is currently a requirement that the file be called Api.js (todo:change that) + + +- Api.js exports static function `updatePlatform(destination, options, events);` +- PlatformApi.updatePlatform = function (cordovaProject, options) {}; +- The `updatePlatform` method is equal to the bin/update script. It should update an already installed platform. It should accept a CordovaProject instance, that defines a project structure and configuration, that should be applied to the new platform, and an options object. +- cordovaProject: This is a CordovaProject instance that defines a project structure and configuration, that should be applied to the new platform. This argument is optional and if not defined, that platform is used as a standalone project and not as part of a Cordova project. +- options : This is an options object. The most common options are : +- options.customTemplate : This is a path to custom template, that should override the default one from platform. +- options.link : This is a flag that should indicate that the platform's sources will be linked to the installed platform instead of copying. + - The `updatePlatform` method must return a promise, which is either fulfilled with a PlatformApi instance or rejected with a CordovaError. + +- Api.js exports static function `createPlatform(destination, cfg, options, events);` +- PlatformApi.createPlatform = function(cordovaProject, options) {}; +- The `createPlatform method` is equal to the bin/create script. It should install the platform to a specified directory and create a platform project. It should accept a CordovaProject instance, that defines a project structure and configuration, that should be applied to the new platform, and an options object. +- cordovaProject : This is a CordovaProject instance that defines a project structure and configuration, that should be applied to the new platform. This argument is optional and if not defined, that platform is used as a standalone project and not as part of a Cordova project. +- options : This is an options object. The most common options are : +- options.customTemplate : This is a path to custom template, that should override the default one from the platform. --- End diff -- Voice should be 2nd person. Something like ... Templates allow app developers to create apps based on boilerplate application code ... Not sure how deep you need to go as the audience for this guide is/are platform developers, so it should be more 'How to I respect the template parameter when it is given?' and not 'How do I use templates?' --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org
[GitHub] cordova-test-platform pull request #1: Doc requirements for platform api exp...
Github user audreyso commented on a diff in the pull request: https://github.com/apache/cordova-test-platform/pull/1#discussion_r128879376 --- Diff: PlatformRequirements.md --- @@ -0,0 +1,144 @@ + +# New Platform Checklist + +## Stand-alone scripts + +bin/create scripts +- bin/create _(typically a node script)_ +- bin/create.bat for windows +- windows .bat file typically just calls bin/create with node + +bin/update +- not entirely sure this code is run, or needs to exist with newish non-destructive platform updates + +## Package Expectations + +- Platforms must have a package.json in their root. +- Package.json exports a 'main', usually `"main": "src/cordova/Api.js"` +- This allows other modules to simply require() the path to this platform and get access to the Api. + +## Api (Platform) Expectations +- The PlatformApi class +- The PlatformApi class is an abstraction around a particular platform that exposes all the actions, properties, and methods for this platform so they are accessible programmatically. +- It can install & uninstall plugins with all source files, web assets and js files. +- It exposes a single 'prepare' method to provide a way for cordova-lib to apply a project's setting/www content to the platform. +- The PlatformApi class should be implemented by each platform that wants to use the new API flow. For those platforms, which don't provide their own PlatformApi, there will be a polyfill in cordova-lib. +- Platforms that implement their own PlatformApi instance should implement all prototype methods of this class to be fully compatible with cordova-lib. +- The PlatformApi instance should define the following field: +- platform : This is a String that defines a platform name. + +- Api.js exports static functions +- there is currently a requirement that the file be called Api.js (todo:change that) + + +- Api.js exports static function `updatePlatform(destination, options, events);` +- PlatformApi.updatePlatform = function (cordovaProject, options) {}; +- The `updatePlatform` method is equal to the bin/update script. It should update an already installed platform. It should accept a CordovaProject instance, that defines a project structure and configuration, that should be applied to the new platform, and an options object. +- cordovaProject: This is a CordovaProject instance that defines a project structure and configuration, that should be applied to the new platform. This argument is optional and if not defined, that platform is used as a standalone project and not as part of a Cordova project. +- options : This is an options object. The most common options are : +- options.customTemplate : This is a path to custom template, that should override the default one from platform. +- options.link : This is a flag that should indicate that the platform's sources will be linked to the installed platform instead of copying. + - The `updatePlatform` method must return a promise, which is either fulfilled with a PlatformApi instance or rejected with a CordovaError. + +- Api.js exports static function `createPlatform(destination, cfg, options, events);` +- PlatformApi.createPlatform = function(cordovaProject, options) {}; +- The `createPlatform method` is equal to the bin/create script. It should install the platform to a specified directory and create a platform project. It should accept a CordovaProject instance, that defines a project structure and configuration, that should be applied to the new platform, and an options object. +- cordovaProject : This is a CordovaProject instance that defines a project structure and configuration, that should be applied to the new platform. This argument is optional and if not defined, that platform is used as a standalone project and not as part of a Cordova project. +- options : This is an options object. The most common options are : +- options.customTemplate : This is a path to custom template, that should override the default one from the platform. --- End diff -- How about something like this: Templates allow you to use preexisting code to jumpstart your project. Locate a template you wish to use. Then, create your project using that template, by specifying the --template flag during the create command, followed by your template source. You can createCordova project with a custom template located locally, in NPM, or GitHub. ``` $ cordova create hello com.example.hello HelloWorld --template $ cordova create hello com.example.hello HelloWorld --template $ cordova create hello com.example.hello HelloWorld --template ```
[GitHub] cordova-test-platform pull request #1: Doc requirements for platform api exp...
Github user audreyso commented on a diff in the pull request: https://github.com/apache/cordova-test-platform/pull/1#discussion_r128878157 --- Diff: PlatformRequirements.md --- @@ -0,0 +1,144 @@ + +# New Platform Checklist + +## Stand-alone scripts + +bin/create scripts +- bin/create _(typically a node script)_ +- bin/create.bat for windows +- windows .bat file typically just calls bin/create with node + +bin/update +- not entirely sure this code is run, or needs to exist with newish non-destructive platform updates + +## Package Expectations + +- Platforms must have a package.json in their root. +- Package.json exports a 'main', usually `"main": "src/cordova/Api.js"` +- This allows other modules to simply require() the path to this platform and get access to the Api. + +## Api (Platform) Expectations +- The PlatformApi class +- The PlatformApi class is an abstraction around a particular platform that exposes all the actions, properties, and methods for this platform so they are accessible programmatically. +- It can install & uninstall plugins with all source files, web assets and js files. +- It exposes a single 'prepare' method to provide a way for cordova-lib to apply a project's setting/www content to the platform. +- The PlatformApi class should be implemented by each platform that wants to use the new API flow. For those platforms, which don't provide their own PlatformApi, there will be a polyfill in cordova-lib. +- Platforms that implement their own PlatformApi instance should implement all prototype methods of this class to be fully compatible with cordova-lib. +- The PlatformApi instance should define the following field: +- platform : This is a String that defines a platform name. + +- Api.js exports static functions +- there is currently a requirement that the file be called Api.js (todo:change that) + --- End diff -- https://issues.apache.org/jira/browse/CB-13058 --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. --- - To unsubscribe, e-mail: dev-unsubscr...@cordova.apache.org For additional commands, e-mail: dev-h...@cordova.apache.org
[GitHub] cordova-test-platform pull request #1: Doc requirements for platform api exp...
Github user purplecabbage commented on a diff in the pull request: https://github.com/apache/cordova-test-platform/pull/1#discussion_r128877837 --- Diff: PlatformRequirements.md --- @@ -0,0 +1,144 @@ + +# New Platform Checklist + +## Stand-alone scripts + +bin/create scripts +- bin/create _(typically a node script)_ +- bin/create.bat for windows +- windows .bat file typically just calls bin/create with node + +bin/update +- not entirely sure this code is run, or needs to exist with newish non-destructive platform updates + +## Package Expectations + +- Platforms must have a package.json in their root. +- Package.json exports a 'main', usually `"main": "src/cordova/Api.js"` +- This allows other modules to simply require() the path to this platform and get access to the Api. + +## Api (Platform) Expectations +- The PlatformApi class +- The PlatformApi class is an abstraction around a particular platform that exposes all the actions, properties, and methods for this platform so they are accessible programmatically. +- It can install & uninstall plugins with all source files, web assets and js files. +- It exposes a single 'prepare' method to provide a way for cordova-lib to apply a project's setting/www content to the platform. +- The PlatformApi class should be implemented by each platform that wants to use the new API flow. For those platforms, which don't provide their own PlatformApi, there will be a polyfill in cordova-lib. +- Platforms that implement their own PlatformApi instance should implement all prototype methods of this class to be fully compatible with cordova-lib. +- The PlatformApi instance should define the following field: +- platform : This is a String that defines a platform name. + +- Api.js exports static functions +- there is currently a requirement that the file be called Api.js (todo:change that) + + +- Api.js exports static function `updatePlatform(destination, options, events);` --- End diff -- Yes, you can remove the update api. I would also recommend that you test it and verify that it does not get called. ie. try commenting out Api.updatePlatform in ios,android,browser,windows,test platforms and call cordova platform update for each ... --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. --- - To unsubscribe, e-mail: dev-unsubscr...@cordova.apache.org For additional commands, e-mail: dev-h...@cordova.apache.org
[GitHub] cordova-test-platform pull request #1: Doc requirements for platform api exp...
Github user audreyso commented on a diff in the pull request: https://github.com/apache/cordova-test-platform/pull/1#discussion_r128877652 --- Diff: PlatformRequirements.md --- @@ -0,0 +1,144 @@ + +# New Platform Checklist + +## Stand-alone scripts + +bin/create scripts +- bin/create _(typically a node script)_ +- bin/create.bat for windows +- windows .bat file typically just calls bin/create with node + +bin/update +- not entirely sure this code is run, or needs to exist with newish non-destructive platform updates + +## Package Expectations + +- Platforms must have a package.json in their root. +- Package.json exports a 'main', usually `"main": "src/cordova/Api.js"` +- This allows other modules to simply require() the path to this platform and get access to the Api. + +## Api (Platform) Expectations +- The PlatformApi class +- The PlatformApi class is an abstraction around a particular platform that exposes all the actions, properties, and methods for this platform so they are accessible programmatically. +- It can install & uninstall plugins with all source files, web assets and js files. +- It exposes a single 'prepare' method to provide a way for cordova-lib to apply a project's setting/www content to the platform. +- The PlatformApi class should be implemented by each platform that wants to use the new API flow. For those platforms, which don't provide their own PlatformApi, there will be a polyfill in cordova-lib. +- Platforms that implement their own PlatformApi instance should implement all prototype methods of this class to be fully compatible with cordova-lib. +- The PlatformApi instance should define the following field: +- platform : This is a String that defines a platform name. + +- Api.js exports static functions +- there is currently a requirement that the file be called Api.js (todo:change that) + + +- Api.js exports static function `updatePlatform(destination, options, events);` +- PlatformApi.updatePlatform = function (cordovaProject, options) {}; +- The `updatePlatform` method is equal to the bin/update script. It should update an already installed platform. It should accept a CordovaProject instance, that defines a project structure and configuration, that should be applied to the new platform, and an options object. +- cordovaProject: This is a CordovaProject instance that defines a project structure and configuration, that should be applied to the new platform. This argument is optional and if not defined, that platform is used as a standalone project and not as part of a Cordova project. +- options : This is an options object. The most common options are : +- options.customTemplate : This is a path to custom template, that should override the default one from platform. +- options.link : This is a flag that should indicate that the platform's sources will be linked to the installed platform instead of copying. + - The `updatePlatform` method must return a promise, which is either fulfilled with a PlatformApi instance or rejected with a CordovaError. + +- Api.js exports static function `createPlatform(destination, cfg, options, events);` +- PlatformApi.createPlatform = function(cordovaProject, options) {}; +- The `createPlatform method` is equal to the bin/create script. It should install the platform to a specified directory and create a platform project. It should accept a CordovaProject instance, that defines a project structure and configuration, that should be applied to the new platform, and an options object. +- cordovaProject : This is a CordovaProject instance that defines a project structure and configuration, that should be applied to the new platform. This argument is optional and if not defined, that platform is used as a standalone project and not as part of a Cordova project. +- options : This is an options object. The most common options are : +- options.customTemplate : This is a path to custom template, that should override the default one from the platform. +- options.link : This is a flag that should indicate that the platform's sources will be linked to the installed platform instead of copying. +- The `createPlatform` method must return a promise, which is either fulfilled with a PlatformApi instance or rejected with a CordovaError. + +The way most platforms work is somewhat tricky. The Api.js could be anywhere in the platform repo, ex. /templates/cordova/Api.js . When a new project is created for the platform, the platform copies this file (and supporting files ) to destination/cordova/Api.js. The project expectations demand that the Api.js file be available at
[GitHub] cordova-test-platform pull request #1: Doc requirements for platform api exp...
Github user audreyso commented on a diff in the pull request: https://github.com/apache/cordova-test-platform/pull/1#discussion_r128876824 --- Diff: PlatformRequirements.md --- @@ -0,0 +1,144 @@ + +# New Platform Checklist + +## Stand-alone scripts + +bin/create scripts +- bin/create _(typically a node script)_ +- bin/create.bat for windows +- windows .bat file typically just calls bin/create with node + +bin/update +- not entirely sure this code is run, or needs to exist with newish non-destructive platform updates + +## Package Expectations + +- Platforms must have a package.json in their root. +- Package.json exports a 'main', usually `"main": "src/cordova/Api.js"` +- This allows other modules to simply require() the path to this platform and get access to the Api. + +## Api (Platform) Expectations +- The PlatformApi class +- The PlatformApi class is an abstraction around a particular platform that exposes all the actions, properties, and methods for this platform so they are accessible programmatically. +- It can install & uninstall plugins with all source files, web assets and js files. +- It exposes a single 'prepare' method to provide a way for cordova-lib to apply a project's setting/www content to the platform. +- The PlatformApi class should be implemented by each platform that wants to use the new API flow. For those platforms, which don't provide their own PlatformApi, there will be a polyfill in cordova-lib. +- Platforms that implement their own PlatformApi instance should implement all prototype methods of this class to be fully compatible with cordova-lib. +- The PlatformApi instance should define the following field: +- platform : This is a String that defines a platform name. + +- Api.js exports static functions +- there is currently a requirement that the file be called Api.js (todo:change that) + + +- Api.js exports static function `updatePlatform(destination, options, events);` --- End diff -- Ohh okay! Just to confirm, all of the info about the updatePlatform function should be totally removed? --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. --- - To unsubscribe, e-mail: dev-unsubscr...@cordova.apache.org For additional commands, e-mail: dev-h...@cordova.apache.org
[GitHub] cordova-test-platform issue #1: Doc requirements for platform api expectatio...
Github user purplecabbage commented on the issue: https://github.com/apache/cordova-test-platform/pull/1 Another thing to note is that the tests that are in this repo *could* be used to verify the platformAPI for anyone attempting to implement it. --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. --- - To unsubscribe, e-mail: dev-unsubscr...@cordova.apache.org For additional commands, e-mail: dev-h...@cordova.apache.org
[GitHub] cordova-test-platform pull request #1: Doc requirements for platform api exp...
Github user purplecabbage commented on a diff in the pull request: https://github.com/apache/cordova-test-platform/pull/1#discussion_r128874756 --- Diff: PlatformRequirements.md --- @@ -0,0 +1,144 @@ + +# New Platform Checklist + +## Stand-alone scripts + +bin/create scripts +- bin/create _(typically a node script)_ +- bin/create.bat for windows +- windows .bat file typically just calls bin/create with node + +bin/update +- not entirely sure this code is run, or needs to exist with newish non-destructive platform updates + +## Package Expectations + +- Platforms must have a package.json in their root. +- Package.json exports a 'main', usually `"main": "src/cordova/Api.js"` +- This allows other modules to simply require() the path to this platform and get access to the Api. + +## Api (Platform) Expectations +- The PlatformApi class +- The PlatformApi class is an abstraction around a particular platform that exposes all the actions, properties, and methods for this platform so they are accessible programmatically. +- It can install & uninstall plugins with all source files, web assets and js files. +- It exposes a single 'prepare' method to provide a way for cordova-lib to apply a project's setting/www content to the platform. +- The PlatformApi class should be implemented by each platform that wants to use the new API flow. For those platforms, which don't provide their own PlatformApi, there will be a polyfill in cordova-lib. +- Platforms that implement their own PlatformApi instance should implement all prototype methods of this class to be fully compatible with cordova-lib. +- The PlatformApi instance should define the following field: +- platform : This is a String that defines a platform name. + +- Api.js exports static functions +- there is currently a requirement that the file be called Api.js (todo:change that) + --- End diff -- File an issue that we remove the requirement that the file be called Api.js --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. --- - To unsubscribe, e-mail: dev-unsubscr...@cordova.apache.org For additional commands, e-mail: dev-h...@cordova.apache.org
[GitHub] cordova-plugin-device pull request #67: Fixes the NPM build and much more th...
GitHub user Bubelbub opened a pull request: https://github.com/apache/cordova-plugin-device/pull/67 Fixes the NPM build and much more things [NPM 5] ð You can merge this pull request into a Git repository by running: $ git pull https://github.com/DDTChen/cordova-plugin-device master Alternatively you can review and apply these changes as the patch at: https://github.com/apache/cordova-plugin-device/pull/67.patch To close this pull request, make a commit to your master/trunk branch with (at least) the following in the commit message: This closes #67 commit 886a04e6de424b2e2a7a2602af9ab58884b13f1e Author: DDTChenDate: 2017-07-21T03:32:09Z build error test commit cef481d50ec5478a63fad16692ccd399d21bf881 Author: DDTChen Date: 2017-07-21T03:50:10Z add node version for android test commit 55e664571010eeedf80694a843b13e08c934b1a0 Author: DDTChen Date: 2017-07-21T03:55:19Z try set nodejs env commit 3b9a4f0f834bd3b5ae7fdbe3e613123244a9f43d Author: DDTChen Date: 2017-07-21T04:02:53Z install nvm and node commit 6b535afb623cb1a4422c1fe3bb3af7077cc41b23 Author: DDTChen Date: 2017-07-21T05:43:18Z fix install npm commit de1d82564c26a887cc31908772dbede86b81bcb0 Author: DDTChen Date: 2017-07-21T05:48:39Z skip SAUCE_LAB test commit 78a69b70a43cddc6f754071a53913bd8f814dd78 Author: DDTChen Date: 2017-07-21T05:54:57Z fix about 4.4 commit b72cbd1bc7e1f52101d365e06c063c038ddb768d Author: DDTChen Date: 2017-07-21T05:58:11Z fix android error commit 79f76843bcf67ca03909fa7b1cb1c50f089d405e Author: DDTChen Date: 2017-07-21T07:08:12Z run cordova-paramedic commit c120aa6a22645c5736f694f476046569cda4943c Author: DDTChen Date: 2017-07-21T07:38:35Z fix create android avd commit ca35f503cf085edbc0fb5f9743b258f4bf3ca7fc Author: DDTChen Date: 2017-07-21T07:47:37Z fix create android avd commit b0965e2a5cc7fca2748a7d67e1b311962730043e Author: DDTChen Date: 2017-07-21T08:04:51Z fix create android avd --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. --- - To unsubscribe, e-mail: dev-unsubscr...@cordova.apache.org For additional commands, e-mail: dev-h...@cordova.apache.org
[GitHub] cordova-test-platform pull request #1: Doc requirements for platform api exp...
Github user stevengill commented on a diff in the pull request: https://github.com/apache/cordova-test-platform/pull/1#discussion_r128869649 --- Diff: PlatformRequirements.md --- @@ -0,0 +1,144 @@ + +# New Platform Checklist + +## Stand-alone scripts + +bin/create scripts +- bin/create _(typically a node script)_ +- bin/create.bat for windows +- windows .bat file typically just calls bin/create with node + +bin/update +- not entirely sure this code is run, or needs to exist with newish non-destructive platform updates + +## Package Expectations + +- Platforms must have a package.json in their root. +- Package.json exports a 'main', usually `"main": "src/cordova/Api.js"` +- This allows other modules to simply require() the path to this platform and get access to the Api. + +## Api (Platform) Expectations +- The PlatformApi class +- The PlatformApi class is an abstraction around a particular platform that exposes all the actions, properties, and methods for this platform so they are accessible programmatically. +- It can install & uninstall plugins with all source files, web assets and js files. +- It exposes a single 'prepare' method to provide a way for cordova-lib to apply a project's setting/www content to the platform. +- The PlatformApi class should be implemented by each platform that wants to use the new API flow. For those platforms, which don't provide their own PlatformApi, there will be a polyfill in cordova-lib. +- Platforms that implement their own PlatformApi instance should implement all prototype methods of this class to be fully compatible with cordova-lib. +- The PlatformApi instance should define the following field: +- platform : This is a String that defines a platform name. + +- Api.js exports static functions +- there is currently a requirement that the file be called Api.js (todo:change that) + + +- Api.js exports static function `updatePlatform(destination, options, events);` +- PlatformApi.updatePlatform = function (cordovaProject, options) {}; +- The `updatePlatform` method is equal to the bin/update script. It should update an already installed platform. It should accept a CordovaProject instance, that defines a project structure and configuration, that should be applied to the new platform, and an options object. +- cordovaProject: This is a CordovaProject instance that defines a project structure and configuration, that should be applied to the new platform. This argument is optional and if not defined, that platform is used as a standalone project and not as part of a Cordova project. +- options : This is an options object. The most common options are : +- options.customTemplate : This is a path to custom template, that should override the default one from platform. +- options.link : This is a flag that should indicate that the platform's sources will be linked to the installed platform instead of copying. + - The `updatePlatform` method must return a promise, which is either fulfilled with a PlatformApi instance or rejected with a CordovaError. + +- Api.js exports static function `createPlatform(destination, cfg, options, events);` +- PlatformApi.createPlatform = function(cordovaProject, options) {}; +- The `createPlatform method` is equal to the bin/create script. It should install the platform to a specified directory and create a platform project. It should accept a CordovaProject instance, that defines a project structure and configuration, that should be applied to the new platform, and an options object. +- cordovaProject : This is a CordovaProject instance that defines a project structure and configuration, that should be applied to the new platform. This argument is optional and if not defined, that platform is used as a standalone project and not as part of a Cordova project. +- options : This is an options object. The most common options are : +- options.customTemplate : This is a path to custom template, that should override the default one from the platform. --- End diff -- maybe just link to the template documentation? https://cordova.apache.org/docs/en/latest/guide/cli/template.html --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. --- - To unsubscribe, e-mail: dev-unsubscr...@cordova.apache.org For additional commands, e-mail: dev-h...@cordova.apache.org
[GitHub] cordova-test-platform pull request #1: Doc requirements for platform api exp...
Github user stevengill commented on a diff in the pull request: https://github.com/apache/cordova-test-platform/pull/1#discussion_r128869395 --- Diff: PlatformRequirements.md --- @@ -0,0 +1,144 @@ + +# New Platform Checklist + +## Stand-alone scripts + +bin/create scripts +- bin/create _(typically a node script)_ +- bin/create.bat for windows +- windows .bat file typically just calls bin/create with node + +bin/update +- not entirely sure this code is run, or needs to exist with newish non-destructive platform updates + +## Package Expectations + +- Platforms must have a package.json in their root. +- Package.json exports a 'main', usually `"main": "src/cordova/Api.js"` +- This allows other modules to simply require() the path to this platform and get access to the Api. + +## Api (Platform) Expectations +- The PlatformApi class +- The PlatformApi class is an abstraction around a particular platform that exposes all the actions, properties, and methods for this platform so they are accessible programmatically. +- It can install & uninstall plugins with all source files, web assets and js files. +- It exposes a single 'prepare' method to provide a way for cordova-lib to apply a project's setting/www content to the platform. +- The PlatformApi class should be implemented by each platform that wants to use the new API flow. For those platforms, which don't provide their own PlatformApi, there will be a polyfill in cordova-lib. --- End diff -- yup. polyfill is on the way out --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. --- - To unsubscribe, e-mail: dev-unsubscr...@cordova.apache.org For additional commands, e-mail: dev-h...@cordova.apache.org
[GitHub] cordova-test-platform pull request #1: Doc requirements for platform api exp...
Github user filmaj commented on a diff in the pull request: https://github.com/apache/cordova-test-platform/pull/1#discussion_r128838089 --- Diff: PlatformRequirements.md --- @@ -0,0 +1,144 @@ + +# New Platform Checklist + +## Stand-alone scripts + +bin/create scripts +- bin/create _(typically a node script)_ +- bin/create.bat for windows +- windows .bat file typically just calls bin/create with node + +bin/update +- not entirely sure this code is run, or needs to exist with newish non-destructive platform updates + +## Package Expectations + +- Platforms must have a package.json in their root. +- Package.json exports a 'main', usually `"main": "src/cordova/Api.js"` +- This allows other modules to simply require() the path to this platform and get access to the Api. + +## Api (Platform) Expectations +- The PlatformApi class +- The PlatformApi class is an abstraction around a particular platform that exposes all the actions, properties, and methods for this platform so they are accessible programmatically. +- It can install & uninstall plugins with all source files, web assets and js files. +- It exposes a single 'prepare' method to provide a way for cordova-lib to apply a project's setting/www content to the platform. +- The PlatformApi class should be implemented by each platform that wants to use the new API flow. For those platforms, which don't provide their own PlatformApi, there will be a polyfill in cordova-lib. +- Platforms that implement their own PlatformApi instance should implement all prototype methods of this class to be fully compatible with cordova-lib. +- The PlatformApi instance should define the following field: +- platform : This is a String that defines a platform name. + +- Api.js exports static functions +- there is currently a requirement that the file be called Api.js (todo:change that) + + +- Api.js exports static function `updatePlatform(destination, options, events);` +- PlatformApi.updatePlatform = function (cordovaProject, options) {}; +- The `updatePlatform` method is equal to the bin/update script. It should update an already installed platform. It should accept a CordovaProject instance, that defines a project structure and configuration, that should be applied to the new platform, and an options object. +- cordovaProject: This is a CordovaProject instance that defines a project structure and configuration, that should be applied to the new platform. This argument is optional and if not defined, that platform is used as a standalone project and not as part of a Cordova project. +- options : This is an options object. The most common options are : +- options.customTemplate : This is a path to custom template, that should override the default one from platform. +- options.link : This is a flag that should indicate that the platform's sources will be linked to the installed platform instead of copying. + - The `updatePlatform` method must return a promise, which is either fulfilled with a PlatformApi instance or rejected with a CordovaError. + +- Api.js exports static function `createPlatform(destination, cfg, options, events);` +- PlatformApi.createPlatform = function(cordovaProject, options) {}; +- The `createPlatform method` is equal to the bin/create script. It should install the platform to a specified directory and create a platform project. It should accept a CordovaProject instance, that defines a project structure and configuration, that should be applied to the new platform, and an options object. +- cordovaProject : This is a CordovaProject instance that defines a project structure and configuration, that should be applied to the new platform. This argument is optional and if not defined, that platform is used as a standalone project and not as part of a Cordova project. +- options : This is an options object. The most common options are : +- options.customTemplate : This is a path to custom template, that should override the default one from the platform. +- options.link : This is a flag that should indicate that the platform's sources will be linked to the installed platform instead of copying. +- The `createPlatform` method must return a promise, which is either fulfilled with a PlatformApi instance or rejected with a CordovaError. + +The way most platforms work is somewhat tricky. The Api.js could be anywhere in the platform repo, ex. /templates/cordova/Api.js . When a new project is created for the platform, the platform copies this file (and supporting files ) to destination/cordova/Api.js. The project expectations demand that the Api.js file be available at
[GitHub] cordova-test-platform pull request #1: Doc requirements for platform api exp...
Github user filmaj commented on a diff in the pull request: https://github.com/apache/cordova-test-platform/pull/1#discussion_r128837876 --- Diff: PlatformRequirements.md --- @@ -0,0 +1,144 @@ + +# New Platform Checklist + +## Stand-alone scripts + +bin/create scripts +- bin/create _(typically a node script)_ +- bin/create.bat for windows +- windows .bat file typically just calls bin/create with node + +bin/update +- not entirely sure this code is run, or needs to exist with newish non-destructive platform updates + +## Package Expectations + +- Platforms must have a package.json in their root. +- Package.json exports a 'main', usually `"main": "src/cordova/Api.js"` +- This allows other modules to simply require() the path to this platform and get access to the Api. + +## Api (Platform) Expectations +- The PlatformApi class +- The PlatformApi class is an abstraction around a particular platform that exposes all the actions, properties, and methods for this platform so they are accessible programmatically. +- It can install & uninstall plugins with all source files, web assets and js files. +- It exposes a single 'prepare' method to provide a way for cordova-lib to apply a project's setting/www content to the platform. +- The PlatformApi class should be implemented by each platform that wants to use the new API flow. For those platforms, which don't provide their own PlatformApi, there will be a polyfill in cordova-lib. +- Platforms that implement their own PlatformApi instance should implement all prototype methods of this class to be fully compatible with cordova-lib. +- The PlatformApi instance should define the following field: +- platform : This is a String that defines a platform name. + +- Api.js exports static functions +- there is currently a requirement that the file be called Api.js (todo:change that) + + +- Api.js exports static function `updatePlatform(destination, options, events);` +- PlatformApi.updatePlatform = function (cordovaProject, options) {}; +- The `updatePlatform` method is equal to the bin/update script. It should update an already installed platform. It should accept a CordovaProject instance, that defines a project structure and configuration, that should be applied to the new platform, and an options object. +- cordovaProject: This is a CordovaProject instance that defines a project structure and configuration, that should be applied to the new platform. This argument is optional and if not defined, that platform is used as a standalone project and not as part of a Cordova project. +- options : This is an options object. The most common options are : +- options.customTemplate : This is a path to custom template, that should override the default one from platform. +- options.link : This is a flag that should indicate that the platform's sources will be linked to the installed platform instead of copying. + - The `updatePlatform` method must return a promise, which is either fulfilled with a PlatformApi instance or rejected with a CordovaError. + +- Api.js exports static function `createPlatform(destination, cfg, options, events);` +- PlatformApi.createPlatform = function(cordovaProject, options) {}; +- The `createPlatform method` is equal to the bin/create script. It should install the platform to a specified directory and create a platform project. It should accept a CordovaProject instance, that defines a project structure and configuration, that should be applied to the new platform, and an options object. +- cordovaProject : This is a CordovaProject instance that defines a project structure and configuration, that should be applied to the new platform. This argument is optional and if not defined, that platform is used as a standalone project and not as part of a Cordova project. +- options : This is an options object. The most common options are : +- options.customTemplate : This is a path to custom template, that should override the default one from the platform. +- options.link : This is a flag that should indicate that the platform's sources will be linked to the installed platform instead of copying. +- The `createPlatform` method must return a promise, which is either fulfilled with a PlatformApi instance or rejected with a CordovaError. + +The way most platforms work is somewhat tricky. The Api.js could be anywhere in the platform repo, ex. /templates/cordova/Api.js . When a new project is created for the platform, the platform copies this file (and supporting files ) to destination/cordova/Api.js. The project expectations demand that the Api.js file be available at
[GitHub] cordova-test-platform pull request #1: Doc requirements for platform api exp...
Github user filmaj commented on a diff in the pull request: https://github.com/apache/cordova-test-platform/pull/1#discussion_r128833191 --- Diff: PlatformRequirements.md --- @@ -0,0 +1,144 @@ + +# New Platform Checklist + +## Stand-alone scripts + +bin/create scripts --- End diff -- Can we describe what the purpose of the scripts are? i.e. "invoking this script would create a platform-specific cordova-compatible project shell" --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. --- - To unsubscribe, e-mail: dev-unsubscr...@cordova.apache.org For additional commands, e-mail: dev-h...@cordova.apache.org
[GitHub] cordova-test-platform pull request #1: Doc requirements for platform api exp...
Github user filmaj commented on a diff in the pull request: https://github.com/apache/cordova-test-platform/pull/1#discussion_r128838640 --- Diff: PlatformRequirements.md --- @@ -0,0 +1,144 @@ + +# New Platform Checklist + +## Stand-alone scripts + +bin/create scripts +- bin/create _(typically a node script)_ +- bin/create.bat for windows +- windows .bat file typically just calls bin/create with node + +bin/update +- not entirely sure this code is run, or needs to exist with newish non-destructive platform updates + +## Package Expectations + +- Platforms must have a package.json in their root. +- Package.json exports a 'main', usually `"main": "src/cordova/Api.js"` +- This allows other modules to simply require() the path to this platform and get access to the Api. + +## Api (Platform) Expectations +- The PlatformApi class +- The PlatformApi class is an abstraction around a particular platform that exposes all the actions, properties, and methods for this platform so they are accessible programmatically. +- It can install & uninstall plugins with all source files, web assets and js files. +- It exposes a single 'prepare' method to provide a way for cordova-lib to apply a project's setting/www content to the platform. +- The PlatformApi class should be implemented by each platform that wants to use the new API flow. For those platforms, which don't provide their own PlatformApi, there will be a polyfill in cordova-lib. +- Platforms that implement their own PlatformApi instance should implement all prototype methods of this class to be fully compatible with cordova-lib. +- The PlatformApi instance should define the following field: +- platform : This is a String that defines a platform name. + +- Api.js exports static functions +- there is currently a requirement that the file be called Api.js (todo:change that) + + +- Api.js exports static function `updatePlatform(destination, options, events);` +- PlatformApi.updatePlatform = function (cordovaProject, options) {}; +- The `updatePlatform` method is equal to the bin/update script. It should update an already installed platform. It should accept a CordovaProject instance, that defines a project structure and configuration, that should be applied to the new platform, and an options object. +- cordovaProject: This is a CordovaProject instance that defines a project structure and configuration, that should be applied to the new platform. This argument is optional and if not defined, that platform is used as a standalone project and not as part of a Cordova project. +- options : This is an options object. The most common options are : +- options.customTemplate : This is a path to custom template, that should override the default one from platform. +- options.link : This is a flag that should indicate that the platform's sources will be linked to the installed platform instead of copying. + - The `updatePlatform` method must return a promise, which is either fulfilled with a PlatformApi instance or rejected with a CordovaError. + +- Api.js exports static function `createPlatform(destination, cfg, options, events);` +- PlatformApi.createPlatform = function(cordovaProject, options) {}; +- The `createPlatform method` is equal to the bin/create script. It should install the platform to a specified directory and create a platform project. It should accept a CordovaProject instance, that defines a project structure and configuration, that should be applied to the new platform, and an options object. +- cordovaProject : This is a CordovaProject instance that defines a project structure and configuration, that should be applied to the new platform. This argument is optional and if not defined, that platform is used as a standalone project and not as part of a Cordova project. +- options : This is an options object. The most common options are : +- options.customTemplate : This is a path to custom template, that should override the default one from the platform. +- options.link : This is a flag that should indicate that the platform's sources will be linked to the installed platform instead of copying. +- The `createPlatform` method must return a promise, which is either fulfilled with a PlatformApi instance or rejected with a CordovaError. + +The way most platforms work is somewhat tricky. The Api.js could be anywhere in the platform repo, ex. /templates/cordova/Api.js . When a new project is created for the platform, the platform copies this file (and supporting files ) to destination/cordova/Api.js. The project expectations demand that the Api.js file be available at
[GitHub] cordova-test-platform pull request #1: Doc requirements for platform api exp...
Github user filmaj commented on a diff in the pull request: https://github.com/apache/cordova-test-platform/pull/1#discussion_r128836281 --- Diff: PlatformRequirements.md --- @@ -0,0 +1,144 @@ + +# New Platform Checklist + +## Stand-alone scripts + +bin/create scripts +- bin/create _(typically a node script)_ +- bin/create.bat for windows +- windows .bat file typically just calls bin/create with node + +bin/update +- not entirely sure this code is run, or needs to exist with newish non-destructive platform updates + +## Package Expectations + +- Platforms must have a package.json in their root. +- Package.json exports a 'main', usually `"main": "src/cordova/Api.js"` +- This allows other modules to simply require() the path to this platform and get access to the Api. + +## Api (Platform) Expectations +- The PlatformApi class +- The PlatformApi class is an abstraction around a particular platform that exposes all the actions, properties, and methods for this platform so they are accessible programmatically. +- It can install & uninstall plugins with all source files, web assets and js files. +- It exposes a single 'prepare' method to provide a way for cordova-lib to apply a project's setting/www content to the platform. +- The PlatformApi class should be implemented by each platform that wants to use the new API flow. For those platforms, which don't provide their own PlatformApi, there will be a polyfill in cordova-lib. +- Platforms that implement their own PlatformApi instance should implement all prototype methods of this class to be fully compatible with cordova-lib. +- The PlatformApi instance should define the following field: +- platform : This is a String that defines a platform name. + +- Api.js exports static functions +- there is currently a requirement that the file be called Api.js (todo:change that) + + +- Api.js exports static function `updatePlatform(destination, options, events);` +- PlatformApi.updatePlatform = function (cordovaProject, options) {}; +- The `updatePlatform` method is equal to the bin/update script. It should update an already installed platform. It should accept a CordovaProject instance, that defines a project structure and configuration, that should be applied to the new platform, and an options object. +- cordovaProject: This is a CordovaProject instance that defines a project structure and configuration, that should be applied to the new platform. This argument is optional and if not defined, that platform is used as a standalone project and not as part of a Cordova project. +- options : This is an options object. The most common options are : +- options.customTemplate : This is a path to custom template, that should override the default one from platform. +- options.link : This is a flag that should indicate that the platform's sources will be linked to the installed platform instead of copying. + - The `updatePlatform` method must return a promise, which is either fulfilled with a PlatformApi instance or rejected with a CordovaError. + +- Api.js exports static function `createPlatform(destination, cfg, options, events);` +- PlatformApi.createPlatform = function(cordovaProject, options) {}; +- The `createPlatform method` is equal to the bin/create script. It should install the platform to a specified directory and create a platform project. It should accept a CordovaProject instance, that defines a project structure and configuration, that should be applied to the new platform, and an options object. --- End diff -- Re: the `CordovaProject` object/instance, anything we can link to to provide more details on what this means and how it works? --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. --- - To unsubscribe, e-mail: dev-unsubscr...@cordova.apache.org For additional commands, e-mail: dev-h...@cordova.apache.org
[GitHub] cordova-test-platform pull request #1: Doc requirements for platform api exp...
Github user filmaj commented on a diff in the pull request: https://github.com/apache/cordova-test-platform/pull/1#discussion_r128834498 --- Diff: PlatformRequirements.md --- @@ -0,0 +1,144 @@ + +# New Platform Checklist + +## Stand-alone scripts + +bin/create scripts +- bin/create _(typically a node script)_ +- bin/create.bat for windows +- windows .bat file typically just calls bin/create with node + +bin/update +- not entirely sure this code is run, or needs to exist with newish non-destructive platform updates + +## Package Expectations + +- Platforms must have a package.json in their root. +- Package.json exports a 'main', usually `"main": "src/cordova/Api.js"` +- This allows other modules to simply require() the path to this platform and get access to the Api. + +## Api (Platform) Expectations +- The PlatformApi class +- The PlatformApi class is an abstraction around a particular platform that exposes all the actions, properties, and methods for this platform so they are accessible programmatically. +- It can install & uninstall plugins with all source files, web assets and js files. +- It exposes a single 'prepare' method to provide a way for cordova-lib to apply a project's setting/www content to the platform. +- The PlatformApi class should be implemented by each platform that wants to use the new API flow. For those platforms, which don't provide their own PlatformApi, there will be a polyfill in cordova-lib. --- End diff -- I'm unsure about this point, as I've heard the polyfill is on its way out. Can someone else confirm? --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. --- - To unsubscribe, e-mail: dev-unsubscr...@cordova.apache.org For additional commands, e-mail: dev-h...@cordova.apache.org
[GitHub] cordova-test-platform pull request #1: Doc requirements for platform api exp...
Github user filmaj commented on a diff in the pull request: https://github.com/apache/cordova-test-platform/pull/1#discussion_r128837070 --- Diff: PlatformRequirements.md --- @@ -0,0 +1,144 @@ + +# New Platform Checklist + +## Stand-alone scripts + +bin/create scripts +- bin/create _(typically a node script)_ +- bin/create.bat for windows +- windows .bat file typically just calls bin/create with node + +bin/update +- not entirely sure this code is run, or needs to exist with newish non-destructive platform updates + +## Package Expectations + +- Platforms must have a package.json in their root. +- Package.json exports a 'main', usually `"main": "src/cordova/Api.js"` +- This allows other modules to simply require() the path to this platform and get access to the Api. + +## Api (Platform) Expectations +- The PlatformApi class +- The PlatformApi class is an abstraction around a particular platform that exposes all the actions, properties, and methods for this platform so they are accessible programmatically. +- It can install & uninstall plugins with all source files, web assets and js files. +- It exposes a single 'prepare' method to provide a way for cordova-lib to apply a project's setting/www content to the platform. +- The PlatformApi class should be implemented by each platform that wants to use the new API flow. For those platforms, which don't provide their own PlatformApi, there will be a polyfill in cordova-lib. +- Platforms that implement their own PlatformApi instance should implement all prototype methods of this class to be fully compatible with cordova-lib. +- The PlatformApi instance should define the following field: +- platform : This is a String that defines a platform name. + +- Api.js exports static functions +- there is currently a requirement that the file be called Api.js (todo:change that) + + +- Api.js exports static function `updatePlatform(destination, options, events);` +- PlatformApi.updatePlatform = function (cordovaProject, options) {}; +- The `updatePlatform` method is equal to the bin/update script. It should update an already installed platform. It should accept a CordovaProject instance, that defines a project structure and configuration, that should be applied to the new platform, and an options object. +- cordovaProject: This is a CordovaProject instance that defines a project structure and configuration, that should be applied to the new platform. This argument is optional and if not defined, that platform is used as a standalone project and not as part of a Cordova project. +- options : This is an options object. The most common options are : +- options.customTemplate : This is a path to custom template, that should override the default one from platform. +- options.link : This is a flag that should indicate that the platform's sources will be linked to the installed platform instead of copying. + - The `updatePlatform` method must return a promise, which is either fulfilled with a PlatformApi instance or rejected with a CordovaError. + +- Api.js exports static function `createPlatform(destination, cfg, options, events);` +- PlatformApi.createPlatform = function(cordovaProject, options) {}; +- The `createPlatform method` is equal to the bin/create script. It should install the platform to a specified directory and create a platform project. It should accept a CordovaProject instance, that defines a project structure and configuration, that should be applied to the new platform, and an options object. +- cordovaProject : This is a CordovaProject instance that defines a project structure and configuration, that should be applied to the new platform. This argument is optional and if not defined, that platform is used as a standalone project and not as part of a Cordova project. +- options : This is an options object. The most common options are : +- options.customTemplate : This is a path to custom template, that should override the default one from the platform. +- options.link : This is a flag that should indicate that the platform's sources will be linked to the installed platform instead of copying. +- The `createPlatform` method must return a promise, which is either fulfilled with a PlatformApi instance or rejected with a CordovaError. + +The way most platforms work is somewhat tricky. The Api.js could be anywhere in the platform repo, ex. /templates/cordova/Api.js . When a new project is created for the platform, the platform copies this file (and supporting files ) to destination/cordova/Api.js. The project expectations demand that the Api.js file be available at
[GitHub] cordova-test-platform pull request #1: Doc requirements for platform api exp...
Github user filmaj commented on a diff in the pull request: https://github.com/apache/cordova-test-platform/pull/1#discussion_r128837925 --- Diff: PlatformRequirements.md --- @@ -0,0 +1,144 @@ + +# New Platform Checklist + +## Stand-alone scripts + +bin/create scripts +- bin/create _(typically a node script)_ +- bin/create.bat for windows +- windows .bat file typically just calls bin/create with node + +bin/update +- not entirely sure this code is run, or needs to exist with newish non-destructive platform updates + +## Package Expectations + +- Platforms must have a package.json in their root. +- Package.json exports a 'main', usually `"main": "src/cordova/Api.js"` +- This allows other modules to simply require() the path to this platform and get access to the Api. + +## Api (Platform) Expectations +- The PlatformApi class +- The PlatformApi class is an abstraction around a particular platform that exposes all the actions, properties, and methods for this platform so they are accessible programmatically. +- It can install & uninstall plugins with all source files, web assets and js files. +- It exposes a single 'prepare' method to provide a way for cordova-lib to apply a project's setting/www content to the platform. +- The PlatformApi class should be implemented by each platform that wants to use the new API flow. For those platforms, which don't provide their own PlatformApi, there will be a polyfill in cordova-lib. +- Platforms that implement their own PlatformApi instance should implement all prototype methods of this class to be fully compatible with cordova-lib. +- The PlatformApi instance should define the following field: +- platform : This is a String that defines a platform name. + +- Api.js exports static functions +- there is currently a requirement that the file be called Api.js (todo:change that) + + +- Api.js exports static function `updatePlatform(destination, options, events);` +- PlatformApi.updatePlatform = function (cordovaProject, options) {}; +- The `updatePlatform` method is equal to the bin/update script. It should update an already installed platform. It should accept a CordovaProject instance, that defines a project structure and configuration, that should be applied to the new platform, and an options object. +- cordovaProject: This is a CordovaProject instance that defines a project structure and configuration, that should be applied to the new platform. This argument is optional and if not defined, that platform is used as a standalone project and not as part of a Cordova project. +- options : This is an options object. The most common options are : +- options.customTemplate : This is a path to custom template, that should override the default one from platform. +- options.link : This is a flag that should indicate that the platform's sources will be linked to the installed platform instead of copying. + - The `updatePlatform` method must return a promise, which is either fulfilled with a PlatformApi instance or rejected with a CordovaError. + +- Api.js exports static function `createPlatform(destination, cfg, options, events);` +- PlatformApi.createPlatform = function(cordovaProject, options) {}; +- The `createPlatform method` is equal to the bin/create script. It should install the platform to a specified directory and create a platform project. It should accept a CordovaProject instance, that defines a project structure and configuration, that should be applied to the new platform, and an options object. +- cordovaProject : This is a CordovaProject instance that defines a project structure and configuration, that should be applied to the new platform. This argument is optional and if not defined, that platform is used as a standalone project and not as part of a Cordova project. +- options : This is an options object. The most common options are : +- options.customTemplate : This is a path to custom template, that should override the default one from the platform. +- options.link : This is a flag that should indicate that the platform's sources will be linked to the installed platform instead of copying. +- The `createPlatform` method must return a promise, which is either fulfilled with a PlatformApi instance or rejected with a CordovaError. + +The way most platforms work is somewhat tricky. The Api.js could be anywhere in the platform repo, ex. /templates/cordova/Api.js . When a new project is created for the platform, the platform copies this file (and supporting files ) to destination/cordova/Api.js. The project expectations demand that the Api.js file be available at
[GitHub] cordova-test-platform pull request #1: Doc requirements for platform api exp...
Github user filmaj commented on a diff in the pull request: https://github.com/apache/cordova-test-platform/pull/1#discussion_r128836475 --- Diff: PlatformRequirements.md --- @@ -0,0 +1,144 @@ + +# New Platform Checklist + +## Stand-alone scripts + +bin/create scripts +- bin/create _(typically a node script)_ +- bin/create.bat for windows +- windows .bat file typically just calls bin/create with node + +bin/update +- not entirely sure this code is run, or needs to exist with newish non-destructive platform updates + +## Package Expectations + +- Platforms must have a package.json in their root. +- Package.json exports a 'main', usually `"main": "src/cordova/Api.js"` +- This allows other modules to simply require() the path to this platform and get access to the Api. + +## Api (Platform) Expectations +- The PlatformApi class +- The PlatformApi class is an abstraction around a particular platform that exposes all the actions, properties, and methods for this platform so they are accessible programmatically. +- It can install & uninstall plugins with all source files, web assets and js files. +- It exposes a single 'prepare' method to provide a way for cordova-lib to apply a project's setting/www content to the platform. +- The PlatformApi class should be implemented by each platform that wants to use the new API flow. For those platforms, which don't provide their own PlatformApi, there will be a polyfill in cordova-lib. +- Platforms that implement their own PlatformApi instance should implement all prototype methods of this class to be fully compatible with cordova-lib. +- The PlatformApi instance should define the following field: +- platform : This is a String that defines a platform name. + +- Api.js exports static functions +- there is currently a requirement that the file be called Api.js (todo:change that) + + +- Api.js exports static function `updatePlatform(destination, options, events);` +- PlatformApi.updatePlatform = function (cordovaProject, options) {}; +- The `updatePlatform` method is equal to the bin/update script. It should update an already installed platform. It should accept a CordovaProject instance, that defines a project structure and configuration, that should be applied to the new platform, and an options object. +- cordovaProject: This is a CordovaProject instance that defines a project structure and configuration, that should be applied to the new platform. This argument is optional and if not defined, that platform is used as a standalone project and not as part of a Cordova project. +- options : This is an options object. The most common options are : +- options.customTemplate : This is a path to custom template, that should override the default one from platform. +- options.link : This is a flag that should indicate that the platform's sources will be linked to the installed platform instead of copying. + - The `updatePlatform` method must return a promise, which is either fulfilled with a PlatformApi instance or rejected with a CordovaError. + +- Api.js exports static function `createPlatform(destination, cfg, options, events);` +- PlatformApi.createPlatform = function(cordovaProject, options) {}; +- The `createPlatform method` is equal to the bin/create script. It should install the platform to a specified directory and create a platform project. It should accept a CordovaProject instance, that defines a project structure and configuration, that should be applied to the new platform, and an options object. +- cordovaProject : This is a CordovaProject instance that defines a project structure and configuration, that should be applied to the new platform. This argument is optional and if not defined, that platform is used as a standalone project and not as part of a Cordova project. +- options : This is an options object. The most common options are : +- options.customTemplate : This is a path to custom template, that should override the default one from the platform. --- End diff -- I think we need a pre-amble about what a template is and how it is used in the context of `create`. --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. --- - To unsubscribe, e-mail: dev-unsubscr...@cordova.apache.org For additional commands, e-mail: dev-h...@cordova.apache.org
[GitHub] cordova-test-platform pull request #1: Doc requirements for platform api exp...
Github user filmaj commented on a diff in the pull request: https://github.com/apache/cordova-test-platform/pull/1#discussion_r128838987 --- Diff: PlatformRequirements.md --- @@ -0,0 +1,144 @@ + +# New Platform Checklist + +## Stand-alone scripts + +bin/create scripts +- bin/create _(typically a node script)_ +- bin/create.bat for windows +- windows .bat file typically just calls bin/create with node + +bin/update +- not entirely sure this code is run, or needs to exist with newish non-destructive platform updates + +## Package Expectations + +- Platforms must have a package.json in their root. +- Package.json exports a 'main', usually `"main": "src/cordova/Api.js"` +- This allows other modules to simply require() the path to this platform and get access to the Api. + +## Api (Platform) Expectations +- The PlatformApi class +- The PlatformApi class is an abstraction around a particular platform that exposes all the actions, properties, and methods for this platform so they are accessible programmatically. +- It can install & uninstall plugins with all source files, web assets and js files. +- It exposes a single 'prepare' method to provide a way for cordova-lib to apply a project's setting/www content to the platform. +- The PlatformApi class should be implemented by each platform that wants to use the new API flow. For those platforms, which don't provide their own PlatformApi, there will be a polyfill in cordova-lib. +- Platforms that implement their own PlatformApi instance should implement all prototype methods of this class to be fully compatible with cordova-lib. +- The PlatformApi instance should define the following field: +- platform : This is a String that defines a platform name. + +- Api.js exports static functions +- there is currently a requirement that the file be called Api.js (todo:change that) + + +- Api.js exports static function `updatePlatform(destination, options, events);` +- PlatformApi.updatePlatform = function (cordovaProject, options) {}; +- The `updatePlatform` method is equal to the bin/update script. It should update an already installed platform. It should accept a CordovaProject instance, that defines a project structure and configuration, that should be applied to the new platform, and an options object. +- cordovaProject: This is a CordovaProject instance that defines a project structure and configuration, that should be applied to the new platform. This argument is optional and if not defined, that platform is used as a standalone project and not as part of a Cordova project. +- options : This is an options object. The most common options are : +- options.customTemplate : This is a path to custom template, that should override the default one from platform. +- options.link : This is a flag that should indicate that the platform's sources will be linked to the installed platform instead of copying. + - The `updatePlatform` method must return a promise, which is either fulfilled with a PlatformApi instance or rejected with a CordovaError. + +- Api.js exports static function `createPlatform(destination, cfg, options, events);` +- PlatformApi.createPlatform = function(cordovaProject, options) {}; +- The `createPlatform method` is equal to the bin/create script. It should install the platform to a specified directory and create a platform project. It should accept a CordovaProject instance, that defines a project structure and configuration, that should be applied to the new platform, and an options object. +- cordovaProject : This is a CordovaProject instance that defines a project structure and configuration, that should be applied to the new platform. This argument is optional and if not defined, that platform is used as a standalone project and not as part of a Cordova project. +- options : This is an options object. The most common options are : +- options.customTemplate : This is a path to custom template, that should override the default one from the platform. +- options.link : This is a flag that should indicate that the platform's sources will be linked to the installed platform instead of copying. +- The `createPlatform` method must return a promise, which is either fulfilled with a PlatformApi instance or rejected with a CordovaError. + +The way most platforms work is somewhat tricky. The Api.js could be anywhere in the platform repo, ex. /templates/cordova/Api.js . When a new project is created for the platform, the platform copies this file (and supporting files ) to destination/cordova/Api.js. The project expectations demand that the Api.js file be available at
[GitHub] cordova-test-platform pull request #1: Doc requirements for platform api exp...
Github user filmaj commented on a diff in the pull request: https://github.com/apache/cordova-test-platform/pull/1#discussion_r128833488 --- Diff: PlatformRequirements.md --- @@ -0,0 +1,144 @@ + +# New Platform Checklist + +## Stand-alone scripts + +bin/create scripts +- bin/create _(typically a node script)_ +- bin/create.bat for windows +- windows .bat file typically just calls bin/create with node + +bin/update --- End diff -- I think we should remove this, as the `update` script seems to be going away, e.g. https://issues.apache.org/jira/browse/CB-12948 --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. --- - To unsubscribe, e-mail: dev-unsubscr...@cordova.apache.org For additional commands, e-mail: dev-h...@cordova.apache.org
[GitHub] cordova-test-platform pull request #1: Doc requirements for platform api exp...
Github user filmaj commented on a diff in the pull request: https://github.com/apache/cordova-test-platform/pull/1#discussion_r128838263 --- Diff: PlatformRequirements.md --- @@ -0,0 +1,144 @@ + +# New Platform Checklist + +## Stand-alone scripts + +bin/create scripts +- bin/create _(typically a node script)_ +- bin/create.bat for windows +- windows .bat file typically just calls bin/create with node + +bin/update +- not entirely sure this code is run, or needs to exist with newish non-destructive platform updates + +## Package Expectations + +- Platforms must have a package.json in their root. +- Package.json exports a 'main', usually `"main": "src/cordova/Api.js"` +- This allows other modules to simply require() the path to this platform and get access to the Api. + +## Api (Platform) Expectations +- The PlatformApi class +- The PlatformApi class is an abstraction around a particular platform that exposes all the actions, properties, and methods for this platform so they are accessible programmatically. +- It can install & uninstall plugins with all source files, web assets and js files. +- It exposes a single 'prepare' method to provide a way for cordova-lib to apply a project's setting/www content to the platform. +- The PlatformApi class should be implemented by each platform that wants to use the new API flow. For those platforms, which don't provide their own PlatformApi, there will be a polyfill in cordova-lib. +- Platforms that implement their own PlatformApi instance should implement all prototype methods of this class to be fully compatible with cordova-lib. +- The PlatformApi instance should define the following field: +- platform : This is a String that defines a platform name. + +- Api.js exports static functions +- there is currently a requirement that the file be called Api.js (todo:change that) + + +- Api.js exports static function `updatePlatform(destination, options, events);` +- PlatformApi.updatePlatform = function (cordovaProject, options) {}; +- The `updatePlatform` method is equal to the bin/update script. It should update an already installed platform. It should accept a CordovaProject instance, that defines a project structure and configuration, that should be applied to the new platform, and an options object. +- cordovaProject: This is a CordovaProject instance that defines a project structure and configuration, that should be applied to the new platform. This argument is optional and if not defined, that platform is used as a standalone project and not as part of a Cordova project. +- options : This is an options object. The most common options are : +- options.customTemplate : This is a path to custom template, that should override the default one from platform. +- options.link : This is a flag that should indicate that the platform's sources will be linked to the installed platform instead of copying. + - The `updatePlatform` method must return a promise, which is either fulfilled with a PlatformApi instance or rejected with a CordovaError. + +- Api.js exports static function `createPlatform(destination, cfg, options, events);` +- PlatformApi.createPlatform = function(cordovaProject, options) {}; +- The `createPlatform method` is equal to the bin/create script. It should install the platform to a specified directory and create a platform project. It should accept a CordovaProject instance, that defines a project structure and configuration, that should be applied to the new platform, and an options object. +- cordovaProject : This is a CordovaProject instance that defines a project structure and configuration, that should be applied to the new platform. This argument is optional and if not defined, that platform is used as a standalone project and not as part of a Cordova project. +- options : This is an options object. The most common options are : +- options.customTemplate : This is a path to custom template, that should override the default one from the platform. +- options.link : This is a flag that should indicate that the platform's sources will be linked to the installed platform instead of copying. +- The `createPlatform` method must return a promise, which is either fulfilled with a PlatformApi instance or rejected with a CordovaError. + +The way most platforms work is somewhat tricky. The Api.js could be anywhere in the platform repo, ex. /templates/cordova/Api.js . When a new project is created for the platform, the platform copies this file (and supporting files ) to destination/cordova/Api.js. The project expectations demand that the Api.js file be available at
[GitHub] cordova-test-platform pull request #1: Doc requirements for platform api exp...
Github user filmaj commented on a diff in the pull request: https://github.com/apache/cordova-test-platform/pull/1#discussion_r128837813 --- Diff: PlatformRequirements.md --- @@ -0,0 +1,144 @@ + +# New Platform Checklist + +## Stand-alone scripts + +bin/create scripts +- bin/create _(typically a node script)_ +- bin/create.bat for windows +- windows .bat file typically just calls bin/create with node + +bin/update +- not entirely sure this code is run, or needs to exist with newish non-destructive platform updates + +## Package Expectations + +- Platforms must have a package.json in their root. +- Package.json exports a 'main', usually `"main": "src/cordova/Api.js"` +- This allows other modules to simply require() the path to this platform and get access to the Api. + +## Api (Platform) Expectations +- The PlatformApi class +- The PlatformApi class is an abstraction around a particular platform that exposes all the actions, properties, and methods for this platform so they are accessible programmatically. +- It can install & uninstall plugins with all source files, web assets and js files. +- It exposes a single 'prepare' method to provide a way for cordova-lib to apply a project's setting/www content to the platform. +- The PlatformApi class should be implemented by each platform that wants to use the new API flow. For those platforms, which don't provide their own PlatformApi, there will be a polyfill in cordova-lib. +- Platforms that implement their own PlatformApi instance should implement all prototype methods of this class to be fully compatible with cordova-lib. +- The PlatformApi instance should define the following field: +- platform : This is a String that defines a platform name. + +- Api.js exports static functions +- there is currently a requirement that the file be called Api.js (todo:change that) + + +- Api.js exports static function `updatePlatform(destination, options, events);` +- PlatformApi.updatePlatform = function (cordovaProject, options) {}; +- The `updatePlatform` method is equal to the bin/update script. It should update an already installed platform. It should accept a CordovaProject instance, that defines a project structure and configuration, that should be applied to the new platform, and an options object. +- cordovaProject: This is a CordovaProject instance that defines a project structure and configuration, that should be applied to the new platform. This argument is optional and if not defined, that platform is used as a standalone project and not as part of a Cordova project. +- options : This is an options object. The most common options are : +- options.customTemplate : This is a path to custom template, that should override the default one from platform. +- options.link : This is a flag that should indicate that the platform's sources will be linked to the installed platform instead of copying. + - The `updatePlatform` method must return a promise, which is either fulfilled with a PlatformApi instance or rejected with a CordovaError. + +- Api.js exports static function `createPlatform(destination, cfg, options, events);` +- PlatformApi.createPlatform = function(cordovaProject, options) {}; +- The `createPlatform method` is equal to the bin/create script. It should install the platform to a specified directory and create a platform project. It should accept a CordovaProject instance, that defines a project structure and configuration, that should be applied to the new platform, and an options object. +- cordovaProject : This is a CordovaProject instance that defines a project structure and configuration, that should be applied to the new platform. This argument is optional and if not defined, that platform is used as a standalone project and not as part of a Cordova project. +- options : This is an options object. The most common options are : +- options.customTemplate : This is a path to custom template, that should override the default one from the platform. +- options.link : This is a flag that should indicate that the platform's sources will be linked to the installed platform instead of copying. +- The `createPlatform` method must return a promise, which is either fulfilled with a PlatformApi instance or rejected with a CordovaError. + +The way most platforms work is somewhat tricky. The Api.js could be anywhere in the platform repo, ex. /templates/cordova/Api.js . When a new project is created for the platform, the platform copies this file (and supporting files ) to destination/cordova/Api.js. The project expectations demand that the Api.js file be available at
[GitHub] cordova-test-platform pull request #1: Doc requirements for platform api exp...
Github user filmaj commented on a diff in the pull request: https://github.com/apache/cordova-test-platform/pull/1#discussion_r128834387 --- Diff: PlatformRequirements.md --- @@ -0,0 +1,144 @@ + +# New Platform Checklist + +## Stand-alone scripts + +bin/create scripts +- bin/create _(typically a node script)_ +- bin/create.bat for windows +- windows .bat file typically just calls bin/create with node + +bin/update +- not entirely sure this code is run, or needs to exist with newish non-destructive platform updates + +## Package Expectations + +- Platforms must have a package.json in their root. +- Package.json exports a 'main', usually `"main": "src/cordova/Api.js"` +- This allows other modules to simply require() the path to this platform and get access to the Api. + +## Api (Platform) Expectations +- The PlatformApi class +- The PlatformApi class is an abstraction around a particular platform that exposes all the actions, properties, and methods for this platform so they are accessible programmatically. +- It can install & uninstall plugins with all source files, web assets and js files. +- It exposes a single 'prepare' method to provide a way for cordova-lib to apply a project's setting/www content to the platform. --- End diff -- I would expand on this, in particular the "project settings" part. Something like "interpolates metadata from a cordova project's config.xml (link to cordova docs' config.xml section) (such as application name, description, etc.) into the format expected by the platform." --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. --- - To unsubscribe, e-mail: dev-unsubscr...@cordova.apache.org For additional commands, e-mail: dev-h...@cordova.apache.org
[GitHub] cordova-test-platform pull request #1: Doc requirements for platform api exp...
Github user filmaj commented on a diff in the pull request: https://github.com/apache/cordova-test-platform/pull/1#discussion_r128833714 --- Diff: PlatformRequirements.md --- @@ -0,0 +1,144 @@ + +# New Platform Checklist + +## Stand-alone scripts + +bin/create scripts +- bin/create _(typically a node script)_ +- bin/create.bat for windows +- windows .bat file typically just calls bin/create with node + +bin/update +- not entirely sure this code is run, or needs to exist with newish non-destructive platform updates + +## Package Expectations + +- Platforms must have a package.json in their root. +- Package.json exports a 'main', usually `"main": "src/cordova/Api.js"` --- End diff -- I would tweak the wording and remove "usually" - gives a sense of uncertainty. --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. --- - To unsubscribe, e-mail: dev-unsubscr...@cordova.apache.org For additional commands, e-mail: dev-h...@cordova.apache.org
[GitHub] cordova-test-platform pull request #1: Doc requirements for platform api exp...
Github user filmaj commented on a diff in the pull request: https://github.com/apache/cordova-test-platform/pull/1#discussion_r128839290 --- Diff: PlatformRequirements.md --- @@ -0,0 +1,144 @@ + +# New Platform Checklist + +## Stand-alone scripts + +bin/create scripts +- bin/create _(typically a node script)_ +- bin/create.bat for windows +- windows .bat file typically just calls bin/create with node + +bin/update +- not entirely sure this code is run, or needs to exist with newish non-destructive platform updates + +## Package Expectations + +- Platforms must have a package.json in their root. +- Package.json exports a 'main', usually `"main": "src/cordova/Api.js"` +- This allows other modules to simply require() the path to this platform and get access to the Api. + +## Api (Platform) Expectations +- The PlatformApi class +- The PlatformApi class is an abstraction around a particular platform that exposes all the actions, properties, and methods for this platform so they are accessible programmatically. +- It can install & uninstall plugins with all source files, web assets and js files. +- It exposes a single 'prepare' method to provide a way for cordova-lib to apply a project's setting/www content to the platform. +- The PlatformApi class should be implemented by each platform that wants to use the new API flow. For those platforms, which don't provide their own PlatformApi, there will be a polyfill in cordova-lib. +- Platforms that implement their own PlatformApi instance should implement all prototype methods of this class to be fully compatible with cordova-lib. +- The PlatformApi instance should define the following field: +- platform : This is a String that defines a platform name. + +- Api.js exports static functions +- there is currently a requirement that the file be called Api.js (todo:change that) + + +- Api.js exports static function `updatePlatform(destination, options, events);` +- PlatformApi.updatePlatform = function (cordovaProject, options) {}; +- The `updatePlatform` method is equal to the bin/update script. It should update an already installed platform. It should accept a CordovaProject instance, that defines a project structure and configuration, that should be applied to the new platform, and an options object. +- cordovaProject: This is a CordovaProject instance that defines a project structure and configuration, that should be applied to the new platform. This argument is optional and if not defined, that platform is used as a standalone project and not as part of a Cordova project. +- options : This is an options object. The most common options are : +- options.customTemplate : This is a path to custom template, that should override the default one from platform. +- options.link : This is a flag that should indicate that the platform's sources will be linked to the installed platform instead of copying. + - The `updatePlatform` method must return a promise, which is either fulfilled with a PlatformApi instance or rejected with a CordovaError. + +- Api.js exports static function `createPlatform(destination, cfg, options, events);` +- PlatformApi.createPlatform = function(cordovaProject, options) {}; +- The `createPlatform method` is equal to the bin/create script. It should install the platform to a specified directory and create a platform project. It should accept a CordovaProject instance, that defines a project structure and configuration, that should be applied to the new platform, and an options object. +- cordovaProject : This is a CordovaProject instance that defines a project structure and configuration, that should be applied to the new platform. This argument is optional and if not defined, that platform is used as a standalone project and not as part of a Cordova project. +- options : This is an options object. The most common options are : +- options.customTemplate : This is a path to custom template, that should override the default one from the platform. +- options.link : This is a flag that should indicate that the platform's sources will be linked to the installed platform instead of copying. +- The `createPlatform` method must return a promise, which is either fulfilled with a PlatformApi instance or rejected with a CordovaError. + +The way most platforms work is somewhat tricky. The Api.js could be anywhere in the platform repo, ex. /templates/cordova/Api.js . When a new project is created for the platform, the platform copies this file (and supporting files ) to destination/cordova/Api.js. The project expectations demand that the Api.js file be available at
[GitHub] cordova-test-platform pull request #1: Doc requirements for platform api exp...
Github user filmaj commented on a diff in the pull request: https://github.com/apache/cordova-test-platform/pull/1#discussion_r128839772 --- Diff: PlatformRequirements.md --- @@ -0,0 +1,144 @@ + +# New Platform Checklist + +## Stand-alone scripts + +bin/create scripts +- bin/create _(typically a node script)_ +- bin/create.bat for windows +- windows .bat file typically just calls bin/create with node + +bin/update +- not entirely sure this code is run, or needs to exist with newish non-destructive platform updates + +## Package Expectations + +- Platforms must have a package.json in their root. +- Package.json exports a 'main', usually `"main": "src/cordova/Api.js"` +- This allows other modules to simply require() the path to this platform and get access to the Api. + +## Api (Platform) Expectations +- The PlatformApi class +- The PlatformApi class is an abstraction around a particular platform that exposes all the actions, properties, and methods for this platform so they are accessible programmatically. +- It can install & uninstall plugins with all source files, web assets and js files. +- It exposes a single 'prepare' method to provide a way for cordova-lib to apply a project's setting/www content to the platform. +- The PlatformApi class should be implemented by each platform that wants to use the new API flow. For those platforms, which don't provide their own PlatformApi, there will be a polyfill in cordova-lib. +- Platforms that implement their own PlatformApi instance should implement all prototype methods of this class to be fully compatible with cordova-lib. +- The PlatformApi instance should define the following field: +- platform : This is a String that defines a platform name. + +- Api.js exports static functions +- there is currently a requirement that the file be called Api.js (todo:change that) + + +- Api.js exports static function `updatePlatform(destination, options, events);` +- PlatformApi.updatePlatform = function (cordovaProject, options) {}; +- The `updatePlatform` method is equal to the bin/update script. It should update an already installed platform. It should accept a CordovaProject instance, that defines a project structure and configuration, that should be applied to the new platform, and an options object. +- cordovaProject: This is a CordovaProject instance that defines a project structure and configuration, that should be applied to the new platform. This argument is optional and if not defined, that platform is used as a standalone project and not as part of a Cordova project. +- options : This is an options object. The most common options are : +- options.customTemplate : This is a path to custom template, that should override the default one from platform. +- options.link : This is a flag that should indicate that the platform's sources will be linked to the installed platform instead of copying. + - The `updatePlatform` method must return a promise, which is either fulfilled with a PlatformApi instance or rejected with a CordovaError. + +- Api.js exports static function `createPlatform(destination, cfg, options, events);` +- PlatformApi.createPlatform = function(cordovaProject, options) {}; +- The `createPlatform method` is equal to the bin/create script. It should install the platform to a specified directory and create a platform project. It should accept a CordovaProject instance, that defines a project structure and configuration, that should be applied to the new platform, and an options object. +- cordovaProject : This is a CordovaProject instance that defines a project structure and configuration, that should be applied to the new platform. This argument is optional and if not defined, that platform is used as a standalone project and not as part of a Cordova project. +- options : This is an options object. The most common options are : +- options.customTemplate : This is a path to custom template, that should override the default one from the platform. +- options.link : This is a flag that should indicate that the platform's sources will be linked to the installed platform instead of copying. +- The `createPlatform` method must return a promise, which is either fulfilled with a PlatformApi instance or rejected with a CordovaError. + +The way most platforms work is somewhat tricky. The Api.js could be anywhere in the platform repo, ex. /templates/cordova/Api.js . When a new project is created for the platform, the platform copies this file (and supporting files ) to destination/cordova/Api.js. The project expectations demand that the Api.js file be available at
[GitHub] cordova-test-platform pull request #1: Doc requirements for platform api exp...
Github user filmaj commented on a diff in the pull request: https://github.com/apache/cordova-test-platform/pull/1#discussion_r128834664 --- Diff: PlatformRequirements.md --- @@ -0,0 +1,144 @@ + +# New Platform Checklist + +## Stand-alone scripts + +bin/create scripts +- bin/create _(typically a node script)_ +- bin/create.bat for windows +- windows .bat file typically just calls bin/create with node + +bin/update +- not entirely sure this code is run, or needs to exist with newish non-destructive platform updates + +## Package Expectations + +- Platforms must have a package.json in their root. +- Package.json exports a 'main', usually `"main": "src/cordova/Api.js"` +- This allows other modules to simply require() the path to this platform and get access to the Api. + +## Api (Platform) Expectations +- The PlatformApi class +- The PlatformApi class is an abstraction around a particular platform that exposes all the actions, properties, and methods for this platform so they are accessible programmatically. +- It can install & uninstall plugins with all source files, web assets and js files. +- It exposes a single 'prepare' method to provide a way for cordova-lib to apply a project's setting/www content to the platform. +- The PlatformApi class should be implemented by each platform that wants to use the new API flow. For those platforms, which don't provide their own PlatformApi, there will be a polyfill in cordova-lib. +- Platforms that implement their own PlatformApi instance should implement all prototype methods of this class to be fully compatible with cordova-lib. +- The PlatformApi instance should define the following field: +- platform : This is a String that defines a platform name. + +- Api.js exports static functions +- there is currently a requirement that the file be called Api.js (todo:change that) --- End diff -- Is this todo still applicable? I am not sure that _will_ change. --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. --- - To unsubscribe, e-mail: dev-unsubscr...@cordova.apache.org For additional commands, e-mail: dev-h...@cordova.apache.org
[GitHub] cordova-test-platform pull request #1: Doc requirements for platform api exp...
Github user filmaj commented on a diff in the pull request: https://github.com/apache/cordova-test-platform/pull/1#discussion_r128837509 --- Diff: PlatformRequirements.md --- @@ -0,0 +1,144 @@ + +# New Platform Checklist + +## Stand-alone scripts + +bin/create scripts +- bin/create _(typically a node script)_ +- bin/create.bat for windows +- windows .bat file typically just calls bin/create with node + +bin/update +- not entirely sure this code is run, or needs to exist with newish non-destructive platform updates + +## Package Expectations + +- Platforms must have a package.json in their root. +- Package.json exports a 'main', usually `"main": "src/cordova/Api.js"` +- This allows other modules to simply require() the path to this platform and get access to the Api. + +## Api (Platform) Expectations +- The PlatformApi class +- The PlatformApi class is an abstraction around a particular platform that exposes all the actions, properties, and methods for this platform so they are accessible programmatically. +- It can install & uninstall plugins with all source files, web assets and js files. +- It exposes a single 'prepare' method to provide a way for cordova-lib to apply a project's setting/www content to the platform. +- The PlatformApi class should be implemented by each platform that wants to use the new API flow. For those platforms, which don't provide their own PlatformApi, there will be a polyfill in cordova-lib. +- Platforms that implement their own PlatformApi instance should implement all prototype methods of this class to be fully compatible with cordova-lib. +- The PlatformApi instance should define the following field: +- platform : This is a String that defines a platform name. + +- Api.js exports static functions +- there is currently a requirement that the file be called Api.js (todo:change that) + + +- Api.js exports static function `updatePlatform(destination, options, events);` +- PlatformApi.updatePlatform = function (cordovaProject, options) {}; +- The `updatePlatform` method is equal to the bin/update script. It should update an already installed platform. It should accept a CordovaProject instance, that defines a project structure and configuration, that should be applied to the new platform, and an options object. +- cordovaProject: This is a CordovaProject instance that defines a project structure and configuration, that should be applied to the new platform. This argument is optional and if not defined, that platform is used as a standalone project and not as part of a Cordova project. +- options : This is an options object. The most common options are : +- options.customTemplate : This is a path to custom template, that should override the default one from platform. +- options.link : This is a flag that should indicate that the platform's sources will be linked to the installed platform instead of copying. + - The `updatePlatform` method must return a promise, which is either fulfilled with a PlatformApi instance or rejected with a CordovaError. + +- Api.js exports static function `createPlatform(destination, cfg, options, events);` +- PlatformApi.createPlatform = function(cordovaProject, options) {}; +- The `createPlatform method` is equal to the bin/create script. It should install the platform to a specified directory and create a platform project. It should accept a CordovaProject instance, that defines a project structure and configuration, that should be applied to the new platform, and an options object. +- cordovaProject : This is a CordovaProject instance that defines a project structure and configuration, that should be applied to the new platform. This argument is optional and if not defined, that platform is used as a standalone project and not as part of a Cordova project. +- options : This is an options object. The most common options are : +- options.customTemplate : This is a path to custom template, that should override the default one from the platform. +- options.link : This is a flag that should indicate that the platform's sources will be linked to the installed platform instead of copying. +- The `createPlatform` method must return a promise, which is either fulfilled with a PlatformApi instance or rejected with a CordovaError. + +The way most platforms work is somewhat tricky. The Api.js could be anywhere in the platform repo, ex. /templates/cordova/Api.js . When a new project is created for the platform, the platform copies this file (and supporting files ) to destination/cordova/Api.js. The project expectations demand that the Api.js file be available at
[GitHub] cordova-test-platform pull request #1: Doc requirements for platform api exp...
Github user filmaj commented on a diff in the pull request: https://github.com/apache/cordova-test-platform/pull/1#discussion_r128837232 --- Diff: PlatformRequirements.md --- @@ -0,0 +1,144 @@ + +# New Platform Checklist + +## Stand-alone scripts + +bin/create scripts +- bin/create _(typically a node script)_ +- bin/create.bat for windows +- windows .bat file typically just calls bin/create with node + +bin/update +- not entirely sure this code is run, or needs to exist with newish non-destructive platform updates + +## Package Expectations + +- Platforms must have a package.json in their root. +- Package.json exports a 'main', usually `"main": "src/cordova/Api.js"` +- This allows other modules to simply require() the path to this platform and get access to the Api. + +## Api (Platform) Expectations +- The PlatformApi class +- The PlatformApi class is an abstraction around a particular platform that exposes all the actions, properties, and methods for this platform so they are accessible programmatically. +- It can install & uninstall plugins with all source files, web assets and js files. +- It exposes a single 'prepare' method to provide a way for cordova-lib to apply a project's setting/www content to the platform. +- The PlatformApi class should be implemented by each platform that wants to use the new API flow. For those platforms, which don't provide their own PlatformApi, there will be a polyfill in cordova-lib. +- Platforms that implement their own PlatformApi instance should implement all prototype methods of this class to be fully compatible with cordova-lib. +- The PlatformApi instance should define the following field: +- platform : This is a String that defines a platform name. + +- Api.js exports static functions +- there is currently a requirement that the file be called Api.js (todo:change that) + + +- Api.js exports static function `updatePlatform(destination, options, events);` +- PlatformApi.updatePlatform = function (cordovaProject, options) {}; +- The `updatePlatform` method is equal to the bin/update script. It should update an already installed platform. It should accept a CordovaProject instance, that defines a project structure and configuration, that should be applied to the new platform, and an options object. +- cordovaProject: This is a CordovaProject instance that defines a project structure and configuration, that should be applied to the new platform. This argument is optional and if not defined, that platform is used as a standalone project and not as part of a Cordova project. +- options : This is an options object. The most common options are : +- options.customTemplate : This is a path to custom template, that should override the default one from platform. +- options.link : This is a flag that should indicate that the platform's sources will be linked to the installed platform instead of copying. + - The `updatePlatform` method must return a promise, which is either fulfilled with a PlatformApi instance or rejected with a CordovaError. + +- Api.js exports static function `createPlatform(destination, cfg, options, events);` +- PlatformApi.createPlatform = function(cordovaProject, options) {}; +- The `createPlatform method` is equal to the bin/create script. It should install the platform to a specified directory and create a platform project. It should accept a CordovaProject instance, that defines a project structure and configuration, that should be applied to the new platform, and an options object. +- cordovaProject : This is a CordovaProject instance that defines a project structure and configuration, that should be applied to the new platform. This argument is optional and if not defined, that platform is used as a standalone project and not as part of a Cordova project. +- options : This is an options object. The most common options are : +- options.customTemplate : This is a path to custom template, that should override the default one from the platform. +- options.link : This is a flag that should indicate that the platform's sources will be linked to the installed platform instead of copying. +- The `createPlatform` method must return a promise, which is either fulfilled with a PlatformApi instance or rejected with a CordovaError. + +The way most platforms work is somewhat tricky. The Api.js could be anywhere in the platform repo, ex. /templates/cordova/Api.js . When a new project is created for the platform, the platform copies this file (and supporting files ) to destination/cordova/Api.js. The project expectations demand that the Api.js file be available at
[GitHub] cordova-test-platform pull request #1: Doc requirements for platform api exp...
Github user filmaj commented on a diff in the pull request: https://github.com/apache/cordova-test-platform/pull/1#discussion_r128836016 --- Diff: PlatformRequirements.md --- @@ -0,0 +1,144 @@ + +# New Platform Checklist + +## Stand-alone scripts + +bin/create scripts +- bin/create _(typically a node script)_ +- bin/create.bat for windows +- windows .bat file typically just calls bin/create with node + +bin/update +- not entirely sure this code is run, or needs to exist with newish non-destructive platform updates + +## Package Expectations + +- Platforms must have a package.json in their root. +- Package.json exports a 'main', usually `"main": "src/cordova/Api.js"` +- This allows other modules to simply require() the path to this platform and get access to the Api. + +## Api (Platform) Expectations +- The PlatformApi class +- The PlatformApi class is an abstraction around a particular platform that exposes all the actions, properties, and methods for this platform so they are accessible programmatically. +- It can install & uninstall plugins with all source files, web assets and js files. +- It exposes a single 'prepare' method to provide a way for cordova-lib to apply a project's setting/www content to the platform. +- The PlatformApi class should be implemented by each platform that wants to use the new API flow. For those platforms, which don't provide their own PlatformApi, there will be a polyfill in cordova-lib. +- Platforms that implement their own PlatformApi instance should implement all prototype methods of this class to be fully compatible with cordova-lib. +- The PlatformApi instance should define the following field: +- platform : This is a String that defines a platform name. + +- Api.js exports static functions +- there is currently a requirement that the file be called Api.js (todo:change that) + + +- Api.js exports static function `updatePlatform(destination, options, events);` --- End diff -- Similar to above note on update, not sure it is worth documenting this since it is going away. --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. --- - To unsubscribe, e-mail: dev-unsubscr...@cordova.apache.org For additional commands, e-mail: dev-h...@cordova.apache.org
[GitHub] cordova-test-platform pull request #1: Doc requirements for platform api exp...
Github user filmaj commented on a diff in the pull request: https://github.com/apache/cordova-test-platform/pull/1#discussion_r128834741 --- Diff: PlatformRequirements.md --- @@ -0,0 +1,144 @@ + +# New Platform Checklist + +## Stand-alone scripts + +bin/create scripts +- bin/create _(typically a node script)_ +- bin/create.bat for windows +- windows .bat file typically just calls bin/create with node + +bin/update +- not entirely sure this code is run, or needs to exist with newish non-destructive platform updates + +## Package Expectations + +- Platforms must have a package.json in their root. +- Package.json exports a 'main', usually `"main": "src/cordova/Api.js"` +- This allows other modules to simply require() the path to this platform and get access to the Api. + +## Api (Platform) Expectations +- The PlatformApi class +- The PlatformApi class is an abstraction around a particular platform that exposes all the actions, properties, and methods for this platform so they are accessible programmatically. +- It can install & uninstall plugins with all source files, web assets and js files. +- It exposes a single 'prepare' method to provide a way for cordova-lib to apply a project's setting/www content to the platform. +- The PlatformApi class should be implemented by each platform that wants to use the new API flow. For those platforms, which don't provide their own PlatformApi, there will be a polyfill in cordova-lib. +- Platforms that implement their own PlatformApi instance should implement all prototype methods of this class to be fully compatible with cordova-lib. +- The PlatformApi instance should define the following field: +- platform : This is a String that defines a platform name. + +- Api.js exports static functions --- End diff -- What is meant by "static" functions? That's not a very javascript-y concept. --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. --- - To unsubscribe, e-mail: dev-unsubscr...@cordova.apache.org For additional commands, e-mail: dev-h...@cordova.apache.org
[GitHub] cordova-test-platform pull request #1: Doc requirements for platform api exp...
Github user purplecabbage commented on a diff in the pull request: https://github.com/apache/cordova-test-platform/pull/1#discussion_r128835893 --- Diff: PlatformRequirements.md --- @@ -0,0 +1,144 @@ + +# New Platform Checklist + +## Stand-alone scripts + +bin/create scripts +- bin/create _(typically a node script)_ +- bin/create.bat for windows +- windows .bat file typically just calls bin/create with node + +bin/update +- not entirely sure this code is run, or needs to exist with newish non-destructive platform updates + +## Package Expectations + +- Platforms must have a package.json in their root. +- Package.json exports a 'main', usually `"main": "src/cordova/Api.js"` +- This allows other modules to simply require() the path to this platform and get access to the Api. + +## Api (Platform) Expectations +- The PlatformApi class +- The PlatformApi class is an abstraction around a particular platform that exposes all the actions, properties, and methods for this platform so they are accessible programmatically. +- It can install & uninstall plugins with all source files, web assets and js files. +- It exposes a single 'prepare' method to provide a way for cordova-lib to apply a project's setting/www content to the platform. +- The PlatformApi class should be implemented by each platform that wants to use the new API flow. For those platforms, which don't provide their own PlatformApi, there will be a polyfill in cordova-lib. +- Platforms that implement their own PlatformApi instance should implement all prototype methods of this class to be fully compatible with cordova-lib. +- The PlatformApi instance should define the following field: +- platform : This is a String that defines a platform name. + +- Api.js exports static functions +- there is currently a requirement that the file be called Api.js (todo:change that) + + +- Api.js exports static function `updatePlatform(destination, options, events);` +- PlatformApi.updatePlatform = function (cordovaProject, options) {}; +- The `updatePlatform` method is equal to the bin/update script. It should update an already installed platform. It should accept a CordovaProject instance, that defines a project structure and configuration, that should be applied to the new platform, and an options object. +- cordovaProject: This is a CordovaProject instance that defines a project structure and configuration, that should be applied to the new platform. This argument is optional and if not defined, that platform is used as a standalone project and not as part of a Cordova project. +- options : This is an options object. The most common options are : +- options.customTemplate : This is a path to custom template, that should override the default one from platform. +- options.link : This is a flag that should indicate that the platform's sources will be linked to the installed platform instead of copying. + - The `updatePlatform` method must return a promise, which is either fulfilled with a PlatformApi instance or rejected with a CordovaError. + +- Api.js exports static function `createPlatform(destination, cfg, options, events);` +- PlatformApi.createPlatform = function(cordovaProject, options) {}; +- The `createPlatform method` is equal to the bin/create script. It should install the platform to a specified directory and create a platform project. It should accept a CordovaProject instance, that defines a project structure and configuration, that should be applied to the new platform, and an options object. +- cordovaProject : This is a CordovaProject instance that defines a project structure and configuration, that should be applied to the new platform. This argument is optional and if not defined, that platform is used as a standalone project and not as part of a Cordova project. +- options : This is an options object. The most common options are : +- options.customTemplate : This is a path to custom template, that should override the default one from the platform. +- options.link : This is a flag that should indicate that the platform's sources will be linked to the installed platform instead of copying. +- The `createPlatform` method must return a promise, which is either fulfilled with a PlatformApi instance or rejected with a CordovaError. + +The way most platforms work is somewhat tricky. The Api.js could be anywhere in the platform repo, ex. /templates/cordova/Api.js . When a new project is created for the platform, the platform copies this file (and supporting files ) to destination/cordova/Api.js. The project expectations demand that the Api.js file be available at
[GitHub] cordova-test-platform pull request #1: Doc requirements for platform api exp...
Github user purplecabbage commented on a diff in the pull request: https://github.com/apache/cordova-test-platform/pull/1#discussion_r128835035 --- Diff: PlatformRequirements.md --- @@ -0,0 +1,144 @@ + +# New Platform Checklist + +## Stand-alone scripts + +bin/create scripts +- bin/create _(typically a node script)_ +- bin/create.bat for windows +- windows .bat file typically just calls bin/create with node + +bin/update +- not entirely sure this code is run, or needs to exist with newish non-destructive platform updates + +## Package Expectations + +- Platforms must have a package.json in their root. +- Package.json exports a 'main', usually `"main": "src/cordova/Api.js"` +- This allows other modules to simply require() the path to this platform and get access to the Api. + +## Api (Platform) Expectations +- The PlatformApi class +- The PlatformApi class is an abstraction around a particular platform that exposes all the actions, properties, and methods for this platform so they are accessible programmatically. +- It can install & uninstall plugins with all source files, web assets and js files. +- It exposes a single 'prepare' method to provide a way for cordova-lib to apply a project's setting/www content to the platform. +- The PlatformApi class should be implemented by each platform that wants to use the new API flow. For those platforms, which don't provide their own PlatformApi, there will be a polyfill in cordova-lib. +- Platforms that implement their own PlatformApi instance should implement all prototype methods of this class to be fully compatible with cordova-lib. +- The PlatformApi instance should define the following field: +- platform : This is a String that defines a platform name. + +- Api.js exports static functions +- there is currently a requirement that the file be called Api.js (todo:change that) + + +- Api.js exports static function `updatePlatform(destination, options, events);` +- PlatformApi.updatePlatform = function (cordovaProject, options) {}; +- The `updatePlatform` method is equal to the bin/update script. It should update an already installed platform. It should accept a CordovaProject instance, that defines a project structure and configuration, that should be applied to the new platform, and an options object. +- cordovaProject: This is a CordovaProject instance that defines a project structure and configuration, that should be applied to the new platform. This argument is optional and if not defined, that platform is used as a standalone project and not as part of a Cordova project. +- options : This is an options object. The most common options are : +- options.customTemplate : This is a path to custom template, that should override the default one from platform. +- options.link : This is a flag that should indicate that the platform's sources will be linked to the installed platform instead of copying. + - The `updatePlatform` method must return a promise, which is either fulfilled with a PlatformApi instance or rejected with a CordovaError. + +- Api.js exports static function `createPlatform(destination, cfg, options, events);` --- End diff -- MUST export a static function createPlatform that returns a new instance of the platformAPI --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. --- - To unsubscribe, e-mail: dev-unsubscr...@cordova.apache.org For additional commands, e-mail: dev-h...@cordova.apache.org
[GitHub] cordova-test-platform pull request #1: Doc requirements for platform api exp...
Github user purplecabbage commented on a diff in the pull request: https://github.com/apache/cordova-test-platform/pull/1#discussion_r128834822 --- Diff: PlatformRequirements.md --- @@ -0,0 +1,144 @@ + +# New Platform Checklist + +## Stand-alone scripts + +bin/create scripts +- bin/create _(typically a node script)_ +- bin/create.bat for windows +- windows .bat file typically just calls bin/create with node + +bin/update +- not entirely sure this code is run, or needs to exist with newish non-destructive platform updates + +## Package Expectations + +- Platforms must have a package.json in their root. +- Package.json exports a 'main', usually `"main": "src/cordova/Api.js"` +- This allows other modules to simply require() the path to this platform and get access to the Api. --- End diff -- this is a MUST main MUST exist, and it MUST be an instance of the platformAPI with methods as you define later. --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. --- - To unsubscribe, e-mail: dev-unsubscr...@cordova.apache.org For additional commands, e-mail: dev-h...@cordova.apache.org
[GitHub] cordova-test-platform pull request #1: Doc requirements for platform api exp...
Github user audreyso commented on a diff in the pull request: https://github.com/apache/cordova-test-platform/pull/1#discussion_r128834432 --- Diff: PlatformRequirements.md --- @@ -0,0 +1,144 @@ + +# New Platform Checklist + +## Stand-alone scripts + +bin/create scripts +- bin/create _(typically a node script)_ +- bin/create.bat for windows +- windows .bat file typically just calls bin/create with node + +bin/update +- not entirely sure this code is run, or needs to exist with newish non-destructive platform updates + --- End diff -- Is there a better way to say this? --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. --- - To unsubscribe, e-mail: dev-unsubscr...@cordova.apache.org For additional commands, e-mail: dev-h...@cordova.apache.org
[GitHub] cordova-test-platform pull request #1: Doc requirements for platform api exp...
Github user audreyso commented on a diff in the pull request: https://github.com/apache/cordova-test-platform/pull/1#discussion_r128834249 --- Diff: PlatformRequirements.md --- @@ -0,0 +1,144 @@ + +# New Platform Checklist + +## Stand-alone scripts + +bin/create scripts +- bin/create _(typically a node script)_ +- bin/create.bat for windows +- windows .bat file typically just calls bin/create with node + +bin/update +- not entirely sure this code is run, or needs to exist with newish non-destructive platform updates + +## Package Expectations + +- Platforms must have a package.json in their root. +- Package.json exports a 'main', usually `"main": "src/cordova/Api.js"` +- This allows other modules to simply require() the path to this platform and get access to the Api. + +## Api (Platform) Expectations +- The PlatformApi class +- The PlatformApi class is an abstraction around a particular platform that exposes all the actions, properties, and methods for this platform so they are accessible programmatically. +- It can install & uninstall plugins with all source files, web assets and js files. +- It exposes a single 'prepare' method to provide a way for cordova-lib to apply a project's setting/www content to the platform. +- The PlatformApi class should be implemented by each platform that wants to use the new API flow. For those platforms, which don't provide their own PlatformApi, there will be a polyfill in cordova-lib. +- Platforms that implement their own PlatformApi instance should implement all prototype methods of this class to be fully compatible with cordova-lib. +- The PlatformApi instance should define the following field: +- platform : This is a String that defines a platform name. + +- Api.js exports static functions +- there is currently a requirement that the file be called Api.js (todo:change that) + --- End diff -- I think this to-do is a note left from someone else as a reminder for something... Can I just take it out? --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. --- - To unsubscribe, e-mail: dev-unsubscr...@cordova.apache.org For additional commands, e-mail: dev-h...@cordova.apache.org
[GitHub] cordova-lib pull request #582: CB-12361 : added tests for plugin/search.js
GitHub user audreyso opened a pull request: https://github.com/apache/cordova-lib/pull/582 CB-12361 : added tests for plugin/search.js ### Platforms affected ### What does this PR do? Added tests for plugin/search.js. ### What testing has been done on this change? ### Checklist - [X] [Reported an issue](http://cordova.apache.org/contribute/issues.html) in the JIRA database - [X] Commit message follows the format: "CB-3232: (android) Fix bug with resolving file paths", where CB- is the JIRA ID & "android" is the platform affected. - [X] Added automated test coverage as appropriate for this change. You can merge this pull request into a Git repository by running: $ git pull https://github.com/audreyso/cordova-lib CB-12361-12-plugin Alternatively you can review and apply these changes as the patch at: https://github.com/apache/cordova-lib/pull/582.patch To close this pull request, make a commit to your master/trunk branch with (at least) the following in the commit message: This closes #582 commit 175513b5eaad88059b0e47257025f122da76a0a5 Author: Audrey SoDate: 2017-07-20T20:23:11Z CB-12361 : added tests for plugin/search.js --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. --- - To unsubscribe, e-mail: dev-unsubscr...@cordova.apache.org For additional commands, e-mail: dev-h...@cordova.apache.org
[GitHub] cordova-test-platform pull request #2: CB-11347: a bit more documentation ar...
GitHub user filmaj opened a pull request: https://github.com/apache/cordova-test-platform/pull/2 CB-11347: a bit more documentation around platform API + links to a few additional discussion PRs. FYI / please review @purplecabbage @shazron You can merge this pull request into a Git repository by running: $ git pull https://github.com/filmaj/cordova-test-platform CB-11347 Alternatively you can review and apply these changes as the patch at: https://github.com/apache/cordova-test-platform/pull/2.patch To close this pull request, make a commit to your master/trunk branch with (at least) the following in the commit message: This closes #2 commit 2e0a0f9ef09522082ba30986fc47899a356f9edb Author: filmajDate: 2017-07-21T18:17:42Z CB-11347: a bit more documentation around platform API and additional reading. --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. --- - To unsubscribe, e-mail: dev-unsubscr...@cordova.apache.org For additional commands, e-mail: dev-h...@cordova.apache.org
[GitHub] cordova-lib pull request #581: CB-12361 : added plugin remove tests
GitHub user audreyso opened a pull request: https://github.com/apache/cordova-lib/pull/581 CB-12361 : added plugin remove tests ### Platforms affected ### What does this PR do? Added plugin remove tests. ### What testing has been done on this change? ### Checklist - [X] [Reported an issue](http://cordova.apache.org/contribute/issues.html) in the JIRA database - [X] Commit message follows the format: "CB-3232: (android) Fix bug with resolving file paths", where CB- is the JIRA ID & "android" is the platform affected. - [X] Added automated test coverage as appropriate for this change. You can merge this pull request into a Git repository by running: $ git pull https://github.com/audreyso/cordova-lib CB-12361-13-plugin Alternatively you can review and apply these changes as the patch at: https://github.com/apache/cordova-lib/pull/581.patch To close this pull request, make a commit to your master/trunk branch with (at least) the following in the commit message: This closes #581 commit f2326ca2b291aef0736b8924d060fe5bd219b1cd Author: Audrey SoDate: 2017-07-20T23:19:07Z CB-12361 : added plugin remove tests --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. --- - To unsubscribe, e-mail: dev-unsubscr...@cordova.apache.org For additional commands, e-mail: dev-h...@cordova.apache.org
[GitHub] cordova-plugin-battery-status issue #57: CB-13028 (CI) Added browser platfor...
Github user filmaj commented on the issue: https://github.com/apache/cordova-plugin-battery-status/pull/57 Do we absolutely require using the mac image? --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. --- - To unsubscribe, e-mail: dev-unsubscr...@cordova.apache.org For additional commands, e-mail: dev-h...@cordova.apache.org
[GitHub] cordova-plugin-wkwebview-engine issue #38: Dynamic Swipe Preference
Github user larssn commented on the issue: https://github.com/apache/cordova-plugin-wkwebview-engine/pull/38 We've been ccorcos' branch. We needed the ability to open the keyboard on `element.focus()` --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. --- - To unsubscribe, e-mail: dev-unsubscr...@cordova.apache.org For additional commands, e-mail: dev-h...@cordova.apache.org
[GitHub] cordova-plugin-camera issue #282: Fix camera permissions bug on video stream...
Github user douglasmoraisdev commented on the issue: https://github.com/apache/cordova-plugin-camera/pull/282 > The code you link to (step 4 of the guide) doesn't use cordova-plugin-camera's JS API. It uses: @filmaj, yes, you're right. But this is a html5 web codage, if you apply this codelab to your cell phone, you will need to (or choose) to use the cordova-plugin-camera. For use... ``` navigator.getUserMedia = navigator.getUserMedia || navigator.webkitGetUserMedia || navigator.mozGetUserMedia; ``` ... on mobile, you need the plugin and permissions on camera. I found the same problem testing this project: https://github.com/eface2face/iOSRTCApp It's a diferent implementation than the Codelabs, and this uses the cordova-plugin-camera too. On a Android 7.0 device, i can't access the camera (black screen). This is just an example. I found the problem this way, but I see this affect the new Android 7.0 (SDK 24 and 25) and upcoming versions because of the new permissions-related changes. You can read more about this at: Https://developer.android.com/about/versions/nougat/android-7.0-changes.html#perm (changes on permissions section). --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. --- - To unsubscribe, e-mail: dev-unsubscr...@cordova.apache.org For additional commands, e-mail: dev-h...@cordova.apache.org
[GitHub] cordova-plugin-battery-status issue #57: CB-13028 (CI) Added browser platfor...
Github user alsorokin commented on the issue: https://github.com/apache/cordova-plugin-battery-status/pull/57 Okay looks like we're blocked by https://github.com/travis-ci/travis-ci/issues/7945 here. --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. --- - To unsubscribe, e-mail: dev-unsubscr...@cordova.apache.org For additional commands, e-mail: dev-h...@cordova.apache.org
[GitHub] cordova-plugin-inappbrowser issue #198: CB-12145: (android) Allow third part...
Github user devMls commented on the issue: https://github.com/apache/cordova-plugin-inappbrowser/pull/198 i need this, how i can use acceptThirdPartyCookies? --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. --- - To unsubscribe, e-mail: dev-unsubscr...@cordova.apache.org For additional commands, e-mail: dev-h...@cordova.apache.org
Nightly build #434 for cordova has failed
Nightly build #434 for cordova has failed. Please check failure details on build details page at https://builds.apache.org/job/cordova-nightly/434/ You can also take a look at build console: https://builds.apache.org/job/cordova-nightly/434/consoleFull - Jenkins for Apache Cordova - To unsubscribe, e-mail: dev-unsubscr...@cordova.apache.org For additional commands, e-mail: dev-h...@cordova.apache.org
Greetings from XMind team-successfully transplant XMind to the mobile platform with Cordova.
Hi everyone on the Cordova Project We pull the request to include XMind in the listing of Cordova’s home page before. Fortunately, we received your email soon. Perhaps we should introduce our software specifically to gain your supports. XMind is a popular mind mapping software, which has been working and designing the professional, friendly, and innovative mind mapping and brainstorming tools for more than 10 years. With millions of users, XMind is regarded as industry leader in mind mapping and brainstorming software. MindMapping is deeply related to the UI, so we try to develop it with HTML + CSS + JS. Transplanting it to mobile platform . We tried to use Cordova as mobile framework . It works well. We hope to share it with others. We would like if we can be listing in the showcase apps. XMind Cloud for Web: http://www.xmind.net/cloud/ XMind Cloud for iOS: https://itunes.apple.com/app/apple-store/id1177322341?mt=8 XMind website: www.xmind.net If there any question, please feel free to contact us. Thank you and looking forward to your reply. Lindy Greetings -- Lovely Greetings, Lindy