From 9abc7a46f7b5325a6b4b9394d4ee332460bdf843 Mon Sep 17 00:00:00 2001 From: Eldad Fux Date: Sun, 17 May 2020 10:33:17 +0300 Subject: [PATCH] Updated platform list --- app/config/platforms.php | 110 +++++++++++++------------- app/controllers/web/home.php | 9 --- app/sdks/flutter-flutter/README.md | 2 +- app/sdks/flutter-flutter/pubspec.yaml | 2 +- 4 files changed, 55 insertions(+), 68 deletions(-) diff --git a/app/config/platforms.php b/app/config/platforms.php index 6438df515..f0382b28a 100644 --- a/app/config/platforms.php +++ b/app/config/platforms.php @@ -1,25 +1,19 @@ [ - 'key' => APP_PLATFORM_WEB, - 'name' => 'Web', - 'description' => 'Client libraries for integrating with '.APP_NAME.' to build web-based applications and websites. Read the [getting started for web](/docs/getting-started-for-web) tutorial to start building your first web application.', + APP_PLATFORM_CLIENT => [ + 'key' => APP_PLATFORM_CLIENT, + 'name' => 'Client', + 'description' => 'Client libraries for integrating with '.APP_NAME.' to build client-based applications and websites. Read the [getting started for web](/docs/getting-started-for-web) or [getting started for Flutter](/docs/getting-started-for-flutter) tutorials to start building your first application.', 'enabled' => true, 'beta' => false, 'languages' => [ [ - 'key' => 'javascript', + 'key' => 'web', 'name' => 'Web', 'version' => '1.0.29', 'url' => 'https://github.com/appwrite/sdk-for-js', @@ -27,21 +21,25 @@ return [ 'beta' => false, 'family' => APP_PLATFORM_CLIENT, 'prism' => 'javascript', - 'source' => realpath(__DIR__ . '/../sdks/web-javascript'), + 'source' => realpath(__DIR__ . '/../sdks/web-web'), 'gitUrl' => 'git@github.com:appwrite/sdk-for-js.git', 'gitRepoName' => 'sdk-for-js', 'gitUserName' => 'appwrite', ], - ], - ], - - APP_PLATFORM_IOS => [ - 'key' => APP_PLATFORM_IOS, - 'name' => 'iOS', - 'description' => 'Client libraries for integrating with '.APP_NAME.' to build iOS applications. Read the [getting started for iOS](/docs/getting-started-for-ios) tutorial to start building your first iOS application.', - 'enabled' => false, - 'beta' => false, - 'languages' => [ + [ + 'key' => 'flutter', + 'name' => 'Flutter', + 'version' => '0.1.1', + 'url' => 'https://github.com/appwrite/sdk-for-flutter', + 'enabled' => true, + 'beta' => true, + 'family' => APP_PLATFORM_CLIENT, + 'prism' => 'dart', + 'source' => realpath(__DIR__ . '/../sdks/flutter-flutter'), + 'gitUrl' => 'git@github.com:appwrite/sdk-for-flutter.git', + 'gitRepoName' => 'sdk-for-flutter', + 'gitUserName' => 'appwrite', + ], [ 'key' => 'swift', 'name' => 'Swift', @@ -68,16 +66,6 @@ return [ 'gitRepoName' => 'sdk-for-objective-c', 'gitUserName' => 'appwrite', ], - ], - ], - - APP_PLATFORM_ANDROID => [ - 'key' => APP_PLATFORM_ANDROID, - 'name' => 'Android', - 'description' => 'Client libraries for integrating with '.APP_NAME.' to build Android applications. Read the [getting started for Android](/docs/getting-started-for-android) tutorial to start building your first Android application.', - 'enabled' => false, - 'beta' => false, - 'languages' => [ [ 'key' => 'kotlin', 'name' => 'Kotlin', @@ -106,30 +94,39 @@ return [ ], ], ], + + // APP_PLATFORM_IOS => [ + // 'key' => APP_PLATFORM_IOS, + // 'name' => 'iOS', + // 'description' => 'Client libraries for integrating with '.APP_NAME.' to build iOS applications. Read the [getting started for iOS](/docs/getting-started-for-ios) tutorial to start building your first iOS application.', + // 'enabled' => false, + // 'beta' => false, + // 'languages' => [ + + // ], + // ], - APP_PLATFORM_FLUTTER => [ - 'key' => APP_PLATFORM_FLUTTER, - 'name' => 'Flutter', - 'description' => 'Client libraries for integrating with '.APP_NAME.' to build cross-platform Flutter applications. Read the [getting started for Flutter](/docs/getting-started-for-flutter) tutorial to start building your first Flutter application.', - 'enabled' => true, - 'beta' => true, - 'languages' => [ - [ - 'key' => 'flutter', - 'name' => 'Flutter', - 'version' => '0.1.1', - 'url' => 'https://github.com/appwrite/sdk-for-flutter', - 'enabled' => true, - 'beta' => true, - 'family' => APP_PLATFORM_CLIENT, - 'prism' => 'dart', - 'source' => realpath(__DIR__ . '/../sdks/flutter-flutter'), - 'gitUrl' => 'git@github.com:appwrite/sdk-for-flutter.git', - 'gitRepoName' => 'sdk-for-dart', - 'gitUserName' => 'appwrite', - ], - ], - ], + // APP_PLATFORM_ANDROID => [ + // 'key' => APP_PLATFORM_ANDROID, + // 'name' => 'Android', + // 'description' => 'Client libraries for integrating with '.APP_NAME.' to build Android applications. Read the [getting started for Android](/docs/getting-started-for-android) tutorial to start building your first Android application.', + // 'enabled' => false, + // 'beta' => false, + // 'languages' => [ + + // ], + // ], + + // APP_PLATFORM_FLUTTER => [ + // 'key' => APP_PLATFORM_FLUTTER, + // 'name' => 'Flutter', + // 'description' => 'Client libraries for integrating with '.APP_NAME.' to build cross-platform Flutter applications. Read the [getting started for Flutter](/docs/getting-started-for-flutter) tutorial to start building your first Flutter application.', + // 'enabled' => true, + // 'beta' => true, + // 'languages' => [ + + // ], + // ], APP_PLATFORM_CONSOLE => [ 'key' => APP_PLATFORM_CONSOLE, @@ -139,7 +136,7 @@ return [ 'languages' => [ [ 'key' => 'javascript', - 'name' => 'JS', + 'name' => 'Console', 'version' => '1.0.0', 'url' => 'https://github.com/appwrite/sdk-for-console', 'enabled' => true, @@ -247,5 +244,4 @@ return [ ], ], ], - ]; diff --git a/app/controllers/web/home.php b/app/controllers/web/home.php index 5ea8178be..f3e4fd72c 100644 --- a/app/controllers/web/home.php +++ b/app/controllers/web/home.php @@ -409,15 +409,6 @@ $utopia->get('/open-api-2.json') if ($extensions) { $platformList = $route->getLabel('sdk.platform', []); - if(in_array(APP_PLATFORM_CLIENT, $platformList)) { - $platformList = array_merge($platformList, [ - APP_PLATFORM_WEB, - APP_PLATFORM_IOS, - APP_PLATFORM_ANDROID, - APP_PLATFORM_FLUTTER, - ]); - } - $temp['extensions'] = [ 'weight' => $route->getOrder(), 'cookies' => $route->getLabel('sdk.cookies', false), diff --git a/app/sdks/flutter-flutter/README.md b/app/sdks/flutter-flutter/README.md index 17fdfc5f0..2521015c9 100644 --- a/app/sdks/flutter-flutter/README.md +++ b/app/sdks/flutter-flutter/README.md @@ -1,7 +1,7 @@ # Appwrite SDK for Dart [![pub package](https://img.shields.io/pub/v/appwrite.svg)](https://pub.dartlang.org/packages/appwrite) -![License](https://img.shields.io/github/license/appwrite/sdk-for-dart.svg?v=1) +![License](https://img.shields.io/github/license/appwrite/sdk-for-flutter.svg?v=1) ![Version](https://img.shields.io/badge/api%20version-0.6.0-blue.svg?v=1) **This SDK is compatible with Appwrite server version 0.6.0. For older versions, please check previous releases.** diff --git a/app/sdks/flutter-flutter/pubspec.yaml b/app/sdks/flutter-flutter/pubspec.yaml index 33c49e6a9..e0f2e6d7e 100644 --- a/app/sdks/flutter-flutter/pubspec.yaml +++ b/app/sdks/flutter-flutter/pubspec.yaml @@ -2,7 +2,7 @@ name: appwrite version: 0.1.1 description: Appwrite is an open-source self-hosted backend server that abstract and simplify complex and repetitive development tasks behind a very simple REST API homepage: https://appwrite.io -repository: https://github.com/appwrite/sdk-for-dart +repository: https://github.com/appwrite/sdk-for-flutter issue_tracker: https://github.com/appwrite/sdk-generator/issues documentation: https://appwrite.io/support environment: