From 5a9c6adfda83a50c2566bc0651374c6b3d820292 Mon Sep 17 00:00:00 2001
From: projectuser <projectuser@leon056.com>
Date: 星期五, 26 十一月 2021 14:28:20 +0800
Subject: [PATCH] init
---
README.md | 49 +++++++++++++++++++++++++++++++++++++++++++++++--
1 files changed, 47 insertions(+), 2 deletions(-)
diff --git a/README.md b/README.md
index f0082ef..b5b2405 100644
--- a/README.md
+++ b/README.md
@@ -1,4 +1,49 @@
-## package_info-0.4.3+4
+# PackageInfo
-package_info-0.4.3+4
+This Flutter plugin provides an API for querying information about an
+application package.
+**Please set your constraint to `package_info: '>=0.4.y+x <2.0.0'`**
+
+## Backward compatible 1.0.0 version is coming
+The package_info plugin has reached a stable API, we guarantee that version `1.0.0` will be backward compatible with `0.4.y+z`.
+Please use `package_info: '>=0.4.y+x <2.0.0'` as your dependency constraint to allow a smoother ecosystem migration.
+For more details see: https://github.com/flutter/flutter/wiki/Package-migration-to-1.0.0
+
+# Usage
+
+You can use the PackageInfo to query information about the
+application package. This works both on iOS and Android.
+
+```dart
+import 'package:package_info/package_info.dart';
+
+PackageInfo packageInfo = await PackageInfo.fromPlatform();
+
+String appName = packageInfo.appName;
+String packageName = packageInfo.packageName;
+String version = packageInfo.version;
+String buildNumber = packageInfo.buildNumber;
+```
+
+Or in async mode:
+
+```dart
+PackageInfo.fromPlatform().then((PackageInfo packageInfo) {
+ String appName = packageInfo.appName;
+ String packageName = packageInfo.packageName;
+ String version = packageInfo.version;
+ String buildNumber = packageInfo.buildNumber;
+});
+```
+
+## Known Issue
+
+As noted on [issue 20761](https://github.com/flutter/flutter/issues/20761#issuecomment-493434578), package_info on iOS
+requires the Xcode build folder to be rebuilt after changes to the version string in `pubspec.yaml`.
+Clean the Xcode build folder with:
+`XCode Menu -> Product -> (Holding Option Key) Clean build folder`.
+
+## Issues and feedback
+
+Please file [issues](https://github.com/flutter/flutter/issues/new) to send feedback or report a bug. Thank you!
--
Gitblit v1.8.0