Skip to content

Commit 2fac30c

Browse files
committed
Enhance documentation for AAB support by updating best practices and CLI sections. Introduced new commands for parsing and uploading AAB files, and clarified the process for using AAB format in the publishing guide.
1 parent 5c23b6b commit 2fac30c

File tree

3 files changed

+18
-4
lines changed

3 files changed

+18
-4
lines changed

site/pages/docs/bestpractice.md

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -50,9 +50,7 @@ splits {
5050

5151
#### 如何支持 aab 格式的原生包?
5252

53-
如果您需要使用 aab 格式的 android 原生包,那么可以在上传到 Google play 之后,在其控制台中下载转换后的 apk 格式(见下图),然后将这个 apk 包上传到热更新的后台,即可正常支持热更新。
54-
55-
![aab](./assets/aab.png)
53+
将 react-native-update-cli 更新到 v2.6.0 以上版本,即可使用 pushy parseAab 和 pushy uploadAab 命令来支持 aab 格式的原生包。
5654

5755
#### 测试与回滚
5856

site/pages/docs/cli.md

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -68,6 +68,13 @@ pushy bundle --platform android --name "1.0.0" --description "热更新版本 1.
6868

6969
解析 app 文件并输出一些相关信息,如版本号,编译时间戳等。
7070

71+
---
72+
73+
#### pushy parseAab [aabFile]
74+
75+
解析 aab 文件并输出一些相关信息,如版本号,编译时间戳等。
76+
77+
7178
---
7279

7380
#### pushy diff [origin][next]
@@ -184,6 +191,14 @@ pushy bundle --platform android --name "1.0.0" --description "热更新版本 1.
184191

185192
---
186193

194+
#### pushy uploadAab [aabFile]
195+
196+
上传 aab 文件到开放平台。
197+
198+
- note: 备注(cli 需 2.6.0 +)
199+
200+
---
201+
187202
#### pushy packages
188203

189204
查看已经上传的原生包。这项操作也可以在网页管理端进行。

site/pages/docs/publish.mdx

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,12 +64,13 @@ $ pushy uploadIpa <ipa后缀文件>
6464

6565
首先参考[文档-打包 APK](https://reactnative.cn/docs/signed-apk-android)设置签名,然后在 android 文件夹下运行`./gradlew assembleRelease``./gradlew aR`,你就可以在`android/app/build/outputs/apk/release/app-release.apk`中找到你的应用包。
6666

67-
> 如果你需要使用 aab 格式(android app bundle,google 市场专用)的包,请参考这里的[做法](bestpractice#如何支持-aab-格式的原生包)将其转换为 apk 格式后再操作。
6867

6968
然后运行如下命令
7069

7170
```bash
7271
$ pushy uploadApk android/app/build/outputs/apk/release/app-release.apk
72+
# 如果你打的是 aab 格式的包,则请使用以下命令
73+
# pushy uploadAab android/app/build/outputs/bundle/release/app-release.aab
7374
```
7475

7576
即可上传 apk 以供后续版本比对之用。此 apk 的`versionName`字段(位于`android/app/build.gradle`中)会被记录为原生版本号`packageVersion`

0 commit comments

Comments
 (0)