Merge branch 'master' of gitee.com:starlock-cn/app-starlock
This commit is contained in:
commit
d20c47fe47
@ -68,7 +68,13 @@ keytool -list -v -keystore android/app/sky.jks
|
||||
```bash
|
||||
flutter build apk --split-per-abi --release --flavor sky -t lib/main_sky.dart
|
||||
```
|
||||
|
||||
编译后的包:
|
||||
通用:build/app/outputs/apk/sky/release/app-sky-universal-release.apk
|
||||
32位:build/app/outputs/apk/sky/release/app-sky-armeabi-v7a-release.apk
|
||||
64位:build/app/outputs/apk/sky/release/app-sky-arm64-v8a-release.apk
|
||||
```bash
|
||||
cp build/app/outputs/apk/sky/release/app-sky-universal-release.apk /d/Downloads/
|
||||
```
|
||||
## 获取编译包的签名
|
||||
用于APP备案,国内商店上架等
|
||||
|
||||
@ -101,7 +107,37 @@ flutter build appbundle --release --flavor sky -t lib/main_sky.dart
|
||||
- 注意,这里的sky.jks和google_pek.zip和encryption_public_key.pem都是sky渠道的,和谷歌账号对应。如果需要使用其他谷歌账号,需要更换这两个文件。
|
||||
|
||||
## 用于华为商店
|
||||
|
||||
1. 复制谷歌的 (PEPK) 工具
|
||||
2. 生成密钥
|
||||
```bash
|
||||
java -jar android/huawei/pepk.jar --keystore=android/app/sky.jks --alias=upload --output=android/huawei/huawei_pek.zip --encryptionkey=034200041E224EE22B45D19B23DB91BA9F52DE0A06513E03A5821409B34976FDEED6E0A47DBA48CC249DD93734A6C5D9A0F43461F9E140F278A5D2860846C2CF5D2C3C02 --include-cert
|
||||
```
|
||||
3. 上传密钥
|
||||
4. 编译和上传 app bundle,和谷歌的一样编译出aab文件即可
|
||||
|
||||
## 用于app store
|
||||
|
||||
下载flavor模板文件,这会创建.tmp文件夹,只需要执行一次,如果有.tmp文件夹,就不用执行这一步了
|
||||
```bash
|
||||
dart run flutter_flavorizr -p assets:download
|
||||
dart run flutter_flavorizr -p assets:extract
|
||||
```
|
||||
重新生成Generated.xcconfig以更新购建物版本号等信息
|
||||
```bash
|
||||
flutter build ios --config-only
|
||||
```
|
||||
构建/编译
|
||||
```bash
|
||||
在Xcode中选择菜单 Product->archive
|
||||
```
|
||||
准备截图
|
||||
因为模拟器只能运行debug,而不能运行release和profile,所以要修改以下运行配置:
|
||||
Xcode顶部中间设备选择器左边,Runner选择下拉,选择Edit Scheme,左侧选择Run,右侧的Build Configuration选择Debug-sky
|
||||
选择Runner:sky-debug 运行于模拟器
|
||||
|
||||
6.5寸(1242 x 2688px)截图选择机型:iphone 11 Pro Max(ios17)
|
||||
5.5寸(1242 x 2208px)截图选择机型:iphone 8 Plus(ios15) (此项目在这个机型会崩溃,无法运行)
|
||||
|
||||
截图完成记得将Runner改回去,不然编译出来的sky是debug版的。
|
||||
|
||||
最后还是随便截图的,然后用PS裁剪成要求的分辨率上传了
|
||||
|
||||
@ -144,7 +144,10 @@ android {
|
||||
productFlavors.xhj.signingConfig signingConfigs.xhj
|
||||
}
|
||||
debug {
|
||||
signingConfig signingConfigs.pre
|
||||
productFlavors.dev.signingConfig signingConfigs.pre
|
||||
productFlavors.pre.signingConfig signingConfigs.pre
|
||||
productFlavors.sky.signingConfig signingConfigs.sky
|
||||
productFlavors.xhj.signingConfig signingConfigs.xhj
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@ -18,7 +18,7 @@ publish_to: 'none' # Remove this line if you wish to publish to pub.dev
|
||||
# In Windows, build-name is used as the major, minor, and patch parts
|
||||
# of the product and file versions while build-number is used as the build suffix.
|
||||
|
||||
version: 1.0.11+20240309
|
||||
version: 1.0.14+20240311
|
||||
|
||||
environment:
|
||||
sdk: '>=2.12.0 <3.0.0'
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user