From 97ad340742c7191f76ae7ff84487d65a3d358c25 Mon Sep 17 00:00:00 2001 From: xuchang Date: Thu, 4 Jan 2024 19:48:29 +0800 Subject: [PATCH] =?UTF-8?q?IssueNo:=20#I8RDPT=20=E8=A7=84=E8=8C=83readme?= =?UTF-8?q?=E8=AF=B4=E6=98=8E=20Sig:=20OpenHarmony-SIG/flutter-samples=20F?= =?UTF-8?q?eature=20or=20Bugfix:=20Feature=20Binary=20Source:=20No?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: xuchang --- README.OpenSource | 2 +- README.en.md | 33 ++++++++++++++++++++ README.md | 79 ++++++++++++++++++++--------------------------- 3 files changed, 67 insertions(+), 47 deletions(-) create mode 100644 README.en.md diff --git a/README.OpenSource b/README.OpenSource index c6652eb6..1823a9ac 100644 --- a/README.OpenSource +++ b/README.OpenSource @@ -5,7 +5,7 @@ "License File": "LICENSE", "Version Number": "d010d3fae62e2bec36614c9b17e9a86e78a65575", "Owner": "aibin@openvalley.net", - "Upstream URL": "https://flutter.dev/", + "Upstream URL": "https://github.com/flutter/samples/", "Description": "This repo is a companion repo to the main flutter repo. It contains the source code for Flutter's first-party packages (i.e., packages developed by the core Flutter team). Check the packages directory to see all packages." } ] \ No newline at end of file diff --git a/README.en.md b/README.en.md new file mode 100644 index 00000000..f169e36d --- /dev/null +++ b/README.en.md @@ -0,0 +1,33 @@ +## Warehouse introduction + +This warehouse is based on the upstream Flutter community [samples warehouse] (https://github.com/flutter/samples/), based on commitId: d010d3fae62e2bec36614c9b17e9a86e78a65575. + +This repository mainly adds sample code for the OpenHarmony platform. + +## New examples have been added to the OpenHarmony platform + +| Warehouse name | Dependency path | Description | +| ----- | ----------------------------------------------- -- | ----- | +| flutter_music_player | flutter_music_player | music player | +| flutter_smart_agriculture | flutter_smart_agriculture | smart farm | +| async_test | ohos/async_test | Asynchronous call demo | +| dio_test | ohos/dio_test | dio demo | +| event_bus_test | ohos/event_bus_test | event-driven demo | +| flutter_svg_test | ohos/flutter_svg_test | svg picture demo | +| http_parser_test | ohos/http_parser_test | http parsing demo | +| http_test | ohos/http_test | http demo | +| path_drawing_test | ohos/path_drawing_test | Path drawing demo | +| platform_test | ohos/platform_test | Platform call demo | +| rxdart_test | ohos/rxdart_test | rxdart demo | +| string_scanner_test | ohos/string_scanner_test | Character scanning demo | +| testchat | ohos/testchat | Chat scene demo | +| tuple_test | ohos/tuple_test | tuple demo | +| uuid_test | ohos/uuid_test | uuid demo | +| vector_match_test | ohos/vector_match_test | Vector matching demo | + + +## How to run the sample code + +1. Compile Flutter’s Engine that is compatible with OpenHarmony, reference: https://gitee.com/openharmony-sig/flutter_engine/blob/master/README.md +2. Download Flutter’s OpenHarmony-compatible SDK and configure the relevant environment. Reference: https://gitee.com/openharmony-sig/flutter_flutter/blob/master/README.md +3. Enter the sample directory, such as flutter_music_player, and run flutter run --local-engine=. \ No newline at end of file diff --git a/README.md b/README.md index a722d51d..4775c819 100644 --- a/README.md +++ b/README.md @@ -1,46 +1,33 @@ -# Flutter samples - -[![Build Status](https://github.com/flutter/samples/workflows/Main%20Branch%20CI/badge.svg)](https://github.com/flutter/samples/actions?workflow=Main%20Branch%20CI) - -A collection of open source samples that illustrate best practices for -[Flutter](https://flutter.dev). - -## Visual samples index - -The easiest way to browse through the samples in this repo (as well as a few others!) -is the [visual samples index](https://flutter.github.io/samples). - -## Tip: minimize download size - -As this repository is quite big, you can use svn to download a single example. -For example: - -``` -svn co https://github.com/flutter/samples/trunk/provider_shopper -``` - -You can also use a -[partial clone](https://github.blog/2020-12-21-get-up-to-speed-with-partial-clone-and-shallow-clone/) -to skip blob objects that aren't currently checked out, -while including the full commit history: - -``` -git clone --filter=blob:none https://github.com/flutter/samples.git -``` - -## Interested in contributing? - -See the [contributor's guide](CONTRIBUTING.md)! - -## Questions or issues? - -If you have a general question about one of these samples or how to adapt its -techniques for one of your own apps, try one of these resources: - -* [The FlutterDev Google Group](https://groups.google.com/forum/#!forum/flutter-dev) -* [The FlutterDev Discord](https://discord.gg/rflutterdev) -* [StackOverflow](https://stackoverflow.com/questions/tagged/flutter) - -If you run into a bug in one of the samples, please file an issue in the -[`flutter/samples` issue tracker](https://github.com/flutter/samples/issues). - +## 仓库介绍 + +该仓库基于上游Flutter社区[samples仓库](https://github.com/flutter/samples/),基于commitId:d010d3fae62e2bec36614c9b17e9a86e78a65575。 + +该仓库主要新增OpenHarmony平台的示例代码。 + +## OpenHarmony平台已新增示例 + +| 仓库名 | 依赖路径 | 描述 | +| ----- | --------------------------------------------- | ----- | +| flutter_music_player | flutter_music_player | 音乐播放器 | +| flutter_smart_agriculture | flutter_smart_agriculture | 智慧农场 | +| async_test | ohos/async_test | 异步调用demo | +| dio_test | ohos/dio_test | dio demo | +| event_bus_test | ohos/event_bus_test | 事件驱动demo | +| flutter_svg_test | ohos/flutter_svg_test | svg图片demo | +| http_parser_test | ohos/http_parser_test | http解析demo | +| http_test | ohos/http_test | http demo | +| path_drawing_test | ohos/path_drawing_test | 路径绘制demo | +| platform_test | ohos/platform_test | 平台调用demo | +| rxdart_test | ohos/rxdart_test | rxdart demo | +| string_scanner_test | ohos/string_scanner_test | 字符扫描demo | +| testchat | ohos/testchat | 聊天场景demo | +| tuple_test | ohos/tuple_test | tuple demo | +| uuid_test | ohos/uuid_test | uuid demo | +| vector_match_test | ohos/vector_match_test | 向量匹配demo | + + +## 如何运行示例代码 + +1. 编译Flutter兼容OpenHarmony的Engine,参考:https://gitee.com/openharmony-sig/flutter_engine/blob/master/README.md +2. 下载Flutter兼容OpenHarmony的SDK,并配置相关环境,参考:https://gitee.com/openharmony-sig/flutter_flutter/blob/master/README.md +3. 进入示例目录,如flutter_music_player,运行flutter run --local-engine=<兼容ohos的engine产物路径>。 -- Gitee